mirror of
https://github.com/torvalds/linux.git
synced 2024-11-23 04:31:50 +00:00
ibmvnic: Potential NULL dereference in clean_one_tx_pool()
There is an && vs || typo here, which potentially leads to a NULL
dereference.
Fixes: e9e1e97884
("ibmvnic: Update TX pool cleaning routine")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
0f1417f9f0
commit
050e85c97f
@ -1135,7 +1135,7 @@ static void clean_one_tx_pool(struct ibmvnic_adapter *adapter,
|
||||
u64 tx_entries;
|
||||
int i;
|
||||
|
||||
if (!tx_pool && !tx_pool->tx_buff)
|
||||
if (!tx_pool || !tx_pool->tx_buff)
|
||||
return;
|
||||
|
||||
tx_entries = tx_pool->num_buffers;
|
||||
|
Loading…
Reference in New Issue
Block a user