net: replace more place to skb_put_[data:zero]
authoryuan linyu <Linyu.Yuan@alcatel-sbell.com.cn>
Sun, 18 Jun 2017 14:49:30 +0000 (22:49 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 20 Jun 2017 17:30:14 +0000 (13:30 -0400)
commitad941e693b24ad8b13c28382d323552ef6fb434b
treedd28b345cc39213a8a1796aabd9e5e30190808bd
parentde77b966ce8adcb4c58d50e2f087320d5479812a
net: replace more place to skb_put_[data:zero]

spatch file,
@@
expression skb, len, data;
type t;
@@
-memcpy((t *)skb_put(skb, len), data, len);
+skb_put_data(skb, data, len);

@@
identifier p;
expression skb, len, data;
type t;
@@
-p = (t *)memset(skb_put(skb, len), data, len);
+p = skb_put_zero(skb, len);

@@
expression skb, len, data;
type t;
@@
-memcpy((t *)__skb_put(skb, len), data, len);
+__skb_put_data(skb, data, len);

@@
identifier p;
expression skb, len, data;
type t;
@@
-p = (t *)memset(__skb_put(skb, len), data, len);
+p = __skb_put_zero(skb, len);

Signed-off-by: yuan linyu <Linyu.Yuan@alcatel-sbell.com.cn>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/cdc_ncm.c
drivers/net/wireless/realtek/rtlwifi/rtl8192c/fw_common.c
drivers/net/wireless/realtek/rtlwifi/rtl8192de/fw.c
drivers/net/wireless/realtek/rtlwifi/rtl8192ee/fw.c
drivers/net/wireless/realtek/rtlwifi/rtl8723ae/fw.c
drivers/net/wireless/realtek/rtlwifi/rtl8723be/fw.c
drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c