From: Alexey Khoroshilov
Date: Sat, 15 Apr 2017 01:50:50 +0300
> @@ -1136,6 +1141,10 @@ static netdev_tx_t ns83820_hard_start_xmit(struct
> sk_buff *skb,
> if (nr_frags)
> len -= skb->data_len;
> buf = pci_map_single(dev->pci_dev, skb->data, len, PCI_DMA_TODEVICE);
> +
The driver does not check if mapping dma memory succeed.
The patch adds the checks and failure handling.
Found by Linux Driver Verification project (linuxtesting.org).
Signed-off-by: Alexey Khoroshilov
---
drivers/net/ethernet/natsemi/ns83820.c | 13 +++--
1 file changed, 11 insertions(