提交 c9642374 编写于 作者: D Dmitry Torokhov 提交者: Greg Kroah-Hartman

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: NDmitry Torokhov <dtor@vmware.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 969e3033
......@@ -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))
/*-------------------------------------------------------------------------*/
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册