Home
last modified time | relevance | path

Searched hist:de940244e8987a76d73fb2b0057ecd494cbfeefd (Results 1 – 1 of 1) sorted by relevance

/linux/drivers/usb/isp1760/
H A Disp1760-core.cdiff de940244e8987a76d73fb2b0057ecd494cbfeefd Thu Aug 19 20:09:29 CEST 2021 Rui Miguel Silva <rui.silva@linaro.org> usb: isp1760: clean never read udc_enabled warning

When CONFIG_USB_ISP1761_UDC is not enabled the udc_enabled variable is
never used since it is short circuited before in the logic operations.

This would trigger the following warning by clang analyzer:

drivers/usb/isp1760/isp1760-core.c:490:2: warning: Value stored to 'udc_enabled' is never read [clang-analyzer-deadcode.DeadStores]
udc_enabled = ((devflags & ISP1760_FLAG_ISP1763) ||
^
drivers/usb/isp1760/isp1760-core.c:490:2: note: Value stored to 'udc_enabled' is never read

Just swap the other of the operands in the logic operations.

Signed-off-by: Rui Miguel Silva <rui.silva@linaro.org>
Link: https://lore.kernel.org/r/20210819180929.1327349-6-rui.silva@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>