]> git.baikalelectronics.ru Git - kernel.git/commit
net/fec_mpc52xx: Don't dereference phy_device if it is NULL
authorGrant Likely <grant.likely@secretlab.ca>
Tue, 31 Mar 2009 20:17:03 +0000 (20:17 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 2 Apr 2009 07:57:01 +0000 (00:57 -0700)
commitd1ba1ab08f2ea19f5f22eb7e3679f7872d77bba1
treebbaa72bad1b4e702004f0b091be2e4d43b69a71e
parentaac0ca0fef35ecae83fb19ece8b79b30d38d5f88
net/fec_mpc52xx: Don't dereference phy_device if it is NULL

The FEC Ethernet device isn't always attached to a phy.  Be careful
not to dereference phy_device if it is NULL.  Also eliminates an
unnecessary extra function from the ioctl path.

Reported-by: Henk Stegeman <henk.stegeman@gmail.com>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/fec_mpc52xx.c