The source for the Linux kernel used in Windows Subsystem for Linux 2 (WSL2)
Перейти к файлу
Guenter Roeck 04e216d19e hwmon: (pmbus) Move boolean error condition check to generating code
0-day rightfully complains about a sometimes uninitialized variable
in pmbus_get_boolean().

drivers/hwmon/pmbus/pmbus_core.c:903:13: warning:
		variable 'ret' is used uninitialized whenever 'if' condition is true
	} else if (!s1 || !s2) {

While that is technically true, it won't be hit in the field since the
condition indicates a programming error. Move the check of that condition
into the code generating the attribute entry, and refuse generating the
attribute if the condition is true. Swap the condition check in
pmbus_get_boolean() to ensure that static analyzers don't get a hiccup
(because we check if s1 and s2 are NULL, static analyzers may believe
that they can be NULL independently of each other).

Reported-by: kernel test robot <lkp@intel.com>
Cc: Alex Qiu <xqiu@google.com>
Reviewed-by: Alex Qiu <xqiu@google.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2020-09-23 09:42:41 -07:00
Documentation dt-bindings: hwmon: Add bindings for ADM1266 2020-09-23 09:42:41 -07:00
LICENSES
arch
block
certs
crypto
drivers hwmon: (pmbus) Move boolean error condition check to generating code 2020-09-23 09:42:41 -07:00
fs
include hwmon: (gsc-hwmon) add fan sensor 2020-09-23 09:42:41 -07:00
init
ipc
kernel Fix the seccomp syscall rewriting so that trace and audit see the 2020-09-20 15:37:15 -07:00
lib
mm
net
samples
scripts
security
sound
tools Fix noreturn detection for ignored sibling functions, from Josh 2020-09-20 15:31:04 -07:00
usr
virt
.clang-format
.cocciconfig
.get_maintainer.ignore
.gitattributes
.gitignore
.mailmap
COPYING
CREDITS
Kbuild
Kconfig
MAINTAINERS
Makefile Linux 5.9-rc6 2020-09-20 16:33:55 -07:00
README

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.