ANDROID: usb: f_accessory: Remove useless assignment
acc_alloc_inst() assigns to a local 'dev' variable, but then never uses
it. Remove the redundant assignment, and the local variable along with
it.
Bug: 173789633
Signed-off-by: Will Deacon <willdeacon@google.com>
Change-Id: Ide9c2e89fb12b846eb8739b302d1b742fc7eb6b5
Signed-off-by: Giuliano Procida <gprocida@google.com>
diff --git a/drivers/usb/gadget/function/f_accessory.c b/drivers/usb/gadget/function/f_accessory.c
index f83064d..59831d7 100644
--- a/drivers/usb/gadget/function/f_accessory.c
+++ b/drivers/usb/gadget/function/f_accessory.c
@@ -1299,7 +1299,6 @@
static struct usb_function_instance *acc_alloc_inst(void)
{
struct acc_instance *fi_acc;
- struct acc_dev *dev;
int err;
fi_acc = kzalloc(sizeof(*fi_acc), GFP_KERNEL);
@@ -1316,7 +1315,6 @@
config_group_init_type_name(&fi_acc->func_inst.group,
"", &acc_func_type);
- dev = _acc_dev;
return &fi_acc->func_inst;
}