From 4110765294e313e1dbc5d62f2d0e61f02b29ffd7 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Thu, 16 May 2024 14:30:10 +0000 Subject: [PATCH] ANDROID: USB: remove some EXPORT_SYMBOL_GPL() markings that are not needed With the recent android gadget work, some symbols were exported that really were not needed because the only caller was built into the module with them. Remove those exports as no one needs to call these outside of the module itself. Bug: 120441124 Bug: 317149848 Cc: Neill Kapron Fixes: c6f183ea8e2b ("ANDROID: usb: gadget: configfs: Add Uevent to notify userspace") Fixes: 6edae4fa37b5 ("ANDROID: usb: gadget: f_midi: Create f_midi device in android_usb class") Change-Id: I750739ca6a9bb08d4de9fc2de6b9dcd5ffff9bc7 Signed-off-by: Greg Kroah-Hartman [ Remove changes to android_f_midi_info.c as it has been deprecated ] Signed-off-by: Neill Kapron --- drivers/usb/gadget/android_configfs_uevent.c | 8 -------- drivers/usb/gadget/function/android_f_accessory.c | 3 --- 2 files changed, 11 deletions(-) diff --git a/drivers/usb/gadget/android_configfs_uevent.c b/drivers/usb/gadget/android_configfs_uevent.c index 5cd2de61000f..8baa7ae007ae 100644 --- a/drivers/usb/gadget/android_configfs_uevent.c +++ b/drivers/usb/gadget/android_configfs_uevent.c @@ -151,13 +151,11 @@ int android_class_create(void) { return class_register(&android_usb_class); } -EXPORT_SYMBOL_GPL(android_class_create); void android_class_destroy(void) { class_unregister(&android_usb_class); } -EXPORT_SYMBOL_GPL(android_class_destroy); int android_device_create(struct android_uevent_opts *opts) { @@ -191,7 +189,6 @@ int android_device_create(struct android_uevent_opts *opts) return 0; } -EXPORT_SYMBOL_GPL(android_device_create); void android_device_destroy(struct android_uevent_opts *opts) { @@ -226,7 +223,6 @@ void android_device_destroy(struct android_uevent_opts *opts) device_destroy(dev->class, dev->devt); spin_unlock_irqrestore(&opts_lock, flags); } -EXPORT_SYMBOL_GPL(android_device_destroy); void __android_set_connected(struct android_uevent_opts *opts, bool connected) @@ -260,25 +256,21 @@ void android_set_connected(struct android_uevent_opts *opts) { __android_set_connected(opts, true); } -EXPORT_SYMBOL_GPL(android_set_connected); void android_set_disconnected(struct android_uevent_opts *opts) { __android_set_connected(opts, false); } -EXPORT_SYMBOL_GPL(android_set_disconnected); void android_set_configured(struct android_uevent_opts *opts) { __android_set_configured(opts, true); } -EXPORT_SYMBOL_GPL(android_set_configured); void android_set_unconfigured(struct android_uevent_opts *opts) { __android_set_configured(opts, false); } -EXPORT_SYMBOL_GPL(android_set_unconfigured); struct device *android_create_function_device(char *name, void *drvdata, const struct attribute_group **groups) diff --git a/drivers/usb/gadget/function/android_f_accessory.c b/drivers/usb/gadget/function/android_f_accessory.c index e87984222608..f1ab05a98149 100644 --- a/drivers/usb/gadget/function/android_f_accessory.c +++ b/drivers/usb/gadget/function/android_f_accessory.c @@ -1314,7 +1314,6 @@ void android_acc_disconnect(void) kill_all_hid_devices(dev); put_acc_dev(dev); } -EXPORT_SYMBOL_GPL(android_acc_disconnect); static void acc_cleanup(void) { @@ -1456,7 +1455,6 @@ bool android_acc_req_match_composite(struct usb_composite_dev *cdev, { return __acc_req_match(ctrl); } -EXPORT_SYMBOL_GPL(android_acc_req_match_composite); static int __acc_setup(struct usb_composite_dev *cdev, const struct usb_ctrlrequest *ctrl) @@ -1590,7 +1588,6 @@ int android_acc_setup_composite(struct usb_composite_dev *cdev, } return __acc_setup(cdev, ctrl); } -EXPORT_SYMBOL_GPL(android_acc_setup_composite); static int acc_setup(struct usb_function *f, const struct usb_ctrlrequest *ctrl)