Revision c10e4cafa2698dedb9b61bbf6d68f209e779cb19 authored by Iyappan Subramanian on 21 August 2014, 20:44:48 UTC, committed by David S. Miller on 22 August 2014, 18:25:25 UTC
A NULL pointer dereference is possible for the argument ring->buf_pool
which is passed to xgene_enet_free_desc_ring(), as ring could be NULL.

And now since NULL pointers are being checked for before the calls to
xgene_enet_free_desc_ring(), might as well take advantage of them and
not call the function if the argument would be NULL.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Iyappan Subramanian <isubramanian@apm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 2ba5af4
History
File Mode Size
Kconfig -rw-r--r-- 6.6 KB
Makefile -rw-r--r-- 1.4 KB
phy-bcm-kona-usb2.c -rw-r--r-- 3.8 KB
phy-berlin-sata.c -rw-r--r-- 6.8 KB
phy-core.c -rw-r--r-- 20.7 KB
phy-exynos-dp-video.c -rw-r--r-- 2.7 KB
phy-exynos-mipi-video.c -rw-r--r-- 4.6 KB
phy-exynos4210-usb2.c -rw-r--r-- 7.0 KB
phy-exynos4x12-usb2.c -rw-r--r-- 10.5 KB
phy-exynos5-usbdrd.c -rw-r--r-- 17.8 KB
phy-exynos5250-sata.c -rw-r--r-- 6.9 KB
phy-exynos5250-usb2.c -rw-r--r-- 12.8 KB
phy-hix5hd2-sata.c -rw-r--r-- 5.3 KB
phy-miphy365x.c -rw-r--r-- 16.2 KB
phy-mvebu-sata.c -rw-r--r-- 3.4 KB
phy-omap-control.c -rw-r--r-- 9.7 KB
phy-omap-usb2.c -rw-r--r-- 9.4 KB
phy-qcom-apq8064-sata.c -rw-r--r-- 8.6 KB
phy-qcom-ipq806x-sata.c -rw-r--r-- 6.5 KB
phy-s5pv210-usb2.c -rw-r--r-- 4.4 KB
phy-samsung-usb2.c -rw-r--r-- 6.1 KB
phy-samsung-usb2.h -rw-r--r-- 1.8 KB
phy-spear1310-miphy.c -rw-r--r-- 7.9 KB
phy-spear1340-miphy.c -rw-r--r-- 8.4 KB
phy-sun4i-usb.c -rw-r--r-- 8.3 KB
phy-ti-pipe3.c -rw-r--r-- 13.1 KB
phy-twl4030-usb.c -rw-r--r-- 21.6 KB
phy-xgene.c -rw-r--r-- 60.0 KB

back to top