tg3: Restrict phy ioctl access
authorMatt Carlson <mcarlson@broadcom.com>
Tue, 25 Jan 2011 15:58:51 +0000 (15:58 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 26 Jan 2011 03:38:17 +0000 (19:38 -0800)
commitf746a3136a61ae535c5d0b49a9418fa21edc61b5
treea59083f33ea74ccf3df7f1dd4468ec06d39dc997
parent0583d52114b19ea06d03dd2cf762a7737c265400
tg3: Restrict phy ioctl access

If management firmware is present and the device is down, the firmware
will assume control of the phy.  If a phy access were allowed from the
host, it will collide with firmware phy accesses, resulting in
unpredictable behavior.  This patch fixes the problem by disallowing phy
accesses during the problematic condition.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/tg3.c