kernel_optimize_test/drivers/net/ethernet
Johannes Berg b080db5853 networking: convert many more places to skb_put_zero()
There were many places that my previous spatch didn't find,
as pointed out by yuan linyu in various patches.

The following spatch found many more and also removes the
now unnecessary casts:

    @@
    identifier p, p2;
    expression len;
    expression skb;
    type t, t2;
    @@
    (
    -p = skb_put(skb, len);
    +p = skb_put_zero(skb, len);
    |
    -p = (t)skb_put(skb, len);
    +p = skb_put_zero(skb, len);
    )
    ... when != p
    (
    p2 = (t2)p;
    -memset(p2, 0, len);
    |
    -memset(p, 0, len);
    )

    @@
    type t, t2;
    identifier p, p2;
    expression skb;
    @@
    t *p;
    ...
    (
    -p = skb_put(skb, sizeof(t));
    +p = skb_put_zero(skb, sizeof(t));
    |
    -p = (t *)skb_put(skb, sizeof(t));
    +p = skb_put_zero(skb, sizeof(t));
    )
    ... when != p
    (
    p2 = (t2)p;
    -memset(p2, 0, sizeof(*p));
    |
    -memset(p, 0, sizeof(*p));
    )

    @@
    expression skb, len;
    @@
    -memset(skb_put(skb, len), 0, len);
    +skb_put_zero(skb, len);

Apply it to the tree (with one manual fixup to keep the
comment in vxlan.c, which spatch removed.)

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 11:48:35 -04:00
..
3com
8390
adaptec
adi
aeroflex
agere
alacritech
allwinner
alteon
altera
amazon
amd
apm
apple
aquantia
arc
atheros
aurora
broadcom
brocade
cadence
calxeda
cavium
chelsio
cirrus
cisco
davicom
dec
dlink
emulex
ezchip
faraday
freescale
fujitsu
hisilicon
hp
i825xx
ibm ibmvnic: Exit polling routine correctly during adapter reset 2017-06-15 14:29:00 -04:00
intel
marvell
mediatek
mellanox networking: convert many more places to skb_put_zero() 2017-06-16 11:48:35 -04:00
micrel
microchip
moxa
myricom
natsemi
neterion net: s2io: remove useless variable in fill_rx_buffers 2017-06-15 14:15:13 -04:00
netronome
nuvoton
nvidia
nxp
oki-semi
packetengines
pasemi
qlogic
qualcomm
rdc
realtek
renesas
rocker
samsung
seeq
sfc
sgi
silan
sis
smsc
stmicro
sun sunvnet: restrict advertized checksum offloads to just IP 2017-06-15 14:22:43 -04:00
synopsys
tehuti
ti
tile
toshiba
tundra
via
wiznet
xilinx
xircom
xscale
dnet.c
dnet.h
ec_bhf.c
ethoc.c
fealnx.c
jme.c
jme.h
Kconfig
korina.c
lantiq_etop.c
Makefile
netx-eth.c