lan78xx: Add missing return code checks
authorJohn Efstathiades <john.efstathiades@pebblebay.com>
Tue, 24 Aug 2021 18:56:08 +0000 (19:56 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 25 Aug 2021 09:55:43 +0000 (10:55 +0100)
commit3415f6baaddb9b39d7112247ab39ef3c700f882e
tree7c47c51324a84df5208d9b7dcf163f9821a9c88e
parent40b8452fa8b4567ab7d862c7d4c3d02f635f17fd
lan78xx: Add missing return code checks

There are many places in the driver where the return code from a
function call is captured but without a subsequent test of the
return code and appropriate action taken.

This patch adds the missing return code tests and action. In most
cases the action is an early exit from the calling function.

The function lan78xx_set_suspend() was also updated to make it
consistent with lan78xx_suspend().

Signed-off-by: John Efstathiades <john.efstathiades@pebblebay.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/lan78xx.c