net: sxgbe: fix potential null dereference
authorByungho An <bh74.an@samsung.com>
Fri, 28 Mar 2014 17:57:44 +0000 (10:57 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 28 Mar 2014 18:42:24 +0000 (14:42 -0400)
commit2405e8f64c14a2cc9967f1f9bbeb1ba48b6cc2a1
treeb90594ff4db31c3d5cd16c6b626b307a2552fc56
parent40b92cad5efb9a03cff2f01dc96532e1a6bffa14
net: sxgbe: fix potential null dereference

This fixes following:

drivers/net/ethernet/samsung/sxgbe/sxgbe_main.c:1828 sxgbe_hw_init()
error: potential null dereference 'priv->hw'.  (kmalloc returns null)

Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Byungho An <bh74.an@samsung.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/samsung/sxgbe/sxgbe_main.c