linux_dsm_epyc7002/drivers/net
Petr Štetiar 1b9705d971 net: wireless: mt76: fix similar warning reported by kbuild test robot
This patch fixes following (similar) warning reported by kbuild test robot:

 In function ‘memcpy’,
  inlined from ‘smsc75xx_init_mac_address’ at drivers/net/usb/smsc75xx.c:778:3,
  inlined from ‘smsc75xx_bind’ at drivers/net/usb/smsc75xx.c:1501:2:
  ./include/linux/string.h:355:9: warning: argument 2 null where non-null expected [-Wnonnull]
  return __builtin_memcpy(p, q, size);
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
  drivers/net/usb/smsc75xx.c: In function ‘smsc75xx_bind’:
  ./include/linux/string.h:355:9: note: in a call to built-in function ‘__builtin_memcpy’

I've replaced the offending memcpy with ether_addr_copy, because I'm
100% sure, that of_get_mac_address can't return NULL as it returns valid
pointer or ERR_PTR encoded value, nothing else.

I'm hesitant to just change IS_ERR into IS_ERR_OR_NULL check, as this
would make the warning disappear also, but it would be confusing to
check for impossible return value just to make a compiler happy.

I'm now changing all occurencies of memcpy to ether_addr_copy after the
of_get_mac_address call, as it's very likely, that we're going to get
similar reports from kbuild test robot in the future.

Fixes: d31a36b5f4 ("net: wireless: support of_get_mac_address new ERR_PTR error")
Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-05-10 15:14:29 -07:00
..
appletalk ipv4: Prepare rtable for IPv6 gateway 2019-04-08 15:22:40 -07:00
arcnet
bonding netlink: make nla_nest_start() add NLA_F_NESTED flag 2019-04-27 17:03:44 -04:00
caif
can
dsa net: dsa: sja1105: Don't return a negative in u8 sja1105_stp_state_get 2019-05-08 13:57:50 -07:00
ethernet net: ethernet: fix similar warning reported by kbuild test robot 2019-05-10 15:14:29 -07:00
fddi
fjes
hamradio
hippi net: hippi:Fix misuse of %x in rrunner.c 2019-04-21 10:37:26 -07:00
hyperv Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-05-07 17:22:09 -07:00
ieee802154 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-05-02 22:14:21 -04:00
ipvlan
netdevsim netdevsim: Make nsim_num_vf static 2019-05-05 10:48:45 -07:00
phy net: phy: realtek: Change TX-delay setting for RGMII modes only 2019-05-08 16:31:38 -07:00
plip
ppp crypto: shash - remove shash_desc::flags 2019-04-25 15:38:12 +08:00
slip slip: make slhc_free() silently accept an error pointer 2019-04-26 18:19:09 -07:00
team genetlink: optionally validate strictly/dumps 2019-04-27 17:07:22 -04:00
usb aqc111: fix double endianness swap on BE 2019-05-09 09:35:40 -07:00
vmxnet3
wan
wimax wimax/i2400m: use struct_size() helper 2019-05-04 00:04:31 -04:00
wireless net: wireless: mt76: fix similar warning reported by kbuild test robot 2019-05-10 15:14:29 -07:00
xen-netback xen-netback: add reference from xenvif to backend_info to facilitate coredump analysis 2019-04-12 10:10:28 -07:00
dummy.c net: dummy: use generic helper to report timestamping info 2019-04-12 16:26:37 -07:00
eql.c
geneve.c
gtp.c genetlink: optionally validate strictly/dumps 2019-04-27 17:07:22 -04:00
ifb.c
Kconfig
LICENSE.SRC
loopback.c net: loopback: use generic helper to report timestamping info 2019-04-12 16:26:37 -07:00
macsec.c genetlink: optionally validate strictly/dumps 2019-04-27 17:07:22 -04:00
macvlan.c macvlan: disable SIOCSHWTSTAMP in container 2019-05-09 09:30:35 -07:00
macvtap.c
Makefile
mdio.c
mii.c
net_failover.c
netconsole.c
nlmon.c
ntb_netdev.c
rionet.c
sb1000.c sb1000: fix variable set but not used warnings 2019-04-18 17:06:15 -07:00
Space.c
sungem_phy.c
tap.c
thunderbolt.c net: thunderbolt: Unregister ThunderboltIP protocol handler when suspending 2019-04-18 11:18:51 +03:00
tun.c tuntap: synchronize through tfiles array instead of tun->numqueues 2019-05-09 09:21:42 -07:00
veth.c net: veth: use generic helper to report timestamping info 2019-04-12 16:26:37 -07:00
virtio_net.c virtio-net: Fix some minor formatting errors 2019-04-06 18:10:11 -07:00
vrf.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-04-25 23:52:29 -04:00
vsockmon.c
vxlan.c
xen-netfront.c xen-netfront: mark expected switch fall-through 2019-04-16 21:03:02 -07:00