linux_dsm_epyc7002/drivers/net/ethernet/sfc
Ben Hutchings 950c54df1e sfc: Reduce RX scatter buffer size, and reduce alignment if appropriate
efx_start_datapath() asserts that we can fit 2 RX scatter buffers plus
a software structure, each appropriately aligned, into a single page.
Where L1_CACHE_BYTES == 256 and PAGE_SIZE == 4096, which is the case
on s390, this assertion fails.

The current scatter buffer size is also not a multiple of 64 or 128,
which are more common cache line sizes.  If we can make both the start
and end of a scatter buffer cache-aligned, this will reduce the need
for read-modify-write operations on inter- processor links.

Fix the alignment by reducing EFX_RX_USR_BUF_SIZE to 2048 - 256 ==
1792.  (We could use 2048 - L1_CACHE_BYTES, but EFX_RX_USR_BUF_SIZE
also affects user-level networking where a larger amount of
housekeeping data may be needed.  Although this version of the driver
does not support user-level networking, I prefer to keep scattering
behaviour consistent with the out-of-tree version.)

This still doesn't fix the s390 build because like most architectures
it has NET_IP_ALIGN == 2.  When NET_IP_ALIGN != 0 we cannot achieve
cache line alignment at either the start or end of a scatter buffer,
so there is actually no point in padding the buffers to a multiple of
the cache line size.  All we need is 4-byte alignment of the network
header, so do that.

Adjust the assertions accordingly.

Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reported-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2013-05-14 11:32:04 -07:00
..
bitfield.h sfc: Add parentheses around use of bitfield macro arguments 2012-10-02 01:58:39 +01:00
efx.c sfc: Reduce RX scatter buffer size, and reduce alignment if appropriate 2013-05-14 11:32:04 -07:00
efx.h sfc: allocate more RX buffers per page 2013-03-07 20:22:15 +00:00
enum.h sfc: Add AER and EEH support for Siena 2013-03-07 20:22:04 +00:00
ethtool.c sfc: Enable RX DMA scattering where possible 2013-03-07 20:22:12 +00:00
falcon_boards.c sfc: Change state names to be clearer, and comment them 2012-08-24 20:10:18 +01:00
falcon_xmac.c sfc: Fix interface statistics running backward 2012-07-17 16:12:34 +01:00
falcon.c Merge branch 'i2c/for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux 2013-05-02 14:38:53 -07:00
filter.c sfc: Enable RX DMA scattering where possible 2013-03-07 20:22:12 +00:00
filter.h sfc: Remove EFX_FILTER_FLAG_RX_OVERRIDE_IP 2012-10-02 01:58:41 +01:00
io.h sfc: Remove confusing MMIO functions 2012-12-01 00:26:11 +00:00
Kconfig sfc: Fix Kconfig typo "----help---" 2013-03-18 10:50:23 +01:00
Makefile ptp: Enable clock drivers along with associated net/PHY drivers 2012-11-01 11:35:18 -04:00
mcdi_mac.c sfc: Add SR-IOV back-end support for SFC9000 family 2012-02-16 00:25:13 +00:00
mcdi_mon.c sfc: initialize dynamic sysfs attributes for lockdep 2012-07-19 10:48:08 -07:00
mcdi_pcol.h sfc: PTP changes to support improved UUID filtering mode 2013-03-07 20:21:55 +00:00
mcdi_phy.c sfc: Added support for new ethtool APIs for obtaining module eeprom 2012-05-10 03:10:46 +01:00
mcdi.c sfc: Fix naming of MTD partitions for FPGA bitfiles 2013-04-25 01:37:00 -04:00
mcdi.h sfc: Fix MCDI structure field lookup 2012-10-02 01:58:40 +01:00
mdio_10g.c sfc: Fix some formatting errors reported by checkpatch 2012-01-05 18:44:49 +00:00
mdio_10g.h
mtd.c sfc: Expose FPGA bitfile partition through MTD 2012-09-19 02:56:24 +01:00
net_driver.h sfc: Reduce RX scatter buffer size, and reduce alignment if appropriate 2013-05-14 11:32:04 -07:00
nic.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2013-03-20 12:46:26 -04:00
nic.h sfc: Really disable flow control while flushing 2012-12-01 00:26:09 +00:00
phy.h
ptp.c sfc: fix return value check in efx_ptp_probe_channel() 2013-05-08 13:13:30 -07:00
qt202x_phy.c sfc: Implement module EEPROM access for SFE4002 and SFN4112F 2012-05-10 03:10:54 +01:00
regs.h sfc: Correct MAC filter bitfield definitions 2012-02-16 00:11:31 +00:00
rx.c sfc: Reduce RX scatter buffer size, and reduce alignment if appropriate 2013-05-14 11:32:04 -07:00
selftest.c sfc: lock TX queues when calling netif_device_detach() 2012-12-01 02:37:35 +00:00
selftest.h sfc: Run event/IRQ self-test asynchronously when interface is brought up 2012-03-06 18:14:15 +00:00
siena_sriov.c sfc: Remove confusing MMIO functions 2012-12-01 00:26:11 +00:00
siena.c sfc: Enable RX DMA scattering where possible 2013-03-07 20:22:12 +00:00
spi.h sfc: Fix some formatting errors reported by checkpatch 2012-01-05 18:44:49 +00:00
tenxpress.c sfc: Fix some formatting errors reported by checkpatch 2012-01-05 18:44:49 +00:00
tx.c sfc: Add support for IEEE-1588 PTP 2012-09-19 02:54:12 +01:00
txc43128_phy.c sfc: Const-qualify static data as appropriate, partly prompted by checkpatch 2012-01-09 17:08:13 +00:00
vfdi.h sfc: Specify that the VFDI status page has page alignment and size 2012-02-22 20:48:07 +00:00
workarounds.h