xhci: Drop superfluous initialization in xhci_queue_ctrl_tx()
Subsystems (2)
PATCH 1/1 xhci: Drop superfluous initialization in xhci_queue_ctrl_tx()
Simplify filed's initialization by directly assigning its final value instead of initializing the variable to sero and then bitwise or-ing it.
Signed-off-by Andrey Smirnov <[email protected]>
Cc Mathias Nyman <[email protected]>
Cc Greg Kroah-Hartman <[email protected]>
--- drivers/usb/host/xhci-ring.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/usb/host/xhci-ring.c +1 -2
@@ -3379,8 +3379,7 @@ int xhci_queue_ctrl_tx(struct xhci_hcd *xhci, gfp_t mem_flags,/* Queue setup TRB - see section 6.4.1.2.1 */ /* FIXME better way to translate setup_packet into two u32 fields? */ setup = (struct usb_ctrlrequest *) urb->setup_packet; - field =0 ; - field |=TRB_IDT |TRB_TYPE (TRB_SETUP ); + field =TRB_IDT |TRB_TYPE (TRB_SETUP );if (start_cycle ==0 ) field |=0x1 ;
Hello!
Quoted 1 line · Andrey Smirnov
Simplify filed's initialization by directly assigning its final value
field's.
Quoted 8 lines
instead of initializing the variable to sero and then bitwise or-ing it.
Signed-off-by Andrey Smirnov <[email protected]>Cc Mathias Nyman <[email protected]>Cc Greg Kroah-Hartman <[email protected]>
[...]
MBR, Sergei
Quoted 9 lines · Sergei Shtylyov
Hello!
Quoted 1 line · Andrey Smirnov
Simplify filed's initialization by directly assigning its final value
field's.
Oops, missed that. Will fix in v2.
Thanks,
Andrey Smirnov