linux/drivers/net/ethernet
Russell King 2fb04fdf30 net: smc91x: fix SMC accesses
Commit b70661c708 ("net: smc91x: use run-time configuration on all ARM
machines") broke some ARM platforms through several mistakes.  Firstly,
the access size must correspond to the following rule:

(a) at least one of 16-bit or 8-bit access size must be supported
(b) 32-bit accesses are optional, and may be enabled in addition to
    the above.

Secondly, it provides no emulation of 16-bit accesses, instead blindly
making 16-bit accesses even when the platform specifies that only 8-bit
is supported.

Reorganise smc91x.h so we can make use of the existing 16-bit access
emulation already provided - if 16-bit accesses are supported, use
16-bit accesses directly, otherwise if 8-bit accesses are supported,
use the provided 16-bit access emulation.  If neither, BUG().  This
exactly reflects the driver behaviour prior to the commit being fixed.

Since the conversion incorrectly cut down the available access sizes on
several platforms, we also need to go through every platform and fix up
the overly-restrictive access size: Arnd assumed that if a platform can
perform 32-bit, 16-bit and 8-bit accesses, then only a 32-bit access
size needed to be specified - not so, all available access sizes must
be specified.

This likely fixes some performance regressions in doing this: if a
platform does not support 8-bit accesses, 8-bit accesses have been
emulated by performing a 16-bit read-modify-write access.

Tested on the Intel Assabet/Neponset platform, which supports only 8-bit
accesses, which was broken by the original commit.

Fixes: b70661c708 ("net: smc91x: use run-time configuration on all ARM machines")
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-08-28 23:44:55 -04:00
..
3com treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
8390 net: ethernet: ax88796: avoid null pointer dereference 2016-08-01 13:32:51 -07:00
adaptec treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
adi net: ethernet: adi: bfin_mac: use phy_ethtool_{get|set}_link_ksettings 2016-07-17 23:22:02 -07:00
aeroflex aeroflex/greth: fix warning about unused variable 2016-05-20 18:33:37 -07:00
agere Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2016-07-24 00:53:32 -04:00
allwinner net: ethernet: sun4i-emac: use phy_ethtool_{get|set}_link_ksettings 2016-06-22 16:22:41 -04:00
alteon
altera ethernet: altera: add missing of_node_put 2016-08-01 21:42:57 -07:00
amd net: amd-xgbe: use correct format specifier 2016-08-01 13:32:51 -07:00
apm net: xgene: fix maybe-uninitialized variable 2016-08-03 11:52:16 -07:00
apple
arc net: arc_emac: add missing of_node_put() in arc_emac_probe() 2016-08-06 00:07:38 -04:00
atheros Merge branch 'pci/msi-affinity' into next 2016-08-01 12:34:01 -05:00
aurora ethernet: aurora: nb8800: add missing of_node_put after calling of_parse_phandle 2016-08-01 21:43:47 -07:00
broadcom net: bgmac: fix reversed check for MII registration error 2016-08-18 23:23:41 -07:00
brocade net: bna: use correct type specifier (2) 2016-08-01 13:32:52 -07:00
cadence net: macb: Correct CAPS mask 2016-08-06 20:53:06 -04:00
calxeda
cavium net: thunderx: Fix OOPs with ethtool --register-dump 2016-08-18 21:16:37 -07:00
chelsio cxgb4: Fixes resource allocation for ULD's in kdump kernel 2016-08-18 23:06:44 -07:00
cirrus net: cx89x0: Add DT support 2016-06-15 12:17:57 -07:00
cisco net: enic: use correct type specifier 2016-08-01 13:32:52 -07:00
davicom dm9000: Fix irq trigger type setup on non-dt platforms 2016-08-09 15:08:22 -07:00
dec net: tulip: fix spelling mistake: "attemping" -> "attempting" 2016-07-30 23:13:51 -07:00
dlink treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
emulex be2net: perform temperature query in adapter regardless of its interface state 2016-07-26 23:17:42 -07:00
ezchip Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2016-07-24 00:53:32 -04:00
faraday net/faraday: Disallow using reversed MAC address from hardware 2016-07-20 21:05:18 -07:00
freescale gianfar: fix size of scatter-gathered frames 2016-08-23 16:49:00 -07:00
fujitsu treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
hisilicon net: hns: dereference ppe_cb->ppe_common_cb if it is non-null 2016-08-26 11:44:56 -07:00
hp treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
i825xx treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
ibm ibmvnic: Fix passive VNIC server login process 2016-07-09 17:42:11 -04:00
intel i40e: Change some init flow for the client 2016-08-25 16:59:30 -07:00
marvell ethernet: marvell: pxa168_eth: add missing of_node_put after calling of_parse_phandle 2016-08-01 21:43:48 -07:00
mediatek net: ethernet: mediatek: fix runtime warning raised by inconsistent struct device pointers passed to DMA API 2016-08-15 23:02:44 -07:00
mellanox net/mlx5: Increase number of ethtool steering priorities 2016-08-28 23:24:16 -04:00
micrel drivers: net: Don't print unpopulated net_device name 2016-05-17 12:30:19 -04:00
microchip enc28j60: Fix race condition in enc28j60 driver 2016-07-02 14:48:14 -04:00
moxa treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
myricom myri10ge: fix sleeping with bh disabled 2016-04-28 14:21:14 -04:00
natsemi treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
neterion net: s2io: simplify logical constraint 2016-08-01 13:32:52 -07:00
netronome nfp: check idx is -ENOSPC before using it is an index 2016-07-11 13:52:00 -07:00
nuvoton treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
nvidia
nxp net: lpc_eth: Check clk_prepare_enable() error 2016-08-23 17:10:16 -07:00
oki-semi pch_gbe: replace private tx ring lock with common netif_tx_lock 2016-04-28 17:19:58 -04:00
packetengines treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
pasemi net: ethernet: pasemi_mac: use phy_ethtool_{get|set}_link_ksettings 2016-07-15 16:41:34 -07:00
qlogic qed: FLR of active VFs might lead to FW assert 2016-08-22 18:11:38 -07:00
qualcomm treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
rdc net: r6040: Bump version and date 2016-07-05 00:10:30 -07:00
realtek 8139cp: Fix one possible deadloop in cp_rx_poll 2016-08-25 17:02:48 -07:00
renesas ethernet: renesas: sh_eth: add missing of_node_put after calling of_parse_phandle 2016-08-01 21:43:49 -07:00
rocker net: add dev arg to ndo_neigh_construct/destroy 2016-07-05 09:06:28 -07:00
samsung net: ethernet: sxgbe: use phy_ethtool_{get|set}_link_ksettings 2016-06-28 09:12:35 -04:00
seeq treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
sfc sfc: fix potential stack corruption from running past stat bitmask 2016-08-26 21:40:44 -07:00
sgi treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
silan
sis treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
smsc net: smc91x: fix SMC accesses 2016-08-28 23:44:55 -04:00
stmicro ethernet: stmicro: stmmac: add missing of_node_put after calling of_parse_phandle 2016-08-01 21:43:49 -07:00
sun treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
synopsys dwc_eth_qos: fix interrupt enable race 2016-08-23 17:11:05 -07:00
tehuti net: tehuti: fix typo: "eneble" -> "enable" 2016-08-21 15:21:36 -07:00
ti drivers: net: cpsw: fix kmemleak false-positive reports for sk buffers 2016-08-09 14:54:59 -07:00
tile timers, driver/net/ethernet/tile: Initialize the egress timer as pinned 2016-07-07 10:25:14 +02:00
toshiba net: ethernet: tc35815: use phy_ethtool_{get|set}_link_ksettings 2016-07-15 16:41:33 -07:00
tundra net/ethernet: tundra: fix dump_eth_one warning in tsi108_eth 2016-08-08 13:08:21 -07:00
via treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
wiznet net: ethernet: wiznet: Remove create_workqueue 2016-06-02 12:15:17 -07:00
xilinx net: xilinx: emaclite: Fallback to random MAC address. 2016-08-20 22:11:29 -07:00
xircom ethernet: xircom: fix spelling mistakes on "excessive collisions" 2016-06-27 04:19:14 -04:00
xscale net: ethernet: ixp4xx_eth: use phy_ethtool_{get|set}_link_ksettings 2016-07-04 15:59:52 -07:00
Kconfig
Makefile
dnet.c net: ethernet: dnet: use phy_ethtool_{get|set}_link_ksettings 2016-06-28 05:10:26 -04:00
dnet.h net: ethernet: dnet: use phydev from struct net_device 2016-06-28 05:10:26 -04:00
ec_bhf.c
ethoc.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2016-07-24 00:53:32 -04:00
fealnx.c treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
jme.c
jme.h
korina.c treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
lantiq_etop.c net: ethernet: lantiq_etop: use phy_ethtool_{get|set}_link_ksettings 2016-07-04 15:59:51 -07:00
netx-eth.c drivers: net: Don't print unpopulated net_device name 2016-05-17 12:30:19 -04:00