diff options
author | Sven Van Asbroeck <[email protected]> | 2021-04-08 20:39:04 -0400 |
---|---|---|
committer | Jakub Kicinski <[email protected]> | 2021-04-09 12:49:38 -0700 |
commit | 3bc41d6d2721d5168a8f7fea34028a5332068f5e (patch) | |
tree | 49f60782ab19f86874a50804a9f7d07addba04fb /net/tipc/crypto.c | |
parent | 864db232dc7036aa2de19749c3d5be0143b24f8f (diff) |
lan743x: fix ethernet frame cutoff issue
The ethernet frame length is calculated incorrectly. Depending on
the value of RX_HEAD_PADDING, this may result in ethernet frames
that are too short (cut off at the end), or too long (garbage added
to the end).
Fix by calculating the ethernet frame length correctly. For added
clarity, use the ETH_FCS_LEN constant in the calculation.
Many thanks to Heiner Kallweit for suggesting this solution.
Suggested-by: Heiner Kallweit <[email protected]>
Fixes: 3e21a10fdea3 ("lan743x: trim all 4 bytes of the FCS; not just 2")
Link: https://lore.kernel.org/lkml/[email protected]/
Signed-off-by: Sven Van Asbroeck <[email protected]>
Reviewed-by: George McCollister <[email protected]>
Tested-by: George McCollister <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'net/tipc/crypto.c')
0 files changed, 0 insertions, 0 deletions