Skip to content

Commit 268200b

Browse files
committed
Merge tag 'fixes-for-v4.9-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-linus
Felipe writes: usb: fixes for v4.9-rc5 One single fix for FunctionFS to make sure we're checking ffs_func_req_match()'s return code correctly.
2 parents f7c4a46 + 05e78c6 commit 268200b

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

  • drivers/usb/gadget/function

drivers/usb/gadget/function/f_fs.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3225,11 +3225,11 @@ static bool ffs_func_req_match(struct usb_function *f,
32253225

32263226
switch (creq->bRequestType & USB_RECIP_MASK) {
32273227
case USB_RECIP_INTERFACE:
3228-
return ffs_func_revmap_intf(func,
3229-
le16_to_cpu(creq->wIndex) >= 0);
3228+
return (ffs_func_revmap_intf(func,
3229+
le16_to_cpu(creq->wIndex)) >= 0);
32303230
case USB_RECIP_ENDPOINT:
3231-
return ffs_func_revmap_ep(func,
3232-
le16_to_cpu(creq->wIndex) >= 0);
3231+
return (ffs_func_revmap_ep(func,
3232+
le16_to_cpu(creq->wIndex)) >= 0);
32333233
default:
32343234
return (bool) (func->ffs->user_flags &
32353235
FUNCTIONFS_ALL_CTRL_RECIP);

0 commit comments

Comments
 (0)