linux_dsm_epyc7002/drivers/net/ethernet/cavium/liquidio
Florian Fainelli 8e6ce7ebeb net: cavium: liquidio: Avoid dma_unmap_single on uninitialized ndata
The label lio_xmit_failed is used 3 times through liquidio_xmit() but it
always makes a call to dma_unmap_single() using potentially
uninitialized variables from "ndata" variable. Out of the 3 gotos, 2 run
after ndata has been initialized, and had a prior dma_map_single() call.

Fix this by adding a new error label: lio_xmit_dma_failed which does
this dma_unmap_single() and then processed with the lio_xmit_failed
fallthrough.

Fixes: f21fb3ed36 ("Add support of Cavium Liquidio ethernet adapters")
Reported-by: coverity (CID 1309740)
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-07-16 22:06:00 -07:00
..
cn66xx_device.c
cn66xx_device.h
cn66xx_regs.h
cn68xx_device.c
cn68xx_device.h
cn68xx_regs.h
lio_ethtool.c drivers/net: get rid of unnecessary initializations in .get_drvinfo() 2015-10-16 00:24:10 -07:00
lio_main.c net: cavium: liquidio: Avoid dma_unmap_single on uninitialized ndata 2016-07-16 22:06:00 -07:00
liquidio_common.h
liquidio_image.h
Makefile
octeon_config.h
octeon_console.c
octeon_device.c net:liquidio: use kmemdup 2016-05-20 19:50:07 -04:00
octeon_device.h
octeon_droq.c net: cavium: liquidio: Return correct error code 2016-02-13 05:57:11 -05:00
octeon_droq.h
octeon_iq.h
octeon_main.h
octeon_mem_ops.c
octeon_mem_ops.h
octeon_network.h
octeon_nic.c
octeon_nic.h
request_manager.c net-Liquidio: Delete unnecessary checks before the function call "vfree" 2015-06-29 09:28:14 -07:00
response_manager.c
response_manager.h