]> err.no Git - linux-2.6/commitdiff
e1000e: Return 1 instead of a non-zero value for link up indication
authorBruce Allan <bruce.w.allan@intel.com>
Sat, 9 Aug 2008 01:35:44 +0000 (18:35 -0700)
committerJeff Garzik <jgarzik@redhat.com>
Thu, 14 Aug 2008 08:39:56 +0000 (04:39 -0400)
A number of users have mentioned they have tools that rely on a link-up
indication having a return value of 1 rather than a non-zero value.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
drivers/net/e1000e/ethtool.c

index cf9679f2b7c41fc94906f81872f452bdf9750b71..e21c9e0f3738441a159ad0a4068e9bb8fe2b82e5 100644 (file)
@@ -177,7 +177,7 @@ static u32 e1000_get_link(struct net_device *netdev)
        u32 status;
        
        status = er32(STATUS);
-       return (status & E1000_STATUS_LU);
+       return (status & E1000_STATUS_LU) ? 1 : 0;
 }
 
 static int e1000_set_spd_dplx(struct e1000_adapter *adapter, u16 spddplx)