net: adaptec: starfire: add checks for dma mapping errors
authorAlexey Khoroshilov <khoroshilov@ispras.ru>
Fri, 27 Jan 2017 22:07:30 +0000 (01:07 +0300)
committerRaspbian kernel package updater <root@raspbian.org>
Sun, 23 Jul 2017 02:58:22 +0000 (02:58 +0000)
commit2f4e8b3315b282e11a201310b6061b6224178e4f
tree5abefab96be6012160553d92db8f85d89c842997
parent6dc643150b7c93257640c3563fb42c558ddab016
net: adaptec: starfire: add checks for dma mapping errors

[ Upstream commit d1156b489fa734d1af763d6a07b1637c01bb0aed ]

init_ring(), refill_rx_ring() and start_tx() don't 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 <khoroshilov@ispras.ru>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/adaptec/starfire.c