[PATCH 0/2] can: usb: remove pointers to struct usb_interface in device's priv structures

Vincent Mailhol posted 2 patches 2 years, 9 months ago
drivers/net/can/usb/gs_usb.c | 29 +++++++++--------------------
drivers/net/can/usb/ucan.c   |  2 --
2 files changed, 9 insertions(+), 22 deletions(-)
[PATCH 0/2] can: usb: remove pointers to struct usb_interface in device's priv structures
Posted by Vincent Mailhol 2 years, 9 months ago
The gs_can and ucan drivers keep a pointer to struct usb_interface in
their private structure. This is not needed. For gs_can the only use
is to retrieve struct usb_device, which is already available in
gs_usb::udev. For ucan, the field is set but never used.

Remove the struct usb_interface fields and clean up.

Vincent Mailhol (2):
  can: ucan: remove unused ucan_priv::intf
  can: gs_usb: remove gs_can::iface

 drivers/net/can/usb/gs_usb.c | 29 +++++++++--------------------
 drivers/net/can/usb/ucan.c   |  2 --
 2 files changed, 9 insertions(+), 22 deletions(-)

-- 
2.25.1
Re: [PATCH 0/2] can: usb: remove pointers to struct usb_interface in device's priv structures
Posted by Marc Kleine-Budde 2 years, 9 months ago
On 08.12.2022 17:11:40, Vincent Mailhol wrote:
> The gs_can and ucan drivers keep a pointer to struct usb_interface in
> their private structure. This is not needed. For gs_can the only use
> is to retrieve struct usb_device, which is already available in
> gs_usb::udev. For ucan, the field is set but never used.
> 
> Remove the struct usb_interface fields and clean up.

Applied to linux-can-next.

Thanks,
Marc

-- 
Pengutronix e.K.                 | Marc Kleine-Budde           |
Embedded Linux                   | https://www.pengutronix.de  |
Vertretung West/Dortmund         | Phone: +49-231-2826-924     |
Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-5555 |