Commit 7a13240
bnxt_en: fix ethtool_reset_flags ABI violations
The ethtool ABI specifies that the reset operation should only clear
the flags that were actually reset. Setting the flags to zero after
a chip reset violates this because it does not include resetting the
application processor complex. Similarly, components that are not yet
defined are also not necessarily being reset.
The fact that chip reset does not cover the AP also means that it is
inappropriate to treat these two components exclusively of one another.
The ABI provides a mechanism to report a failure to reset independent
components via the returned bitmask, so it is also wrong to fail hard
if one of a set of independent resets is not possible.
It is incorrect to rely on the passed by reference flags in bnxt_reset(),
which are being updated as components are reset. The initially requested
value should be used instead so that hard errors do not propagate if any
earlier components could have been reset successfully.
Note, AP and chip resets are global in nature. Dedicated resets are
thus not currently supported.
Signed-off-by: Edwin Peer <edwin.peer@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>1 parent 94f17e8 commit 7a13240
File tree
2 files changed
+31
-24
lines changed- drivers/net/ethernet/broadcom/bnxt
2 files changed
+31
-24
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2999 | 2999 | | |
3000 | 3000 | | |
3001 | 3001 | | |
3002 | | - | |
| 3002 | + | |
| 3003 | + | |
| 3004 | + | |
| 3005 | + | |
3003 | 3006 | | |
3004 | 3007 | | |
3005 | 3008 | | |
| |||
3013 | 3016 | | |
3014 | 3017 | | |
3015 | 3018 | | |
3016 | | - | |
| 3019 | + | |
3017 | 3020 | | |
3018 | | - | |
3019 | | - | |
3020 | | - | |
3021 | | - | |
3022 | | - | |
3023 | | - | |
3024 | | - | |
3025 | | - | |
3026 | | - | |
| 3021 | + | |
| 3022 | + | |
| 3023 | + | |
| 3024 | + | |
| 3025 | + | |
| 3026 | + | |
| 3027 | + | |
| 3028 | + | |
| 3029 | + | |
3027 | 3030 | | |
3028 | | - | |
3029 | | - | |
3030 | | - | |
3031 | | - | |
| 3031 | + | |
3032 | 3032 | | |
3033 | | - | |
3034 | | - | |
3035 | | - | |
3036 | | - | |
| 3033 | + | |
| 3034 | + | |
| 3035 | + | |
| 3036 | + | |
| 3037 | + | |
| 3038 | + | |
| 3039 | + | |
| 3040 | + | |
| 3041 | + | |
3037 | 3042 | | |
3038 | | - | |
3039 | | - | |
3040 | 3043 | | |
3041 | 3044 | | |
3042 | | - | |
| 3045 | + | |
3043 | 3046 | | |
3044 | 3047 | | |
3045 | 3048 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
81 | | - | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
82 | 86 | | |
83 | 87 | | |
84 | 88 | | |
| |||
0 commit comments