linux/drivers/net
Giuseppe CAVALLARO 0f1f88a875 stmmac: verify the dma_cfg platform fields
Recently the dma parameters that can be passed from the platform
have been moved from the plat_stmmacenet_data to the stmmac_dma_cfg.

In case of this new structure is not well allocated the driver can
fails. This is an example how this field is managed in ST platforms

static struct stmmac_dma_cfg gmac_dma_setting = {
        .pbl = 32,
};

static struct plat_stmmacenet_data stih415_ethernet_platform_data[] = {
	{
		.dma_cfg = &gmac_dma_setting,
		.has_gmac = 1,
[snip]

This patch so verifies that the dma_cfg passed from the platform.
In case of it is NULL there is no reason that the driver has to fail
and some default values can be passed. These are ok for all the
Synopsys chips and could impact on performances, only.

Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
cc: Viresh Kumar <viresh.kumar@st.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-04-19 20:08:59 -04:00
..
appletalk
arcnet
bonding bonding: start slaves with link down for ARP monitor 2012-04-19 15:25:02 -04:00
caif caif-hsi: Postpone init of HSI until open() 2012-04-13 11:37:37 -04:00
can net/can: use module_pci_driver 2012-04-16 21:08:18 +02:00
cris
dsa
ethernet stmmac: verify the dma_cfg platform fields 2012-04-19 20:08:59 -04:00
fddi
hamradio
hippi hippi: fix printk format in rrunner.c 2012-04-16 23:48:38 -04:00
hyperv
irda net: Fix spelling typo in net 2012-04-14 15:29:02 -04:00
phy net: Remove redundant spi driver bus initialization 2012-04-13 13:13:38 -04:00
plip
ppp Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2012-04-15 13:19:04 -04:00
slip
team team: add missed "statics" 2012-04-11 10:03:52 -04:00
tokenring net/tokenring: use module_pci_driver 2012-04-14 15:20:04 -04:00
usb Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2012-04-10 14:30:45 -04:00
vmxnet3
wan net: Fix spelling typo in net 2012-04-14 15:29:02 -04:00
wimax net: Fix spelling typo in net 2012-04-14 15:29:02 -04:00
wireless iwlwifi: Remove inconsistent and redundant declaration 2012-04-19 16:55:14 -04:00
xen-netback
dummy.c
eql.c
ifb.c
Kconfig
LICENSE.SRC
loopback.c
macvlan.c macvlan: add FDB bridge ops and macvlan flags 2012-04-15 13:06:05 -04:00
macvtap.c
Makefile
mdio.c
mii.c
netconsole.c
rionet.c
sb1000.c
Space.c
sungem_phy.c
tun.c
veth.c
virtio_net.c virtio-net: send gratuitous packets when needed 2012-04-15 03:23:31 -04:00
xen-netfront.c Two fixes for regressions: 2012-04-06 17:54:53 -07:00