diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-10-16 13:41:55 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-10-20 13:05:33 +0300 |
commit | 593efa4091f5f05c224f8b7fd204d18dbff97e31 (patch) | |
tree | d677fe5880a2e3113302282afcebc2bab4e88d3e /drivers/usb/class | |
parent | 7ebe49b76a001b10b007193b1771f33e6cbc4f3f (diff) | |
download | linux-593efa4091f5f05c224f8b7fd204d18dbff97e31.tar.xz |
USB: allow some usb functions to take a const pointer.
The functions to_usb_interface(), to_usb_device, and
interface_to_usbdev() sometimes would like to take a const * and return
a const * back. As we are doing pointer math, a call to container_of()
loses the const-ness of a pointer, so use a _Generic() macro to pick the
proper inline function to call instead.
Link: https://lore.kernel.org/r/20221016104155.1260201-1-gregkh@linuxfoundation.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/class')
0 files changed, 0 insertions, 0 deletions