diff options
author | Atul Gupta <atul.gupta@chelsio.com> | 2019-05-02 12:46:55 +0200 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2019-05-09 07:17:22 +0200 |
commit | b4f91664307d5bf4f0d93da12a6146f9cf3559fb (patch) | |
tree | 5076c818a357dc8f9895ab85e46f91abe6be3745 /drivers/crypto/chelsio | |
parent | crypto: ccree - use a proper le32 type for le32 val (diff) | |
download | linux-b4f91664307d5bf4f0d93da12a6146f9cf3559fb.tar.xz linux-b4f91664307d5bf4f0d93da12a6146f9cf3559fb.zip |
crypto: chelsio - Fix NULL pointer dereference
Do not request FW to generate cidx update if there is less
space in tx queue to post new request.
SGE DBP 1 pidx increment too large
BUG: unable to handle kernel NULL pointer dereference at
0000000000000124
SGE error for queue 101
Signed-off-by: Atul Gupta <atul.gupta@chelsio.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/chelsio')
-rw-r--r-- | drivers/crypto/chelsio/chcr_ipsec.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/crypto/chelsio/chcr_ipsec.c b/drivers/crypto/chelsio/chcr_ipsec.c index 2f60049361ef..f429aae72542 100644 --- a/drivers/crypto/chelsio/chcr_ipsec.c +++ b/drivers/crypto/chelsio/chcr_ipsec.c @@ -575,7 +575,8 @@ inline void *chcr_crypto_wreq(struct sk_buff *skb, if (unlikely(credits < ETHTXQ_STOP_THRES)) { netif_tx_stop_queue(q->txq); q->q.stops++; - wr_mid |= FW_WR_EQUEQ_F | FW_WR_EQUIQ_F; + if (!q->dbqt) + wr_mid |= FW_WR_EQUEQ_F | FW_WR_EQUIQ_F; } wr_mid |= FW_ULPTX_WR_DATA_F; wr->wreq.flowid_len16 = htonl(wr_mid); |