staging: silicom: remove dead code
authorMichal Nazarewicz <mina86@mina86.com>
Fri, 29 Nov 2013 17:05:01 +0000 (18:05 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 3 Dec 2013 17:03:20 +0000 (09:03 -0800)
bus_info field of struct ethtool_drvinfo is an array thus it always
evaluates to true in a boolean context.  Therefore operation
depending on it being false will never be executed.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/silicom/bpctl_mod.c

index 39dc92a..20325f5 100644 (file)
@@ -135,8 +135,6 @@ static int bp_get_dev_idx_bsf(struct net_device *dev, int *index)
        else
                return -EOPNOTSUPP;
 
-       if (!drvinfo.bus_info)
-               return -ENODATA;
        if (!strcmp(drvinfo.bus_info, "N/A"))
                return -ENODATA;