diff mbox series

[v2,2/3] drivers: usb/core/urb: allow URB_FREE_COHERENT

Message ID 20220609204714.2715188-3-rhett.aultman@samsara.com
State New
Headers show
Series None | expand

Commit Message

Rhett Aultman June 9, 2022, 8:47 p.m. UTC
The URB_FREE_COHERENT flag needs to be added to the allowed flags set in
order to prevent a "bogus flags" warning when it is used.

Signed-off-by: Rhett Aultman <rhett.aultman@samsara.com>
---
 drivers/usb/core/urb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/usb/core/urb.c b/drivers/usb/core/urb.c
index 1460fdac0b18..36c48fb196e0 100644
--- a/drivers/usb/core/urb.c
+++ b/drivers/usb/core/urb.c
@@ -507,7 +507,7 @@  int usb_submit_urb(struct urb *urb, gfp_t mem_flags)
 
 	/* Check against a simple/standard policy */
 	allowed = (URB_NO_TRANSFER_DMA_MAP | URB_NO_INTERRUPT | URB_DIR_MASK |
-			URB_FREE_BUFFER);
+			URB_FREE_BUFFER | URB_FREE_COHERENT);
 	switch (xfertype) {
 	case USB_ENDPOINT_XFER_BULK:
 	case USB_ENDPOINT_XFER_INT: