]> git.baikalelectronics.ru Git - kernel.git/commit
net: enetc: add a dedicated is_eof bit in the TX software BD
authorVladimir Oltean <vladimir.oltean@nxp.com>
Wed, 31 Mar 2021 20:08:51 +0000 (23:08 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 31 Mar 2021 21:57:44 +0000 (14:57 -0700)
commit18e4c12df3ad9ad92d0bccd09948c44d92be87fb
tree1596ce5b22975867d5825f75161da9f1e122d8c6
parent38a2bee2d616c707cf03c6c81b5b8430553a7f3b
net: enetc: add a dedicated is_eof bit in the TX software BD

In the transmit path, if we have a scatter/gather frame, it is put into
multiple software buffer descriptors, the last of which has the skb
pointer populated (which is necessary for rearming the TX MSI vector and
for collecting the two-step TX timestamp from the TX confirmation path).

At the moment, this is sufficient, but with XDP_TX, we'll need to
service TX software buffer descriptors that don't have an skb pointer,
however they might be final nonetheless. So add a dedicated bit for
final software BDs that we populate and check explicitly. Also, we keep
looking just for an skb when doing TX timestamping, because we don't
want/need that for XDP.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/freescale/enetc/enetc.c
drivers/net/ethernet/freescale/enetc/enetc.h