From: Dmitry Torokhov Date: Wed, 23 Feb 2011 22:38:20 +0000 (-0800) Subject: USB: fix unsafe USB_SS_MAX_STREAMS() definition X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=c9642374d0e969e8c17f4f31cd1a2bd111634227;p=linux-beck.git USB: fix unsafe USB_SS_MAX_STREAMS() definition Macro arguments used in expressions need to be enclosed in parenthesis to avoid unpleasant surprises. Signed-off-by: Dmitry Torokhov Signed-off-by: Greg Kroah-Hartman --- diff --git a/include/linux/usb/ch9.h b/include/linux/usb/ch9.h index ab461948b579..34316ba05f29 100644 --- a/include/linux/usb/ch9.h +++ b/include/linux/usb/ch9.h @@ -584,7 +584,7 @@ struct usb_ss_ep_comp_descriptor { #define USB_DT_SS_EP_COMP_SIZE 6 /* Bits 4:0 of bmAttributes if this is a bulk endpoint */ -#define USB_SS_MAX_STREAMS(p) (1 << (p & 0x1f)) +#define USB_SS_MAX_STREAMS(p) (1 << ((p) & 0x1f)) /*-------------------------------------------------------------------------*/