liquidio: fix duplicated code for different branches
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Sun, 13 Aug 2017 01:38:55 +0000 (20:38 -0500)
committerDavid S. Miller <davem@davemloft.net>
Mon, 14 Aug 2017 17:58:09 +0000 (10:58 -0700)
commitb5e7dc47425860172eec6e1116ace7759d13b999
tree1daae85740ce7e5aa329e0ed9061064ec3f80302
parentda1542b01b38ba29e0d28b1ef980071e7d38d6d4
liquidio: fix duplicated code for different branches

Refactor code in order to avoid identical code for different branches.

This issue was detected with the help of Coccinelle.

Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Acked-by: Felix Manlunas <felix.manlunas@cavium.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/cavium/liquidio/lio_ethtool.c