diff options
author | Stefan Wahren <stefan.wahren@i2se.com> | 2018-11-08 14:38:21 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-11-08 19:41:01 -0800 |
commit | 026b907d58c48b2ff2a4c04a67bb5f71ebda1f2d (patch) | |
tree | 80acab764c725b1c4141bfadb838a3ac9cc8934a /drivers/net/ethernet/qualcomm/qca_spi.h | |
parent | 50254256f382c56bde87d970f3d0d02fdb76ec70 (diff) | |
download | linux-stable-026b907d58c48b2ff2a4c04a67bb5f71ebda1f2d.tar.gz linux-stable-026b907d58c48b2ff2a4c04a67bb5f71ebda1f2d.tar.bz2 linux-stable-026b907d58c48b2ff2a4c04a67bb5f71ebda1f2d.zip |
net: qca_spi: Add available buffer space verification
Interferences on the SPI line could distort the response of
available buffer space. So at least we should check that the
response doesn't exceed the maximum available buffer space.
In error case increase a new error counter and retry it later.
This behavior avoids buffer errors in the QCA7000, which
results in an unnecessary chip reset including packet loss.
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/qualcomm/qca_spi.h')
-rw-r--r-- | drivers/net/ethernet/qualcomm/qca_spi.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/qualcomm/qca_spi.h b/drivers/net/ethernet/qualcomm/qca_spi.h index 2d2c49726492..eb9af45fcc5e 100644 --- a/drivers/net/ethernet/qualcomm/qca_spi.h +++ b/drivers/net/ethernet/qualcomm/qca_spi.h @@ -74,6 +74,7 @@ struct qcaspi_stats { u64 ring_full; u64 spi_err; u64 write_verify_failed; + u64 buf_avail_err; }; struct qcaspi { |