staging: silicom: pointless check removal
authorAlan Cox <alan@linux.intel.com>
Thu, 11 Oct 2012 16:23:18 +0000 (17:23 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 22 Oct 2012 22:44:30 +0000 (15:44 -0700)
bus_info is an array not a pointer. Fix silly if check

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/silicom/bp_mod.c

index 3cfd0516adfa5ea6e7e8986b0150eb09711081c2..f579f143f85fc5045ed6e9047fcd819fdf342b82 100644 (file)
@@ -5454,8 +5454,6 @@ static void if_scan_init(void)
                        dev->ethtool_ops->get_drvinfo(dev, &drvinfo);
                } else
                        continue;
-               if (!drvinfo.bus_info)
-                       continue;
                if (!strcmp(drvinfo.bus_info, "N/A"))
                        continue;
                memcpy(&cbuf, drvinfo.bus_info, 32);
@@ -7703,13 +7701,8 @@ get_bypass_slave_pfs(char *page, char **start, off_t off, int count,
                return len;
        }
        net_slave_dev = pbp_device_block_slave->ndev;
-       if (net_slave_dev) {
-               if (net_slave_dev)
-                       len = sprintf(page, "%s\n", net_slave_dev->name);
-               else
-                       len = sprintf(page, "fail\n");
-
-       }
+       if (net_slave_dev)
+               len = sprintf(page, "%s\n", net_slave_dev->name);
 
        *eof = 1;
        return len;