17 Jul, 2008
2 commits
-
* 'linux-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6: (72 commits)
Revert "x86/PCI: ACPI based PCI gap calculation"
PCI: remove unnecessary volatile in PCIe hotplug struct controller
x86/PCI: ACPI based PCI gap calculation
PCI: include linux/pm_wakeup.h for device_set_wakeup_capable
PCI PM: Fix pci_prepare_to_sleep
x86/PCI: Fix PCI config space for domains > 0
Fix acpi_pm_device_sleep_wake() by providing a stub for CONFIG_PM_SLEEP=n
PCI: Simplify PCI device PM code
PCI PM: Introduce pci_prepare_to_sleep and pci_back_from_sleep
PCI ACPI: Rework PCI handling of wake-up
ACPI: Introduce new device wakeup flag 'prepared'
ACPI: Introduce acpi_device_sleep_wake function
PCI: rework pci_set_power_state function to call platform first
PCI: Introduce platform_pci_power_manageable function
ACPI: Introduce acpi_bus_power_manageable function
PCI: make pci_name use dev_name
PCI: handle pci_name() being const
PCI: add stub for pci_set_consistent_dma_mask()
PCI: remove unused arch pcibios_update_resource() functions
PCI: fix pci_setup_device()'s sprinting into a const buffer
...Fixed up conflicts in various files (arch/x86/kernel/setup_64.c,
arch/x86/pci/irq.c, arch/x86/pci/pci.h, drivers/acpi/sleep/main.c,
drivers/pci/pci.c, drivers/pci/pci.h, include/acpi/acpi_bus.h) from x86
and ACPI updates manually. -
No longer needed; replaced mostly with u32, but also acpi_size
where a type that changes 32/64 bit on 32/64-bit platforms is
required.v2: Fix a cast of a 32-bit int to a pointer in ACPI to avoid a compiler warning.
from David HowellsSigned-off-by: Bob Moore
Signed-off-by: Lin Ming
Signed-off-by: Len Brown
Signed-off-by: Andi Kleen
08 Jul, 2008
2 commits
-
* Introduce function acpi_pm_device_sleep_wake() for enabling and
disabling the system wake-up capability of devices that are power
manageable by ACPI.* Introduce function acpi_bus_can_wakeup() allowing other (dependent)
subsystems to check if ACPI is able to enable the system wake-up
capability of given device.* Introduce callback .sleep_wake() in struct pci_platform_pm_ops and
for the ACPI PCI 'driver' make it use acpi_pm_device_sleep_wake().* Introduce callback .can_wakeup() in struct pci_platform_pm_ops and
for the ACPI 'driver' make it use acpi_bus_can_wakeup().* Move the PME# handlig code out of pci_enable_wake() and split it
into two functions, pci_pme_capable() and pci_pme_active(),
allowing the caller to check if given device is capable of
generating PME# from given power state and to enable/disable the
device's PME# functionality, respectively.* Modify pci_enable_wake() to use the new ACPI callbacks and the new
PME#-related functions.* Drop the generic .platform_enable_wakeup() callback that is not
used any more.* Introduce device_set_wakeup_capable() that will set the
power.can_wakeup flag of given device.* Rework PCI device PM initialization so that, if given device is
capable of generating wake-up events, either natively through the
PME# mechanism, or with the help of the platform, its
power.can_wakeup flag is set and its power.should_wakeup flag is
unset as appropriate.* Make ACPI set the power.can_wakeup flag for devices found to be
wake-up capable by it.* Make the ACPI wake-up code enable/disable GPEs for devices that
have the wakeup.flags.prepared flag set (which means that their
wake-up power has been enabled).Signed-off-by: Rafael J. Wysocki
Signed-off-by: Jesse Barnes -
Introduce function acpi_bus_power_manageable() allowing other
(dependent) subsystems to check if ACPI is able to power manage given
device. This may be useful, for example, for PCI device power
management.Signed-off-by: Rafael J. Wysocki
Acked-by: Pavel Machek
Signed-off-by: Jesse Barnes
27 Apr, 2008
1 commit
-
This path adds validation of the MMCONFIG table against the ACPI reserved
motherboard resources. If the MMCONFIG table is found to be reserved in
ACPI, we don't bother checking the E820 table. The PCI Express firmware
spec apparently tells BIOS developers that reservation in ACPI is required
and E820 reservation is optional, so checking against ACPI first makes
sense. Many BIOSes don't reserve the MMCONFIG region in E820 even though
it is perfectly functional, the existing check needlessly disables MMCONFIG
in these cases.In order to do this, MMCONFIG setup has been split into two phases. If PCI
configuration type 1 is not available then MMCONFIG is enabled early as
before. Otherwise, it is enabled later after the ACPI interpreter is
enabled, since we need to be able to execute control methods in order to
check the ACPI reserved resources. Presently this is just triggered off
the end of ACPI interpreter initialization.There are a few other behavioral changes here:
- Validate all MMCONFIG configurations provided, not just the first one.
- Validate the entire required length of each configuration according to
the provided ending bus number is reserved, not just the minimum required
allocation.- Validate that the area is reserved even if we read it from the chipset
directly and not from the MCFG table. This catches the case where the
BIOS didn't set the location properly in the chipset and has mapped it
over other things it shouldn't have.This also cleans up the MMCONFIG initialization functions so that they
simply do nothing if MMCONFIG is not compiled in.Based on an original patch by Rajesh Shah from Intel.
[akpm@linux-foundation.org: many fixes and cleanups]
Signed-off-by: Robert Hancock
Signed-off-by: Andi Kleen
Cc: Andrew Morton
Cc: Greg KH
Signed-off-by: Thomas Gleixner
Tested-by: Andi Kleen
Cc: Rajesh Shah
Cc: Jesse Barnes
Acked-by: Linus Torvalds
Cc: Andi Kleen
Cc: Greg KH
Signed-off-by: Ingo Molnar
Signed-off-by: Andrew Morton
Signed-off-by: Thomas Gleixner
16 Apr, 2008
1 commit
-
List could have become empty after the unlocked check that was made earlier,
so check again inside the lock.Should fix https://bugzilla.redhat.com/show_bug.cgi?id=427765
Signed-off-by: Chuck Ebbert
Cc:
Cc: Len Brown
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
11 Mar, 2008
1 commit
-
__FUNCTION__ is gcc-specific, use __func__
Signed-off-by: Harvey Harrison
Signed-off-by: Len Brown
10 Feb, 2008
1 commit
-
Add function definition and extern variables to asm-x86/acpi.h.
All of these are used in bus.c in ifdef(CONFIG_X86) sections, so are
only added to the x86 include headers. boot.c already includes acpi.h
so no changes are needed there.Fixes the following:
arch/x86/kernel/acpi/boot.c:83:4: warning: symbol 'acpi_sci_flags' was not declared. Should it be static?
arch/x86/kernel/acpi/boot.c:84:5: warning: symbol 'acpi_sci_override_gsi' was not declared. Should it be static?
arch/x86/kernel/acpi/boot.c:421:13: warning: symbol 'acpi_pic_sci_set_trigger' was not declared. Should it be static?Signed-off-by: Harvey Harrison
Signed-off-by: Ingo Molnar
Signed-off-by: Thomas Gleixner
07 Feb, 2008
2 commits
-
Conflicts:
drivers/acpi/scan.c
include/linux/acpi.hSigned-off-by: Len Brown
-
This patch contains the following possible cleanups:
- make the following needlessly global code static:
- drivers/acpi/bay.c:dev_attr_eject
- drivers/acpi/bay.c:dev_attr_present
- drivers/acpi/dock.c:dev_attr_docked
- drivers/acpi/dock.c:dev_attr_flags
- drivers/acpi/dock.c:dev_attr_uid
- drivers/acpi/dock.c:dev_attr_undock
- drivers/acpi/pci_bind.c:acpi_pci_unbind()
- drivers/acpi/pci_link.c:acpi_link_lock
- drivers/acpi/sbs.c:acpi_sbs_callback()
- drivers/acpi/sbshc.c:acpi_smbus_transaction()
- drivers/acpi/sleep/main.c:acpi_sleep_prepare()
- #if 0 the following unused global functions:
- drivers/acpi/numa.c:acpi_unmap_pxm_to_node()
- remove the following unused EXPORT_SYMBOL's:
- acpi_register_gsi
- acpi_unregister_gsi
- acpi_strict
- acpi_bus_receive_event
- register_acpi_bus_type
- unregister_acpi_bus_type
- acpi_os_printf
- acpi_os_sleep
- acpi_os_stall
- acpi_os_read_pci_configuration
- acpi_os_create_semaphore
- acpi_os_delete_semaphore
- acpi_os_wait_semaphore
- acpi_os_signal_semaphore
- acpi_os_signal
- acpi_pci_irq_enable
- acpi_get_pxmSigned-off-by: Adrian Bunk
Acked-by: Alexey Starikovskiy
Signed-off-by: Len Brown
02 Feb, 2008
1 commit
-
Intel menlow driver needs to get the pointer of themal_zone_device
structure of an ACPI thermal zone.
Attach this to each ACPI thermal zone device object.Signed-off-by: Zhang Rui
Signed-off-by: Thomas Sujith
Signed-off-by: Len Brown
25 Jan, 2008
3 commits
-
There is no firmware "subsystem" it's just a directory in /sys that
other portions of the kernel want to hook into. So make it a kobject
not a kset to help alivate anyone who tries to do some odd kset-like
things with this.Cc: Kay Sievers
Cc: Cornelia Huck
Signed-off-by: Greg Kroah-Hartman -
We don't need a kset here, a simple kobject will do just fine, so
dynamically create the kobject and use it.Cc: Kay Sievers
Cc: Len Brown
Signed-off-by: Greg Kroah-Hartman -
We don't need a "default" ktype for a kset. We should set this
explicitly every time for each kset. This change is needed so that we
can make ksets dynamic, and cleans up one of the odd, undocumented
assumption that the kset/kobject/ktype model has.This patch is based on a lot of help from Kay Sievers.
Nasty bug in the block code was found by Dave Young
Cc: Kay Sievers
Cc: Dave Young
Signed-off-by: Greg Kroah-Hartman
24 Jan, 2008
1 commit
-
This reverts commit 93ad7c07ad487b036add8760dabcc35666a550ef.
http://bugzilla.kernel.org/show_bug.cgi?id=9798
Signed-off-by: Len Brown
12 Jan, 2008
1 commit
-
ACPI and APM used "pm_active" to guarantee that
they would not be simultaneously active.But pm_active was recently moved under CONFIG_PM_LEGACY,
so that without CONFIG_PM_LEGACY, pm_active became a NOP --
allowing ACPI and APM to both be simultaneously enabled.
This caused unpredictable results, including boot hangs.Further, the code under CONFIG_PM_LEGACY is scheduled
for removal.So replace pm_active with pm_flags.
pm_flags depends only on CONFIG_PM,
which is present for both CONFIG_APM and CONFIG_ACPI.http://bugzilla.kernel.org/show_bug.cgi?id=9194
Signed-off-by: Len Brown
Signed-off-by: Rafael J. Wysocki
26 Oct, 2007
2 commits
-
force_power_state was used as a workaround for invalid cached
power state of the device. We do not cache power state, so no need for
workaround.Signed-off-by: Alexey Starikovskiy
Acked-by: Rafael J. Wysocki
Signed-off-by: Len Brown -
ACPI may change power resource state behind our back, so don't
keep our local copy, which may not be valid.Signed-off-by: Alexey Starikovskiy
Signed-off-by: Len Brown
20 Oct, 2007
1 commit
-
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: (41 commits)
ACPICA: hw: Don't carry spinlock over suspend
ACPICA: hw: remove use_lock flag from acpi_hw_register_{read, write}
ACPI: cpuidle: port idle timer suspend/resume workaround to cpuidle
ACPI: clean up acpi_enter_sleep_state_prep
Hibernation: Make sure that ACPI is enabled in acpi_hibernation_finish
ACPI: suppress uninitialized var warning
cpuidle: consolidate 2.6.22 cpuidle branch into one patch
ACPI: thinkpad-acpi: skip blanks before the data when parsing sysfs
ACPI: AC: Add sysfs interface
ACPI: SBS: Add sysfs alarm
ACPI: SBS: Add ACPI_PROCFS around procfs handling code.
ACPI: SBS: Add support for power_supply class (and sysfs)
ACPI: SBS: Make SBS reads table-driven.
ACPI: SBS: Simplify data structures in SBS
ACPI: SBS: Split host controller (ACPI0001) from SBS driver (ACPI0002)
ACPI: EC: Add new query handler to list head.
ACPI: Add acpi_bus_generate_event4() function
ACPI: Battery: add sysfs alarm
ACPI: Battery: Add sysfs support
ACPI: Battery: Misc clean-ups, no functional changes
...Fix up conflicts in drivers/misc/thinkpad_acpi.[ch] manually
13 Oct, 2007
1 commit
-
A number of different drivers incorrect access the kobject name field
directly. This is not correct as the name might not be in the array.
Use the proper accessor function instead.
12 Oct, 2007
1 commit
-
ACPI spec defines the sequence of IDE power on/off:
Powering down:
Call _GTM.
Power down drive (calls _PS3 method and turns off power planes).
Powering up:
Power up drive (calls _PS0 method if present and turns on power planes).
Call _STM passing info from _GTM (possibly modified), with ID data from
each drive.
Initialize the channel.
May modify the results of _GTF.
For each drive:
Call _GTF.
Execute task file (possibly modified).
This patch adds the missed _PS0/_PS3 methods call.Signed-off-by: Shaohua Li
Acked-by: Len Brown
Signed-off-by: Bartlomiej Zolnierkiewicz
28 Sep, 2007
1 commit
-
acpi_bus_generate_event() takes two strings out of passed device object.
SBS needs to supply these strings directly.Signed-off-by: Alexey Starikovskiy
Signed-off-by: Len Brown
24 Aug, 2007
2 commits
-
Schedule /proc/acpi/event for removal in 6 months.
Re-name acpi_bus_generate_event() to acpi_bus_generate_proc_event()
to make sure there is no confusion that it is for /proc/acpi/event only.Add CONFIG_ACPI_PROC_EVENT to allow removal of /proc/acpi/event.
There is no functional change if CONFIG_ACPI_PROC_EVENT=ySigned-off-by: Len Brown
-
The previous events patch added a netlink event for every
user of the legacy /proc/acpi/event interface.However, some users of /proc/acpi/event are really input events,
and they already report their events via the input layer.Introduce a new interface, acpi_bus_generate_netlink_event(),
which is explicitly called by devices that want to repoprt
events via netlink. This allows the input-like events
to opt-out of generating netlink events. In summary:events that are sent via netlink:
ac/battery/sbs
thermal
processor
thinkpad_acpi dock/bayevents that are sent via input layer:
button
video hotkey
thinkpad_acpi hotkey
asus_acpi/asus-laptop hotkey
sonypi/sonylaptopSigned-off-by: Zhang Rui
Signed-off-by: Len Brown
04 Jul, 2007
1 commit
-
Upon ACPI events, send an "acpi_event" via Generic Netlink.
This is in addition to /proc/acpi/event, which remains intact for now.Thanks to Jamal for his great help.
Signed-off-by: Zhang Rui
Signed-off-by: Len Brown
26 Apr, 2007
1 commit
-
Be explicit about what "device->status = 0x0F" really means.
syntax only.
Signed-off-by: Bjorn Helgaas
Signed-off-by: Andrew Morton
Signed-off-by: Len Brown
17 Feb, 2007
2 commits
16 Feb, 2007
1 commit
-
http://bugzilla.kernel.org/show_bug.cgi?id=7570
Signed-off-by: Konstantin Karasyov
Signed-off-by: Len Brown
13 Feb, 2007
1 commit
-
cosmetic only
Make "module name" actually match the file name.
Invoke with ';' as leaving it off confuses Lindent and gcc doesn't care.
Fix indentation where Lindent did get confused.Signed-off-by: Len Brown
10 Feb, 2007
1 commit
-
late_initcall() is too late for acpi_sleep_init().
Call it directly from acpi_init code.http://bugzilla.kernel.org/show_bug.cgi?id=7887
Signed-off-by: Alexey Starikovskiy
Signed-off-by: Vladimir Lebedev
Signed-off-by: Len Brown
03 Feb, 2007
4 commits
-
Conflicts:
Documentation/feature-removal-schedule.txt
include/acpi/acpi_drivers.hSigned-off-by: Len Brown
-
Signed-off-by: Len Brown
-
Signed-off-by: Len Brown
-
Signed-off-by: Len Brown
05 Jan, 2007
1 commit
-
Provide ACPI _PRT support for SN Altix systems.
The SN Altix platform does not conform to the
IOSAPIC IRQ routing model, so a new acpi_irq_model
(ACPI_IRQ_MODEL_PLATFORM) has been defined. The SN
platform specific code sets acpi_irq_model to
this new value, and keys off of it in acpi_register_gsi()
to avoid the iosapic code path.Signed-off-by: John Keller
Signed-off-by: Len Brown
16 Dec, 2006
1 commit
-
Setup new sysfs framework
1. Remove /sys/firmware/acpi
2. Add ACPI device in device tree.File "eject" for every device that has _EJ0 method is moved from
/sys/firmware to /sys/devices.
Operation on this file is exactly the same as before.
i.e. echo 1 to "eject" will cause hot removal of this device.
Corresponding changes should be made in userspace for hot removal.Signed-off-by: Li Shaohua
Signed-off-by: Zhang Rui
Signed-off-by: Len Brown
26 Jul, 2006
1 commit
-
The ACPI_EXCEPTION() patch enabled a bunch of messages to print
even in the non-DEBUG kernel. Need to change a couple back,
and note that ACPI_EXCEPTION takes no \n, but ACPI_DEBUG_PRINT does.No context for object [%p]\n
Device `[%s]' is not power manageable\nSigned-off-by: Len Brown
12 Jul, 2006
1 commit
-
Signed-off-by: Randy Dunlap
Signed-off-by: Len Brown
10 Jul, 2006
1 commit
-
Signed-off-by: Len Brown