mirror of
https://github.com/lkl/linux.git
synced 2025-12-19 16:13:19 +09:00
USB: mark all struct bus_type as const
Now that the driver core can properly handle constant struct bus_type, move all of the USB subsystem struct bus_type structures as const, placing them into read-only memory which can not be modified at runtime. Cc: Johan Hovold <johan@kernel.org> Cc: Evan Green <evgreen@chromium.org> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: linux-usb@vger.kernel.org Acked-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Link: https://lore.kernel.org/r/20230313182918.1312597-36-gregkh@linuxfoundation.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
@@ -378,7 +378,7 @@ void usb_serial_handle_dcd_change(struct usb_serial_port *usb_port,
|
||||
int usb_serial_bus_register(struct usb_serial_driver *device);
|
||||
void usb_serial_bus_deregister(struct usb_serial_driver *device);
|
||||
|
||||
extern struct bus_type usb_serial_bus_type;
|
||||
extern const struct bus_type usb_serial_bus_type;
|
||||
extern struct tty_driver *usb_serial_tty_driver;
|
||||
|
||||
static inline void usb_serial_debug_data(struct device *dev,
|
||||
|
||||
Reference in New Issue
Block a user