]> git.baikalelectronics.ru Git - kernel.git/commit
net: usb: asix_devices: fix missing return code check on call to asix_write_medium_mode
authorColin Ian King <colin.king@canonical.com>
Tue, 28 Feb 2017 11:58:22 +0000 (11:58 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 1 Mar 2017 17:50:58 +0000 (09:50 -0800)
commitc07c0182b2ce22129f1e2f4ef5643d59494860d3
tree1b464840d02d47f9592c657954fcfdfb466fdc7d
parent59a605972142a9b2aa65f765fd5ce32817992fc0
net: usb: asix_devices: fix missing return code check on call to asix_write_medium_mode

The call to asix_write_medium_mode is not updating the return code ret
and yet ret is being checked for an error. Fix this by assigning ret to
the return code from the call asix_write_medium_mode.

Detected by CoverityScan, CID#1357148 ("Logically Dead Code")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/asix_devices.c