diff mbox series

[33/75] headers: backport usb_maxpacket api change

Message ID 20240627234808.1253337-34-hauke@hauke-m.de (mailing list archive)
State New, archived
Headers show
Series backports: Update to kernel 6.1.95 | expand

Commit Message

Hauke Mehrtens June 27, 2024, 11:47 p.m. UTC
From: Felix Fietkau <nbd@nbd.name>

The third argument was removed

Signed-off-by: Felix Fietkau <nbd@nbd.name>
---
 backport/backport-include/linux/usb.h | 8 ++++++++
 1 file changed, 8 insertions(+)
diff mbox series

Patch

diff --git a/backport/backport-include/linux/usb.h b/backport/backport-include/linux/usb.h
index bedc405b..ba39657b 100644
--- a/backport/backport-include/linux/usb.h
+++ b/backport/backport-include/linux/usb.h
@@ -9,4 +9,12 @@  bool usb_check_bulk_endpoints(
 		const struct usb_interface *intf, const u8 *ep_addrs);
 #endif /* < 5.15 */
 
+#if LINUX_VERSION_IS_LESS(5,19,0)
+static inline u16 backport_usb_maxpacket(struct usb_device *udev, int pipe)
+{
+	return usb_maxpacket(udev, pipe, usb_pipeout(pipe));
+}
+#define usb_maxpacket LINUX_BACKPORT(usb_maxpacket)
+#endif /* <5.19 */
+
 #endif /* __BACKPORT_LINUX_USB_H */