e1000e: improper return code signage
authorBruce Allan <bruce.w.allan@intel.com>
Fri, 20 Nov 2009 23:23:53 +0000 (23:23 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sat, 21 Nov 2009 19:33:56 +0000 (11:33 -0800)
The e1000_get_cable_length_82577() should return a negative value upon
error.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/e1000e/phy.c

index 03175b3..95a8196 100644 (file)
@@ -3137,7 +3137,7 @@ s32 e1000_get_cable_length_82577(struct e1000_hw *hw)
                 I82577_DSTATUS_CABLE_LENGTH_SHIFT;
 
        if (length == E1000_CABLE_LENGTH_UNDEFINED)
-               ret_val = E1000_ERR_PHY;
+               ret_val = -E1000_ERR_PHY;
 
        phy->cable_length = length;