]> git.baikalelectronics.ru Git - kernel.git/commit
ftgmac100: Directly receive into sk_buffs
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 6 Apr 2017 01:02:49 +0000 (11:02 +1000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 6 Apr 2017 22:39:45 +0000 (15:39 -0700)
commitf1a15128d149d64b31a9a870ce25acb1606d8764
tree0c0904d4272c2994507394fe75298c22092f6c00
parent75bdb5ac0cf492b268451f8a9e8469d05cf805cc
ftgmac100: Directly receive into sk_buffs

The current driver receive path allocates pages and stashes
them into SKB fragments. This is not particularly useful as
we don't support jumbo frames (which wouldn't be great with
the small FIFOs on all the known implementations) anyway.

It also makes us flush the caches and allocate more memory
for RX than necessary.

So set our RX buf to our max packet size instead (which we
bump to 1536 bytes to account for packets with vlan tags
etc...) like most other ethernet drivers.

Then allocate skbs when populating the receive ring and DMA
directly into them.

This simplifies the RX path further.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/faraday/ftgmac100.c