linux/drivers/acpi
Rafael J. Wysocki 35bcda8ac0 ACPI / init: Fix the ordering of acpi_reserve_resources()
commit b9a5e5e18f upstream.

Since acpi_reserve_resources() is defined as a device_initcall(),
there's no guarantee that it will be executed in the right order
with respect to the rest of the ACPI initialization code.  On some
systems this leads to breakage if, for example, the address range
that should be reserved for the ACPI fixed registers is given to
the PCI host bridge instead if the race is won by the wrong code
path.

Fix this by turning acpi_reserve_resources() into a void function
and calling it directly from within the ACPI initialization sequence.

Reported-and-tested-by: George McCollister <george.mccollister@gmail.com>
Link: http://marc.info/?t=143092384600002&r=1&w=2
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2015-06-06 08:19:39 -07:00
..
acpica ACPICA: Utilities: Cleanup to remove useless ACPI_PRINTF/FORMAT_xxx helpers. 2015-05-17 09:53:51 -07:00
apei ACPI and power management updates for 3.14-rc1 2014-01-24 15:51:02 -08:00
ac.c Revert "ACPI / AC: Remove AC's proc directory." 2014-07-17 16:21:03 -07:00
acpi_cmos_rtc.c ACPI / RTC: Fix CMOS RTC opregion handler accesses to wrong addresses 2014-10-05 14:52:15 -07:00
acpi_extlog.c ACPI and power management updates for 3.14-rc1 2014-01-24 15:51:02 -08:00
acpi_ipmi.c ACPI / IPMI: Cleanup coding styles 2013-09-30 19:46:13 +02:00
acpi_lpss.c Revert "ACPI: Add BayTrail SoC GPIO and LPSS ACPI IDs" 2014-01-18 14:04:58 +01:00
acpi_memhotplug.c ACPI / memhotplug: add parameter to disable memory hotplug 2014-01-16 01:43:49 +01:00
acpi_pad.c ACPI and power management updates for 3.14-rc1 2014-01-24 15:51:02 -08:00
acpi_platform.c ACPI: Revert "ACPI / AC: convert ACPI ac driver to platform bus" 2014-06-07 10:28:26 -07:00
acpi_processor.c ACPI / processor: do not mark present at boot but not onlined CPU as onlined 2014-06-07 10:28:26 -07:00
battery.c ACPI / battery: Retry to get battery information if failed during probing 2014-07-17 16:21:06 -07:00
bgrt.c acpi: bgrt: fix build error due to attribute change 2013-08-22 08:34:39 -07:00
blacklist.c ACPI: blacklist win8 OSI for Dell Inspiron 7737 2014-06-07 10:28:26 -07:00
bus.c ACPI: Fix conflict between customized DSDT and DSDT local copy 2014-06-30 20:11:58 -07:00
button.c ACPI / button: Add ACPI Button event via netlink routine 2014-04-26 17:19:03 -07:00
cm_sbs.c ACPI: Revert "ACPI: Remove CONFIG_ACPI_PROCFS_POWER and cm_sbsc.c" 2014-06-07 10:28:26 -07:00
container.c ACPI / hotplug: Generate online uevents for ACPI containers 2014-10-05 14:52:16 -07:00
custom_method.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00
debugfs.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00
device_pm.c ACPI / PM: Fix PM initialization for devices that are not present 2015-01-16 06:59:34 -08:00
dock.c ACPI / dock: Make 'docked' sysfs attribute work as documented 2014-02-15 01:29:06 +01:00
ec.c ACPI / EC: Fix race condition in ec_transaction_completed() 2014-07-17 16:21:04 -07:00
ec_sys.c ACPI / EC: Mark the function acpi_ec_add_debugfs() as static in ec_sys.c 2014-01-06 00:13:22 +01:00
event.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00
fan.c ACPI / fan: fix fan driver compile error when CONFIG_PM_SLEEP is undefined 2014-02-13 15:13:44 +01:00
glue.c ACPI / bind: Move acpi_get_child() to drivers/ide/ide-acpi.c 2013-12-07 01:05:50 +01:00
hed.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00
internal.h Merge branch 'acpi-hotplug' 2014-01-12 23:45:04 +01:00
Kconfig ACPI: Revert "ACPI: Remove CONFIG_ACPI_PROCFS_POWER and cm_sbsc.c" 2014-06-07 10:28:26 -07:00
Makefile ACPI: Revert "ACPI: Remove CONFIG_ACPI_PROCFS_POWER and cm_sbsc.c" 2014-06-07 10:28:26 -07:00
numa.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00
nvs.c ACPI / NVS: Include appropriate header file in nvs.c 2014-01-06 00:13:22 +01:00
osl.c ACPI / init: Fix the ordering of acpi_reserve_resources() 2015-06-06 08:19:39 -07:00
pci_irq.c ACPI / PCI: Fix memory leak in acpi_pci_irq_enable() 2014-02-18 15:47:23 +01:00
pci_link.c ACPI / PCI: Include appropriate header file in pci_link.c 2014-01-06 00:13:22 +01:00
pci_root.c ACPI and power management updates for 3.14-rc1 2014-01-24 15:51:02 -08:00
pci_slot.c ACPI / PCI: Include appropriate header file in pci_slot.c 2014-01-06 00:13:22 +01:00
power.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00
proc.c ACPI / proc: remove unneeded NULL check 2014-02-05 01:06:21 +01:00
processor_core.c Merge branches 'acpi-processor', 'acpi-hotplug', 'acpi-init', 'acpi-pm' and 'acpica' 2014-01-29 11:47:18 +01:00
processor_driver.c ACPI / processor: use ACPI_COMPANION() to get ACPI device 2013-12-07 01:41:01 +01:00
processor_idle.c cpuidle: ACPI: do not overwrite name and description of C0 2015-04-19 10:11:08 +02:00
processor_perflib.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00
processor_thermal.c ACPI: correct minor typos 2013-12-07 01:38:45 +01:00
processor_throttling.c ACPI / processor: Rework processor throttling with work_on_cpu() 2014-02-27 00:21:05 +01:00
reboot.c Revert "ACPI: ignore FADT reset-reg-sup flag" 2012-04-20 11:19:35 -07:00
resource.c ACPI / resources: only reject zero length resources based at address zero 2014-07-17 16:21:03 -07:00
sbs.c Merge branches 'acpi-pm' and 'acpi-video' 2014-02-21 01:28:12 +01:00
sbshc.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00
sbshc.h ACPI: SBS: Ignore alarms coming from unknown devices 2007-12-14 15:14:06 -05:00
scan.c ACPI / scan: Annotate physical_node_lock in acpi_scan_is_offline() 2015-05-06 21:59:18 +02:00
sleep.c ACPI / sleep: Add extra checks for HW Reduced ACPI mode sleep states 2014-03-13 22:11:39 +01:00
sleep.h ACPI: Drop power resources driver 2013-01-17 14:11:06 +01:00
sysfs.c Merge branches 'acpi-processor', 'acpi-hotplug', 'acpi-init', 'acpi-pm' and 'acpica' 2014-01-29 11:47:18 +01:00
tables.c ACPI / tables: Return proper error codes from acpi_table_parse() and fix comment. 2014-01-06 12:33:06 +01:00
thermal.c ACPI / thermal: fix thermal driver compile error when CONFIG_PM_SLEEP is undefined 2014-02-13 15:13:45 +01:00
utils.c ACPI: add dynamic_debug support 2014-06-30 20:11:58 -07:00
video.c ACPI / video: Load the module even if ACPI is disabled 2015-03-18 13:31:34 +01:00
video_detect.c ACPI / video: Add systems that should favour native backlight interface 2014-02-20 01:33:40 +01:00
wakeup.c ACPI: Clean up inclusions of ACPI header files 2013-12-07 01:03:14 +01:00