diff options
author | Colin Ian King <colin.king@canonical.com> | 2017-09-27 23:45:13 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-09-30 06:44:28 +0200 |
commit | 45c1fd61d5cead2ae23880e0677b8660ab9006a4 (patch) | |
tree | 9b0fd96152efab085b45b9919bf49ddfb073a239 /drivers/net/hamradio | |
parent | net-ipv6: add support for sockopt(SOL_IPV6, IPV6_FREEBIND) (diff) | |
download | linux-45c1fd61d5cead2ae23880e0677b8660ab9006a4.tar.xz linux-45c1fd61d5cead2ae23880e0677b8660ab9006a4.zip |
mkiss: remove redundant check on len being zero
The check on len is redundant as it is always greater than 1,
so just remove it and make the printk less complex.
Detected by CoverityScan, CID#1226729 ("Logically dead code")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/hamradio')
-rw-r--r-- | drivers/net/hamradio/mkiss.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/hamradio/mkiss.c b/drivers/net/hamradio/mkiss.c index aec6c26563cf..54bf8e6e4a09 100644 --- a/drivers/net/hamradio/mkiss.c +++ b/drivers/net/hamradio/mkiss.c @@ -477,7 +477,8 @@ static void ax_encaps(struct net_device *dev, unsigned char *icp, int len) cmd = 0; } ax->crcauto = (cmd ? 0 : 1); - printk(KERN_INFO "mkiss: %s: crc mode %s %d\n", ax->dev->name, (len) ? "set to" : "is", cmd); + printk(KERN_INFO "mkiss: %s: crc mode set to %d\n", + ax->dev->name, cmd); } spin_unlock_bh(&ax->buflock); netif_start_queue(dev); |