1
0
Fork 0
Fork of alistair23 Linux kernel for reMarkable from https://github.com/alistair23/linux
 
 
 
 
 
 
Go to file
Petr Štetiar 5503a6889f net: usb: smsc: fix warning reported by kbuild test robot
This patch fixes following 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.

Fixes: adfb3cb2c5 ("net: usb: 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>
Reviewed-by: Woojung Huh <woojung.huh@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-05-07 12:22:47 -07:00
Documentation Documentation: net: dsa: sja1105: Add info about supported traffic modes 2019-05-05 21:52:42 -07:00
LICENSES LICENSES: Add GCC runtime library exception text 2019-01-16 14:54:15 -07:00
arch powerpc: tsi108: support of_get_mac_address new ERR_PTR error 2019-05-05 21:47:07 -07:00
block bfq: update internal depth state when queue depth changes 2019-04-13 19:08:22 -06:00
certs kexec, KEYS: Make use of platform keyring for signature verify 2019-02-04 17:34:07 -05:00
crypto Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-05-02 22:14:21 -04:00
drivers net: usb: smsc: fix warning reported by kbuild test robot 2019-05-07 12:22:47 -07:00
fs Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-05-02 22:14:21 -04:00
include net: dsa: sja1105: Add support for traffic through standalone ports 2019-05-05 21:52:42 -07:00
init init: initialize jump labels before command line option parsing 2019-04-19 09:46:05 -07:00
ipc rhashtable: use bit_spin_locks to protect hash bucket. 2019-04-07 19:12:12 -07:00
kernel Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-05-02 22:14:21 -04:00
lib netlink: add validation of NLA_F_NESTED flag 2019-05-04 01:27:11 -04:00
mm mm/page_alloc.c: fix never set ALLOC_NOFRAGMENT flag 2019-04-26 09:18:05 -07:00
net net: dsa: support of_get_mac_address new ERR_PTR error 2019-05-07 12:22:47 -07:00
samples samples: bpf: add hbm sample to .gitignore 2019-04-25 23:38:00 +02:00
scripts kbuild: tolerate missing pahole when generating BTF 2019-05-06 10:18:47 +02:00
security selinux/stable-5.1 PR 20190429 2019-04-30 08:38:02 -07:00
sound ALSA: hda/realtek - add two more pin configuration sets to quirk table 2019-04-17 10:41:38 +02:00
tools Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next 2019-05-07 09:29:16 -07:00
usr user/Makefile: Fix typo and capitalization in comment section 2018-12-11 00:18:03 +09:00
virt KVM: fix spectrev1 gadgets 2019-04-16 15:38:07 +02:00
.clang-format Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-04-17 11:26:25 -07:00
.cocciconfig scripts: add Linux .cocciconfig for coccinelle 2016-07-22 12:13:39 +02:00
.get_maintainer.ignore
.gitattributes .gitattributes: set git diff driver for C source code files 2016-10-07 18:46:30 -07:00
.gitignore kbuild: Add support for DT binding schema checks 2018-12-13 09:41:32 -06:00
.mailmap Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next 2019-04-11 17:00:05 -07:00
COPYING COPYING: use the new text with points to the license files 2018-03-23 12:41:45 -06:00
CREDITS Char/Misc driver patches for 5.1-rc1 2019-03-06 14:18:59 -08:00
Kbuild Kbuild updates for v5.1 2019-03-10 17:48:21 -07:00
Kconfig kconfig: move the "Executable file formats" menu to fs/Kconfig.binfmt 2018-08-02 08:06:55 +09:00
MAINTAINERS wireless-drivers-next patches for 5.2 2019-05-05 10:20:53 -07:00
Makefile Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-05-02 22:14:21 -04:00
README Drop all 00-INDEX files from Documentation/ 2018-09-09 15:08:58 -06:00

README

Linux kernel
============

There are several guides for kernel developers and users. These guides can
be rendered in a number of formats, like HTML and PDF. Please read
Documentation/admin-guide/README.rst first.

In order to build the documentation, use ``make htmldocs`` or
``make pdfdocs``.  The formatted documentation can also be read online at:

    https://www.kernel.org/doc/html/latest/

There are various text files in the Documentation/ subdirectory,
several of them using the Restructured Text markup notation.

Please read the Documentation/process/changes.rst file, as it contains the
requirements for building and running the kernel, and information about
the problems which may result by upgrading your kernel.