]> git.baikalelectronics.ru Git - kernel.git/commit
gianfar: Map head TxBD first
authorClaudiu Manoil <claudiu.manoil@freescale.com>
Tue, 23 Feb 2016 09:48:37 +0000 (11:48 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Feb 2016 21:55:58 +0000 (16:55 -0500)
commita2478f85a57cf0a94113e0f4a879364486acd78e
tree90b3be276b108488051352cf2d9b8c2c38ed3f11
parent75eb595f646cbd74988d2c87c163c1a6b29f2fc1
gianfar: Map head TxBD first

Move the mapping of the head BD before the mapping of fragments.
The TOE (h/w offload) decision logic block can be also moved up
(as the TOE flag belongs to the head BD), resulting in more
localized code (TOE logic vs BD mapping code blocks).
Note that, for this h/w, the R (status) bit for the head BD of a S/G
frame needs to be written last for a reliable transmission.
For the fragmented skb case, a local variable is used to temporarily
store the status info of the first BD, replacing a BD status read.
A merge of 2 "if(do_tstamp)" blocks was also possible.

Signed-off-by: Claudiu Manoil <claudiu.manoil@freescale.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/freescale/gianfar.c