8139cp: Reduce duplicate csum/tso code in cp_start_xmit()
authorDavid Woodhouse <David.Woodhouse@intel.com>
Wed, 23 Sep 2015 08:44:57 +0000 (09:44 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 23 Sep 2015 21:47:12 +0000 (14:47 -0700)
commit0a5aeee0b79fa99d8e04c98dd4e87d4f52aa497b
treed21cdf659bb7a929d5548e495316f1a514354c29
parenta3b804043f490aeec57d8ca5baccdd35e6250857
8139cp: Reduce duplicate csum/tso code in cp_start_xmit()

We calculate the value of the opts1 descriptor field in three different
places. With two different behaviours when given an invalid packet to
be checksummed — none of them correct. Sort that out.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/realtek/8139cp.c