drivers: net: lmc: fix case value for target abort error
authorColin Ian King <colin.king@canonical.com>
Wed, 1 Aug 2018 17:22:41 +0000 (18:22 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 2 Aug 2018 21:41:43 +0000 (14:41 -0700)
Current value for a target abort error is 0x010, however, this value
should in fact be 0x002.  As it stands, the range of error is 0..7 so
it is currently never being detected.  This bug has been in the driver
since the early 2.6.12 days (or before).

Detected by CoverityScan, CID#744290 ("Logically dead code")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/wan/lmc/lmc_main.c

index 90a4ad9a2d081eb582570476a41a55f71e911dd6..b3a1b6f5c40648f755df770b0288627587e2ff66 100644 (file)
@@ -1362,7 +1362,7 @@ static irqreturn_t lmc_interrupt (int irq, void *dev_instance) /*fold00*/
             case 0x001:
                 printk(KERN_WARNING "%s: Master Abort (naughty)\n", dev->name);
                 break;
-            case 0x010:
+            case 0x002:
                 printk(KERN_WARNING "%s: Target Abort (not so naughty)\n", dev->name);
                 break;
             default: