]> git.baikalelectronics.ru Git - kernel.git/commit
qeth: improve set_features error handling
authorHans Wippel <hwippel@linux.vnet.ibm.com>
Thu, 16 Jun 2016 14:19:01 +0000 (16:19 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 17 Jun 2016 05:16:13 +0000 (22:16 -0700)
commit2df3116209a7fd4edbe29129c9dcf2e1017ff4e0
tree188c731ef8b450eb157f12c90a0b982f3b7d8095
parent0131b3b751e0d5363c81894d33b259fc0c8960f6
qeth: improve set_features error handling

The function set_features is called to configure network device features
on the hardware. If errors occur, the network device features should
reflect the changed hardware state and the function should return an
error in order to notify the user.

In case of an error, the current implementation does not necessarily
save the changed hardware state in the network device features before an
error is returned.

This patch improves error handling by saving features, that could be
changed, to the network device features before returning an error. If
the device is not running, an additional check in fix_features removes
features, that require hardware changes, before they are passed to
set_features. Thus, the corresponding check was removed in set_features.

Signed-off-by: Hans Wippel <hwippel@linux.vnet.ibm.com>
Signed-off-by: Ursula Braun <ubraun@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/s390/net/qeth_core_main.c