summaryrefslogtreecommitdiffstats
path: root/drivers/staging/rtl8712/osdep_service.h
diff options
context:
space:
mode:
authorAya Mahfouz2015-03-03 15:08:38 +0100
committerGreg Kroah-Hartman2015-03-06 18:54:34 +0100
commit47f0585a20e28bdd3155823afcff209615c902ff (patch)
tree10f7284cfb82202cce4f19bc51fe0c0bae4f015f /drivers/staging/rtl8712/osdep_service.h
parentstaging: rtl8192u: replace memset(x,0,ETH_ALEN) by eth_zero_addr(x) (diff)
downloadkernel-qcow2-linux-47f0585a20e28bdd3155823afcff209615c902ff.tar.gz
kernel-qcow2-linux-47f0585a20e28bdd3155823afcff209615c902ff.tar.xz
kernel-qcow2-linux-47f0585a20e28bdd3155823afcff209615c902ff.zip
staging: rtl8192u: ieee80211: replace memset(x,0,ETH_ALEN) by eth_zero_addr(x)
eth_zero_addr() is a wrapper function for memset if 0 is going to be assigned to a mac address. The replacement was done by the following coccinelle script: @header@ @@ #include <linux/etherdevice.h> @eth_zero_addr@ expression e; @@ -memset(e,0,ETH_ALEN); +eth_zero_addr(e); @eth_broadcast_addr@ identifier e; @@ -memset(e,\(0xff\|0xFF\|255\),ETH_ALEN); +eth_broadcast_addr(e); @linux_header depends on !header && (eth_zero_addr || eth_broadcast_addr) @ @@ + #include <linux/etherdevice.h> + @special_header depends on !header && !linux_header && (eth_zero_addr || eth_broadcast_addr) @ @@ + + #include <linux/etherdevice.h> + @custom_header depends on !header && !linux_header && !special_header && (eth_zero_addr || eth_broadcast_addr) @ @@ + + #include <linux/etherdevice.h> Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtl8712/osdep_service.h')
0 files changed, 0 insertions, 0 deletions