Skip to content
Commit eeed948c authored by Lee Jones's avatar Lee Jones Committed by Greg Kroah-Hartman
Browse files

usb: dwc2: gadget: Avoid pointless read of EP control register



Commit ec1f9d9f ("usb: dwc2: gadget: parity fix in isochronous mode") moved
these checks to dwc2_hsotg_change_ep_iso_parity() back in 2015.  The assigned
value hasn't been read back since.  Let's remove the unnecessary H/W read.

Fixes the following W=1 warning:

 drivers/usb/dwc2/gadget.c: In function ‘dwc2_hsotg_epint’:
 drivers/usb/dwc2/gadget.c:2981:6: warning: variable ‘ctrl’ set but not used [-Wunused-but-set-variable]
 2981 | u32 ctrl;
 | ^~~~

Cc: Ben Dooks <ben@simtec.co.uk>
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
Acked-by: default avatarMinas Harutyunyan <hminas@synopsys.com>
Link: https://lore.kernel.org/r/20200715093209.3165641-3-lee.jones@linaro.org


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9607f3cd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment