From ecfbd4b48b53469e13746cd53a619fea50920fe8 Mon Sep 17 00:00:00 2001 From: Simon Arlott Date: Mon, 30 Aug 2010 22:50:20 +0100 Subject: [PATCH] --- yaml --- r: 213553 b: refs/heads/master c: f7dd64916bb6cfae8c96eaa3c754c30b5046586f h: refs/heads/master i: 213551: 7aff6345e8dc745d0f7140bc904da22e1b9df2cc v: v3 --- [refs] | 2 +- trunk/drivers/usb/core/urb.c | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index bb65d8ff2ba9..e06de50bece7 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 0cf7a6338808d702c256778188516a16805e6145 +refs/heads/master: f7dd64916bb6cfae8c96eaa3c754c30b5046586f diff --git a/trunk/drivers/usb/core/urb.c b/trunk/drivers/usb/core/urb.c index 419e6b34e2fe..c14fc082864f 100644 --- a/trunk/drivers/usb/core/urb.c +++ b/trunk/drivers/usb/core/urb.c @@ -401,8 +401,11 @@ int usb_submit_urb(struct urb *urb, gfp_t mem_flags) }; /* Check that the pipe's type matches the endpoint's type */ - if (usb_pipetype(urb->pipe) != pipetypes[xfertype]) + if (usb_pipetype(urb->pipe) != pipetypes[xfertype]) { + dev_err(&dev->dev, "BOGUS urb xfer, pipe %x != type %x\n", + usb_pipetype(urb->pipe), pipetypes[xfertype]); return -EPIPE; /* The most suitable error code :-) */ + } /* enforce simple/standard policy */ allowed = (URB_NO_TRANSFER_DMA_MAP | URB_NO_INTERRUPT | URB_DIR_MASK |