linux-uconsole/include/acpi
Heikki Krogerus 6619f538b3 UPSTREAM: device property: Avoid potential dereferences of invalid pointers
Since fwnode may hold ERR_PTR(-ENODEV) or it may be NULL,
the fwnode type checks is_of_node(), is_acpi_node() and is
is_pset_node() need to consider it. Using IS_ERR_OR_NULL()
to check it.

Fixes: 0d67e0fa16 (device property: fix for a case of use-after-free)
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
[ rjw: Subject & changelog ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

(cherry picked from commit 0224a4a30b)
from v4.7-rc1

BUG=b:62359918
TEST=No regression in camera functionality
TEST=Kernel builds and boots

Change-Id: I7784c41117c3fe0b4661bb08f0ef7b734a6c6780
Signed-off-by: Nathan Ciobanu <nathan.d.ciobanu@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/528596
Commit-Ready: Nathan D Ciobanu <nathan.d.ciobanu@intel.com>
Tested-by: Yong Zhi <yong.zhi@intel.com>
Reviewed-by: Tomasz Figa <tfiga@chromium.org>
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
2017-08-30 14:50:28 +08:00
..
platform ACPI: Enable build of AML interpreter debugger 2015-10-22 02:05:05 +02:00
acbuffer.h ACPICA: Disassembler: Remove duplicate code in _PLD processing. 2015-08-25 23:11:30 +02:00
acconfig.h ACPICA: Make the max-number-of-loops runtime configurable 2015-08-25 23:11:32 +02:00
acexcep.h ACPICA: Improve typechecking, both compile-time and runtime 2015-10-22 02:01:12 +02:00
acnames.h ACPICA: Utilities: Add _CLS processing 2015-07-01 23:17:53 +02:00
acoutput.h ACPICA: Executer: Add option to bypass opcode tracing 2015-07-23 23:09:07 +02:00
acpi.h ACPICA: Update Copyright headers to 2015 2015-02-05 15:31:43 +01:00
acpi_bus.h UPSTREAM: device property: Avoid potential dereferences of invalid pointers 2017-08-30 14:50:28 +08:00
acpi_drivers.h ACPI: Remove FSF mailing addresses 2015-07-08 02:27:32 +02:00
acpi_io.h ACPI: fix acpi_os_ioremap for arm64 2015-03-25 11:49:30 +00:00
acpi_lpat.h ACPI / LPAT: Common table processing functions 2015-01-29 21:02:10 +08:00
acpi_numa.h ACPI / numa: Make __acpi_map_pxm_to_node(), acpi_get_pxm() static 2014-02-03 10:39:38 -07:00
acpiosxf.h ACPICA: Debugger: Add thread ID support so that single step mode can only apply to the debugger thread 2015-10-22 02:05:05 +02:00
acpixf.h ACPICA: Update version to 20150930 2015-10-22 02:05:06 +02:00
acrestyp.h ACPICA: Update Copyright headers to 2015 2015-02-05 15:31:43 +01:00
actbl.h ACPICA: Namespace: Add support of OSDT table 2015-07-01 23:17:54 +02:00
actbl1.h ACPICA: Update NFIT table to rename a flags field 2015-10-22 02:01:12 +02:00
actbl2.h ACPICA: iASL: Add support for TCPA Server Table 2015-07-23 23:09:08 +02:00
actbl3.h ACPICA: Update definitions for the TCPA and TPM2 ACPI tables 2015-07-01 23:17:56 +02:00
actypes.h ACPICA: Debugger: Add option to display namespace summary/counts 2015-08-25 23:11:32 +02:00
acuuid.h ACPICA: Fix for ill-formed GUID strings for NFIT tables. 2015-05-25 23:42:34 +02:00
apei.h acpi, apei, ghes: Factor out ioremap virtual memory for IRQ and NMI context. 2014-07-22 15:05:06 -07:00
button.h ACPI: Eliminate CONFIG_.*{, _MODULE} #ifdef in favor of IS_ENABLED() 2015-09-15 03:05:45 +02:00
cppc_acpi.h ACPI: Introduce CPU performance controls using CPPC 2015-10-12 22:49:55 +02:00
ghes.h ACPICA: Restore error table definitions to reduce code differences between Linux and ACPICA upstream. 2014-06-16 22:33:50 +02:00
hed.h ACPI Hardware Error Device (PNP0C33) support 2010-05-19 22:40:24 -04:00
pdc_intel.h
processor.h CPPC: Probe for CPPC tables for each ACPI Processor object 2015-10-12 23:08:04 +02:00
reboot.h
video.h ACPI: Eliminate CONFIG_.*{, _MODULE} #ifdef in favor of IS_ENABLED() 2015-09-15 03:05:45 +02:00