diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2012-06-09 05:17:01 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-06-11 11:47:51 -0400 |
commit | b5b86a4d99f48e5ac28c19ae2a00415e26a7ac1a (patch) | |
tree | 28795e577718539aff808d2b429668ab1ee0c158 /drivers/staging/et131x | |
parent | 397d3e6029cb816d7a9a78531528a62d08c70d3f (diff) |
Staging: et131x: fix | vs & typos
These two places seem like they should be using bitwise OR instead of
bitwise AND. The first one is a noop which is equivalent to:
imr |= (0x0100 & 0x0004 & 0x0001);
The second is sets lcr2 to zero instead of just clearing the high bits.
lcr2 &= (0x00F0 & 0x000F);
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/et131x')
-rw-r--r-- | drivers/staging/et131x/et131x.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/staging/et131x/et131x.c b/drivers/staging/et131x/et131x.c index cf02336ffbd..8f3fc5f85ec 100644 --- a/drivers/staging/et131x/et131x.c +++ b/drivers/staging/et131x/et131x.c | |||
@@ -1766,8 +1766,8 @@ static void et131x_xcvr_init(struct et131x_adapter *adapter) | |||
1766 | /* Set the link status interrupt only. Bad behavior when link status | 1766 | /* Set the link status interrupt only. Bad behavior when link status |
1767 | * and auto neg are set, we run into a nested interrupt problem | 1767 | * and auto neg are set, we run into a nested interrupt problem |
1768 | */ | 1768 | */ |
1769 | imr |= (ET_PHY_INT_MASK_AUTONEGSTAT & | 1769 | imr |= (ET_PHY_INT_MASK_AUTONEGSTAT | |
1770 | ET_PHY_INT_MASK_LINKSTAT & | 1770 | ET_PHY_INT_MASK_LINKSTAT | |
1771 | ET_PHY_INT_MASK_ENABLE); | 1771 | ET_PHY_INT_MASK_ENABLE); |
1772 | 1772 | ||
1773 | et131x_mii_write(adapter, PHY_INTERRUPT_MASK, imr); | 1773 | et131x_mii_write(adapter, PHY_INTERRUPT_MASK, imr); |
@@ -1783,7 +1783,7 @@ static void et131x_xcvr_init(struct et131x_adapter *adapter) | |||
1783 | if ((adapter->eeprom_data[1] & 0x4) == 0) { | 1783 | if ((adapter->eeprom_data[1] & 0x4) == 0) { |
1784 | et131x_mii_read(adapter, PHY_LED_2, &lcr2); | 1784 | et131x_mii_read(adapter, PHY_LED_2, &lcr2); |
1785 | 1785 | ||
1786 | lcr2 &= (ET_LED2_LED_100TX & ET_LED2_LED_1000T); | 1786 | lcr2 &= (ET_LED2_LED_100TX | ET_LED2_LED_1000T); |
1787 | lcr2 |= (LED_VAL_LINKON_ACTIVE << LED_LINK_SHIFT); | 1787 | lcr2 |= (LED_VAL_LINKON_ACTIVE << LED_LINK_SHIFT); |
1788 | 1788 | ||
1789 | if ((adapter->eeprom_data[1] & 0x8) == 0) | 1789 | if ((adapter->eeprom_data[1] & 0x8) == 0) |