From 77bf53b4861491ad49414d8fceefda2602274519 Mon Sep 17 00:00:00 2001 From: Aran Dalton Date: Mon, 7 Mar 2022 17:34:34 +0800 Subject: [PATCH] ANDROID: usb: gadget: f_accessory: add compat_ioctl support On Android 32-bit system, the following Cts Verifier testcase failed: manualTests#com.android.cts.verifier.usb.accessory.UsbAccessoryTestActivity The reason is that compat_ioctl() needs to be called. So let's add compat_ioctl() for 32-bit applications to solve this issue. Bug: 223101878 Change-Id: I6e1f797d919494d293184411041955c33ad08aef Signed-off-by: Aran Dalton --- drivers/usb/gadget/function/f_accessory.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/gadget/function/f_accessory.c b/drivers/usb/gadget/function/f_accessory.c index 4fb58375dbba..36f775790ed9 100644 --- a/drivers/usb/gadget/function/f_accessory.c +++ b/drivers/usb/gadget/function/f_accessory.c @@ -931,6 +931,7 @@ static const struct file_operations acc_fops = { .read = acc_read, .write = acc_write, .unlocked_ioctl = acc_ioctl, + .compat_ioctl = acc_ioctl, .open = acc_open, .release = acc_release, };