summaryrefslogtreecommitdiffstats
path: root/drivers/i2c/busses
diff options
context:
space:
mode:
authorDoug Berger <opendmb@gmail.com>2020-06-24 18:14:55 -0700
committerSasha Levin <sashal@kernel.org>2020-06-30 23:17:13 -0400
commitd0dac4ebc8616fa4f2be0794e1b12cf196fdb472 (patch)
tree0e5db79572604eed42b986ad7281e88f7a47c264 /drivers/i2c/busses
parentb34e578f36b9d70f487cc97b52ab44b0748d00d7 (diff)
downloadlinux-stable-d0dac4ebc8616fa4f2be0794e1b12cf196fdb472.tar.gz
linux-stable-d0dac4ebc8616fa4f2be0794e1b12cf196fdb472.tar.bz2
linux-stable-d0dac4ebc8616fa4f2be0794e1b12cf196fdb472.zip
net: bcmgenet: use hardware padding of runt frames
[ Upstream commit 20d1f2d1b024f6be199a3bedf1578a1d21592bc5 ] When commit 474ea9cafc45 ("net: bcmgenet: correctly pad short packets") added the call to skb_padto() it should have been located before the nr_frags parameter was read since that value could be changed when padding packets with lengths between 55 and 59 bytes (inclusive). The use of a stale nr_frags value can cause corruption of the pad data when tx-scatter-gather is enabled. This corruption of the pad can cause invalid checksum computation when hardware offload of tx-checksum is also enabled. Since the original reason for the padding was corrected by commit 7dd399130efb ("net: bcmgenet: fix skb_len in bcmgenet_xmit_single()") we can remove the software padding all together and make use of hardware padding of short frames as long as the hardware also always appends the FCS value to the frame. Fixes: 474ea9cafc45 ("net: bcmgenet: correctly pad short packets") Signed-off-by: Doug Berger <opendmb@gmail.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/i2c/busses')
0 files changed, 0 insertions, 0 deletions