aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi
AgeCommit message (Collapse)AuthorFilesLines
2006-02-26[PATCH] x86_64: Disable ACPI blacklist by year for now on x86-64Andi Kleen1-1/+1
ACPI is initialized very early on x86-64, before the DMI code is initialized. This means it would often discover a 0 year and then turn off ACPI because it thought the BIOS was too old. Some systems don't boot without ACPI so this was a problem. I have a full fix by adding new very early DMI detection, but it needs more testing before it can be merged. For 2.6.16 let's just turn the check off. It never made much sense anyways because there are no x86-64 systems older than 2002 or so and they generally all have working ACPI. Cc: len.brown@intel.com Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-02-26[PATCH] x86-64/i386: Use common X86_PM_TIMER option and make it EMBEDDEDAndi Kleen1-5/+3
This makes x86-64 use the common X86_PM_TIMER Kconfig entry in drivers/acpi And since PM timer is needed for correct timing on a lot of systems now (e.g. AMD dual cores) and we often get bug reports from people who forgot to set it make it depend on CONFIG_EMBEDDED. x86-64 had this change before and it's a good thing. I also fixed the description slightly to make this more clear. Cc: len.brown@intel.com Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-02-17[PATCH] ACPI: fix vendor resource length computationBjorn Helgaas1-4/+2
acpi_rs_get_list_length() needs to account for all the vendor-defined data bytes. Failing to include these causes buffers to be sized too small, which causes slab corruption when we later convert AML to resources and run off the end of the buffer. This causes slab corruption on machines that use ACPI vendor-defined resources. All HP ia64 machines do, and I'm told that some NEC machines may as well. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: "Brown, Len" <len.brown@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-02-04[PATCH] x86_64: data/functions wrongly marked as __init with cpu hotplug.Ashok Raj1-1/+3
attached patch is 2 more cases i found via running the reference_init.pl script. These were easy to spot just knowing the file names. There is one another about init/main.c that i cant exactly zero in. (partly because i dont know how to interpret the data thats spewed out of the tool). Signed-off-by: Ashok Raj <ashok.raj@intel.com> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-02-04[PATCH] x86_64: Only switch to IPI broadcast timer on Intel when C3 is supportedVenkatesh Pallipadi1-1/+1
Bug in apic timer removal on C3 patch. We should switch to IPI from APIC timer only when C3 state is valid. Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-01-31[ACPI] ACPICA 20060127Bob Moore85-736/+1238
Implemented support in the Resource Manager to allow unresolved namestring references within resource package objects for the _PRT method. This support is in addition to the previously implemented unresolved reference support within the AML parser. If the interpreter slack mode is enabled (true on Linux unless acpi=strict), these unresolved references will be passed through to the caller as a NULL package entry. http://bugzilla.kernel.org/show_bug.cgi?id=5741 Implemented and deployed new macros and functions for error and warning messages across the subsystem. These macros are simpler and generate less code than their predecessors. The new macros ACPI_ERROR, ACPI_EXCEPTION, ACPI_WARNING, and ACPI_INFO replace the ACPI_REPORT_* macros. Implemented the acpi_cpu_flags type to simplify host OS integration of the Acquire/Release Lock OSL interfaces. Suggested by Steven Rostedt and Andrew Morton. Fixed a problem where Alias ASL operators are sometimes not correctly resolved. causing AE_AML_INTERNAL http://bugzilla.kernel.org/show_bug.cgi?id=5189 http://bugzilla.kernel.org/show_bug.cgi?id=5674 Fixed several problems with the implementation of the ConcatenateResTemplate ASL operator. As per the ACPI specification, zero length buffers are now treated as a single EndTag. One-length buffers always cause a fatal exception. Non-zero length buffers that do not end with a full 2-byte EndTag cause a fatal exception. Fixed a possible structure overwrite in the AcpiGetObjectInfo external interface. (With assistance from Thomas Renninger) Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-27Pull release into acpica branchLen Brown16-267/+329
2006-01-26[ACPI] remove "Resource isn't an IRQ" warningLen Brown1-1/+3
In the case where a (broken) BIOS gives us a blank _CRS for a PCI Interrupt Link Device, the acpi_walk_resources() will not terminate, but will then give the callback the resource end tag. Ignore the end tag. Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-24[ACPI] merge 3549 4320 4485 4588 4980 5483 5651 acpica asus fops pnpacpi ↵Len Brown131-6868/+6025
branches into release Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-20[ACPI] ACPICA 20060113Bob Moore109-944/+569
Added 2006 copyright. At SuSE's suggestion, enabled all error messages without enabling function tracing, ie with CONFIG_ACPI_DEBUG=n Replaced all instances of the ACPI_DEBUG_PRINT macro invoked at the ACPI_DB_ERROR and ACPI_DB_WARN debug levels with the ACPI_REPORT_ERROR and ACPI_REPORT_WARNING macros, respectively. This preserves all error and warning messages in the non-debug version of the ACPICA code (this has been referred to as the "debug lite" option.) Over 200 cases were converted to create a total of over 380 error/warning messages across the ACPICA code. This increases the code and data size of the default non-debug version by about 13K. Added ACPI_NO_ERROR_MESSAGES flag to enable deleting all messages. The size of the debug version remains about the same. Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-20[ACPI] delete message "**** SET: Misaligned resource pointer:"Len Brown1-8/+0
This check, added in ACPICA 20051021, was overly paranoid. Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-16Revert "[ACPI] fix pnpacpi regression resulting from ACPICA 20051117"Len Brown1-6/+6
This reverts ed349a8a0a780ed27e2a765f16cee54d9b63bfee commit.
2006-01-14[PATCH] Unlinline a bunch of other functionsArjan van de Ven1-1/+1
Remove the "inline" keyword from a bunch of big functions in the kernel with the goal of shrinking it by 30kb to 40kb Signed-off-by: Arjan van de Ven <arjan@infradead.org> Signed-off-by: Ingo Molnar <mingo@elte.hu> Acked-by: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-01-11[PATCH] i386: Handle missing local APIC timer interrupts on C3 stateVenkatesh Pallipadi1-0/+15
Whenever we see that a CPU is capable of C3 (during ACPI cstate init), we disable local APIC timer and switch to using a broadcast from external timer interrupt (IRQ 0). This is needed because Intel CPUs stop the local APIC timer in C3. This is currently only enabled for Intel CPUs. Patch below adds the code for i386 and also the ACPI hunk. Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-01-09[PATCH] apci: use pin stored in pci_devKristen Accardi1-4/+3
Use the stored value of the Interrupt Pin, rather than try to read it again. Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-08[PATCH] tpm: add bios measurement logKylene Jo Hall1-0/+2
According to the TCG specifications measurements or hashes of the BIOS code and data are extended into TPM PCRS and a log is kept in an ACPI table of these extensions for later validation if desired. This patch exports the values in the ACPI table through a security-fs seq_file. Signed-off-by: Seiji Munetoh <munetoh@jp.ibm.com> Signed-off-by: Stefan Berger <stefanb@us.ibm.com> Signed-off-by: Reiner Sailer <sailer@us.ibm.com> Signed-off-by: Kylene Hall <kjhall@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-01-08[ACPI] make two processor functions staticAdrian Bunk2-6/+6
acpi_processor_write_throttling() acpi_processor_write_limit() Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-07[ACPI] remove Kconfig "default y" for laptop driversBorislav Petkov1-2/+0
Signed-off-by: Borislav Petkov <petkov@uni-muenster.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-07[ACPI] fix kernel-doc warnings in acpi/scan.cRandy Dunlap1-10/+17
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-07[ACPI] Disable C2/C3 for _all_ IBM R40e LaptopsThomas Rosner1-16/+51
This adds all known BIOS versions of IBM R40e Laptops to the C2/C3 processor state blacklist and thus prevents them from crashing. workaround for http://bugzilla.kernel.org/show_bug.cgi?id=3549 Signed-off-by: Thomas Rosner <kernel-bugs@digital-trauma.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-07[ACPI] acpi_memhotplug.c build fixKAMEZAWA Hiroyuki1-7/+6
drivers/acpi/acpi_memhotplug.c: In function `acpi_memory_get_device_resources': drivers/acpi/acpi_memhotplug.c:101: error: structure has no member named `attribute' drivers/acpi/acpi_memhotplug.c:103: error: structure has no member named `attribute' drivers/acpi/acpi_memhotplug.c: In function `acpi_memory_disable_device': drivers/acpi/acpi_memhotplug.c:253: warning: unused variable `attr' Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-07[ACPI] move some run-time structure inits to compile timeArjan van de Ven5-7/+7
acpi_processor_limit_fops.write was written at run time, but can be initiailized at compile-time instead. Similar for acpi_video_bus_POST_fops.write and friends, but keep doing those at runtime to avoid prototype-hell. Signed-off-by: Arjan van de Ven <arjan@infradead.org> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-07Pull pnpacpi into acpica branchLen Brown5-18/+18
2006-01-06Auto-update from upstreamLen Brown3-15/+15
2006-01-05[ACPI] fix pnpacpi regression resulting from ACPICA 20051117Len Brown1-6/+6
In ACPICA 20051117, acpi_walk_resources() started sending ACPI_RESOURCE_TYPE_END_TAG to the callback routine which wasn't prepared for it, causing _CRS to fail and PnPACPI to not recognize any devices: pnp: ACPI device : hid PNP0C02 pnp: PnPACPI: unknown resource type 7 pnp: PnPACPI: METHOD_NAME__CRS failure for PNP0c02 Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-04[PATCH] driver core: replace "hotplug" by "uevent"Kay Sievers3-15/+15
Leave the overloaded "hotplug" word to susbsystems which are handling real devices. The driver core does not "plug" anything, it just exports the state to userspace and generates events. Signed-off-by: Kay Sievers <kay.sievers@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-01-04[ACPI_ASUS] fix asus module param descriptionKarol Kozimor1-2/+4
Signed-off-by: Karol Kozimor <sziwan@hell.org.pl> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-04[ACPI_ASUS] M6R display readingKarol Kozimor1-1/+1
This patch corrects the node to read display settings on M6R laptops. Signed-off-by: Karol Kozimor <sziwan@hell.org.pl> Signed-off-by: Len Brown <len.brown@intel.com>
2006-01-03[ACPI] fix acpi_os_wait_sempahore() finite timeout case (AE_TIME warning)Yu Luming1-1/+1
Before this fix, the finite timeout case behaved like the no-timeout (trylock) case. http://bugzilla.kernel.org/show_bug.cgi?id=4588 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-30[ACPI] reduce kernel size: move 5BK .bss to 2.5KB .init.dataLen Brown1-2/+2
put __initdata on sdt_entry[], as it is accessed only by __init functions. http://bugzilla.kernel.org/show_bug.cgi?id=1311 Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-29[ASUS_ACPI] work around Samsung P30s oopsKarol Kozimor1-9/+18
The code used to rely on a certain method to return a NULL buffer, which is now hardly possible with the implicit return code on by default. This sort of fixes bugs #5067 and #5092 for now. Note: this patch makes the driver unusable on said machines (and on said machines only) iff acpi=strict is specified, but it seems noone really uses that. Signed-off-by: Karol Kozimor <sziwan@hell.org.pl> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-28[ACPI] fix osl.c build warningLen Brown1-1/+1
typecheck complains on i386 that u32 != unsigned long Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-28[ACPI] ACPICA 20051216Bob Moore18-251/+520
Implemented optional support to allow unresolved names within ASL Package objects. A null object is inserted in the package when a named reference cannot be located in the current namespace. Enabled via the interpreter slack flag which Linux has enabled by default (acpi=strict to disable slack). This should eliminate AE_NOT_FOUND exceptions seen on machines that contain such code. Implemented an optimization to the initialization sequence that can improve boot time. During ACPI device initialization, the _STA method is now run if and only if the _INI method exists. The _STA method is used to determine if the device is present; An _INI can only be run if _STA returns present, but it is a waste of time to run the _STA method if the _INI does not exist. (Prototype and assistance from Dong Wei) Implemented use of the C99 uintptr_t for the pointer casting macros if it is available in the current compiler. Otherwise, the default (void *) cast is used as before. Fixed some possible memory leaks found within the execution path of the Break, Continue, If, and CreateField operators. (Valery Podrezov) Fixed a problem introduced in the 20051202 release where an exception is generated during method execution if a control method attempts to declare another method. Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-22Pull bug3410 into release branchLen Brown1-2/+2
2005-12-22Pull owner_id into release branchLen Brown1-9/+9
2005-12-22[ACPI] fix build warning from owner_id patchLen Brown1-1/+1
Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-22[ACPI] fix passive cooling regressionThomas Renninger1-2/+2
Return logic was inverted. Going for changing the return value to not return zero as it is makes more sense regarding the naming of the function (cpu_has_cpufreq()). http://bugzilla.kernel.org/show_bug.cgi?id=3410 Signed-off-by: Thomas Renninger <trenn@suse.de> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-21[ACPI] build EC driver on IA64Kenji Kaneshige1-1/+0
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-21[ACPI] increase owner_id limit to 64 from 32Alex Williamson1-9/+9
This is an interim patch until changes in an updated ACPICA core increase the limit to 255. Signed-off-by: Alex Williamson <alex.williamson@hp.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-15[ACPI] fix reboot upon suspend-to-diskAlexey Starikovskiy3-10/+13
http://bugzilla.kernel.org/show_bug.cgi?id=4320 Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@intel.com> Acked-by: Pavel Machek <pavel@suse.cz> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-14Auto-update from upstreamLen Brown1-1/+1
2005-12-12[PATCH] ACPI: fix sleeping whilst atomic warnings on resumeDave Jones1-1/+1
This has been broken for months. On resume, we call acpi_pci_link_set() with interrupts off, so we get a warning when we try to do a kmalloc of non atomic memory. The actual allocation is just 2 long's (plus extra byte for some reason I can't fathom), so a simple conversion to GFP_ATOMIC is probably the safest way to fix this. The error looks like this.. Debug: sleeping function called from invalid context at mm/slab.c:2486 in_atomic():0, irqs_disabled():1 [<c0143f6c>] kmem_cache_alloc+0x40/0x56 [<c0206a2e>] acpi_pci_link_set+0x3f/0x17f [<c0206f96>] irqrouter_resume+0x1e/0x3c [<c0239bca>] __sysdev_resume+0x11/0x6b [<c0239e88>] sysdev_resume+0x34/0x52 [<c023de21>] device_power_up+0x5/0xa Signed-off-by: Dave Jones <davej@redhat.com> Cc: "Brown, Len" <len.brown@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-12-10[ACPI] ACPICA 20051202Bob Moore5-223/+338
Modified the parsing of control methods to no longer create namespace objects during the first pass of the parse. Objects are now created only during the execute phase, at the moment the namespace creation operator is encountered in the AML (Name, OperationRegion, CreateByteField, etc.) This should eliminate ALREADY_EXISTS exceptions seen on some machines where reentrant control methods are protected by an AML mutex. The mutex will now correctly block multiple threads from attempting to create the same object more than once. Increased the number of available Owner Ids for namespace object tracking from 32 to 255. This should eliminate the OWNER_ID_LIMIT exceptions seen on some machines with a large number of ACPI tables (either static or dynamic). Enhanced the namespace dump routine to output the owner ID for each namespace object. Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-10[ACPI] ACPICA 20051117Bob Moore26-322/+449
Fixed a problem in the AML parser where the method thread count could be decremented below zero if any errors occurred during the method parse phase. This should eliminate AE_AML_METHOD_LIMIT exceptions seen on some machines. This also fixed a related regression with the mechanism that detects and corrects methods that cannot properly handle reentrancy (related to the deployment of the new OwnerId mechanism.) Eliminated the pre-parsing of control methods (to detect errors) during table load. Related to the problem above, this was causing unwind issues if any errors occurred during the parse, and it seemed to be overkill. A table load should not be aborted if there are problems with any single control method, thus rendering this feature rather pointless. Fixed a problem with the new table-driven resource manager where an internal buffer overflow could occur for small resource templates. Implemented a new external interface, acpi_get_vendor_resource() This interface will find and return a vendor-defined resource descriptor within a _CRS or _PRS method via an ACPI 3.0 UUID match. (from Bjorn Helgaas) Removed the length limit (200) on string objects as per the upcoming ACPI 3.0A specification. This affects the following areas of the interpreter: 1) any implicit conversion of a Buffer to a String, 2) a String object result of the ASL Concatentate operator, 3) the String object result of the ASL ToString operator. Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-10[ACPI] ACPICA 20051102Bob Moore16-959/+1292
Modified the subsystem initialization sequence to improve GPE support. The GPE initialization has been split into two parts in order to defer execution of the _PRW methods (Power Resources for Wake) until after the hardware is fully initialized and the SCI handler is installed. This allows the _PRW methods to access fields protected by the Global Lock. This will fix systems where a NO_GLOBAL_LOCK exception has been seen during initialization. Fixed a regression with the ConcatenateResTemplate() ASL operator introduced in the 20051021 release. Implemented support for "local" internal ACPI object types within the debugger "Object" command and the acpi_walk_namespace() external interfaces. These local types include RegionFields, BankFields, IndexFields, Alias, and reference objects. Moved common AML resource handling code into a new file, "utresrc.c". This code is shared by both the Resource Manager and the AML Debugger. Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-10[ACPI] ACPICA 20051021Bob Moore21-2653/+1945
Implemented support for the EM64T and other x86_64 processors. This essentially entails recognizing that these processors support non-aligned memory transfers. Previously, all 64-bit processors were assumed to lack hardware support for non-aligned transfers. Completed conversion of the Resource Manager to nearly full table-driven operation. Specifically, the resource conversion code (convert AML to internal format and the reverse) and the debug code to dump internal resource descriptors are fully table-driven, reducing code and data size and improving maintainability. The OSL interfaces for Acquire and Release Lock now use a 64-bit flag word on 64-bit processors instead of a fixed 32-bit word. (Alexey Starikovskiy) Implemented support within the resource conversion code for the Type-Specific byte within the various ACPI 3.0 *WordSpace macros. Fixed some issues within the resource conversion code for the type-specific flags for both Memory and I/O address resource descriptors. For Memory, implemented support for the MTP and TTP flags. For I/O, split the TRS and TTP flags into two separate fields. Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-10[ACPI] ACPICA 20050930Bob Moore39-2910/+2182
Completed a major overhaul of the Resource Manager code - specifically, optimizations in the area of the AML/internal resource conversion code. The code has been optimized to simplify and eliminate duplicated code, CPU stack use has been decreased by optimizing function parameters and local variables, and naming conventions across the manager have been standardized for clarity and ease of maintenance (this includes function, parameter, variable, and struct/typedef names.) All Resource Manager dispatch and information tables have been moved to a single location for clarity and ease of maintenance. One new file was created, named "rsinfo.c". The ACPI return macros (return_ACPI_STATUS, etc.) have been modified to guarantee that the argument is not evaluated twice, making them less prone to macro side-effects. However, since there exists the possibility of additional stack use if a particular compiler cannot optimize them (such as in the debug generation case), the original macros are optionally available. Note that some invocations of the return_VALUE macro may now cause size mismatch warnings; the return_UINT8 and return_UINT32 macros are provided to eliminate these. (From Randy Dunlap) Implemented a new mechanism to enable debug tracing for individual control methods. A new external interface, acpi_debug_trace(), is provided to enable this mechanism. The intent is to allow the host OS to easily enable and disable tracing for problematic control methods. This interface can be easily exposed to a user or debugger interface if desired. See the file psxface.c for details. acpi_ut_callocate() will now return a valid pointer if a length of zero is specified - a length of one is used and a warning is issued. This matches the behavior of acpi_ut_allocate(). Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-06Pull release into acpica branchLen Brown16-157/+453
2005-12-06Auto-update from upstreamLen Brown1-0/+228
2005-12-05Pull 5165 into release branchLen Brown1-5/+15
2005-12-05[ACPI] correct earlier SMP deep C-states on HT patchDavid Shaohua Li1-5/+15
http://bugzilla.kernel.org/show_bug.cgi?id=5165 Change polarity of test for PLVL2_UP flag. Skip promotion/demotion code when not needed. Signed-off-by: Shaohua Li <shaohua.li@intel.com> Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-05[ACPI] Embedded Controller (EC) driver printk syntax updateLen Brown1-10/+10
no functional changes Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-05[ACPI] Enable Embedded Controller (EC) interrupt mode by defaultLen Brown1-3/+3
"ec_intr=0" reverts to polling "ec_burst=" no longer exists. Signed-off-by: Len Brown <len.brown@intel.com> Acked-by: Luming Yu <luming.yu@intel.com>
2005-12-05[ACPI] Embedded Controller (EC) driver syntax updateLen Brown1-116/+117
"intr" largely replaces "burst" for syntax to follow semantics "poll" largely replaces "polling" for economy of expression append "interrupt mode" or "polling mode" to dmesg line no functional changes Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-02Add missing "local_irq_enable()" to C2/C3 exit logicLinus Torvalds1-0/+1
Silly bug crept in with the C2/C3 TIF_POLLING_NRFLAG fixes. Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-12-02[PATCH] Fix TIF_POLLING_NRFLAG in ACPI idle routinesNick Piggin1-7/+14
Commit 64c7c8f88559624abdbe12b5da6502e8879f8d28 broke the ACPI C2 and C3 sleep states, because it left TIF_POLLING_NRFLAG active even though those states do not actually poll the reschedule flag at all. As a result, the CPU wouldn't get sent an IPI when it was to be woken up, and would only notice that it had runnable processes on the next timer tick. Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-12-01[ACPI] Disable EC burst mode w/o disabling EC interruptsLuming Yu1-16/+20
Need to de-couple the concept of polling/interrupts vs burst/non-burst. http://bugzilla.kernel.org/show_bug.cgi?id=4980 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-01[ACPI] handle BIOS with implicit C1 in _CSTJanosch Machowinski1-33/+31
The ASUS M6Ne specifies C2, implying C1 but not explicitly specifying it. http://bugzilla.kernel.org/show_bug.cgi?id=4485 Signed-off-by: Janosch Machowinski <jmachowinski@gmx.de> Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-12-01Pull 3410 into release branchLen Brown2-93/+108
2005-12-01Pull 5452 into release branchLen Brown1-0/+15
2005-12-01Pull 5571 into release branchLen Brown1-1/+1
2005-12-01[ACPI] Avoid BIOS inflicted crashes by evaluating _PDC only onceVenkatesh Pallipadi3-21/+11
Linux invokes the AML _PDC method (Processor Driver Capabilities) to tell the BIOS what features it can handle. While the ACPI spec says nothing about the OS invoking _PDC multiple times, doing so with changing bits seems to hopelessly confuse the BIOS on multiple platforms up to and including crashing the system. Factor out the _PDC invocation so Linux invokes it only once. http://bugzilla.kernel.org/show_bug.cgi?id=5483 Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-11-30[ACPI] fix 2.6.13 boot hang regression on HT box w/ broken BIOSVenkatesh Pallipadi1-0/+15
http://bugzilla.kernel.org/show_bug.cgi?id=5452 Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-11-30[ACPI] Fix Null pointer deref in video/lcd/brightnessThomas Renninger1-1/+1
http://bugzilla.kernel.org/show_bug.cgi?id=5571 Signed-off-by: Thomas Renninger <trenn@suse.de> Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com> Signed-off-by: Yu Luming <luming.yu@gmail.com> Cc: <stable@kernel.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-11-30[ACPI] Allow return to active cooling mode once passive mode is enteredThomas Renninger2-93/+108
http://bugzilla.kernel.org/show_bug.cgi?id=3410 https://bugzilla.novell.com/show_bug.cgi?id=131543 Signed-off-by: Thomas Renninger <trenn@suse.de> Signed-off-by: Konstantin Karasyov <konstantin.a.karasyov@intel.com> Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@intel.com> Signed-off-by: Yu Luming <luming.yu@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org>
2005-11-30[ACPI] delete "default y" on Kconfig for ibm_acpi extras driverBorislav Petkov1-1/+0
Signed-off-by: Borislav Petkov <petkov@uni-muenster.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-11-30[ACPI] IA64 build: blacklist.c is used only on X86Al Viro1-1/+1
Signed-off-by: Al Viro <viro@ftp.linux.org.uk> Signed-off-by: Len Brown <len.brown@intel.com> (cherry picked from ef4611613657dfb8af8d336f2f61f08cfcdc9d8a commit)
2005-11-30Pull 5165 into release branchLen Brown1-5/+24
2005-11-30[ACPI] fix HP nx8220 boot hang regressionThomas Renninger1-1/+1
This patch reverts the acpi_bus_find_driver() return value check that came in via the PCI tree via 3fb02738b0fd36f47710a2bf207129efd2f5daa2 [PATCH] acpi bridge hotadd: Allow ACPI .add and .start operations to be done independently This particular change broke booting of some HP/Compaq laptops unless acpi=noirq is used. http://bugzilla.kernel.org/show_bug.cgi?id=5221 https://bugzilla.novell.com/show_bug.cgi?id=116763 Signed-off-by: Thomas Renninger <trenn@suse.de> Cc: Rajesh Shah <rajesh.shah@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-11-30[ACPI] Add support for FADT P_LVL2_UP flagVenkatesh Pallipadi1-0/+19
which tells us if C2 is valid for UP-only, or SMP. As there is no separate bit for C3, use P_LVL2_UP bit to cover both C2 and C3. http://bugzilla.kernel.org/show_bug.cgi?id=5165 Signed-off-by: Venkatesh Pallipadi<venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com> (cherry picked from 28b86b368af3944eb383078fc5797caf2dc8ce44 commit)
2005-11-30[ACPI] Prefer _CST over FADT for C-state capabilitiesVenkatesh Pallipadi1-5/+5
Note: This ACPI standard compliance may cause regression on some system, if they have _CST present, but _CST value is bogus. "nocst" module parameter should workaround that regression. http://bugzilla.kernel.org/show_bug.cgi?id=5165 Signed-off-by: Venkatesh Pallipadi<venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com> (cherry picked from 883baf7f7e81cca26f4683ae0d25ba48f094cc08 commit)
2005-11-18Fix ACPI processor power block initializationLinus Torvalds1-10/+4
Properly clear the memory, and set "pr->flags.power" only if a C2 or deeper state is valid (to make the code match both the comment and previous behaviour). This fixes a boot-time lockup reported by Maneesh Soni when using "maxcpus=1". Acked-by: Maneesh Soni <maneesh@in.ibm.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-13[PATCH] move pm_register/etc. to CONFIG_PM_LEGACY, pm_legacy.hJeff Garzik1-1/+2
Since few people need the support anymore, this moves the legacy pm_xxx functions to CONFIG_PM_LEGACY, and include/linux/pm_legacy.h. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-10[PATCH] pciehp: clean-up how we request control of hotplug hardwarerajesh.shah@intel.com1-0/+1
This patch further tweaks how we request control of hotplug controller hardware from BIOS. We first search the ACPI namespace corresponding to a specific hotplug controller looking for an _OSC or OSHP method. On failure, we successively move to the ACPI parent object, till we hit the highest level host bridge in the hierarchy. This allows for different types of BIOS's which place the _OSC/OSHP methods at various places in the acpi namespace, while still not encroaching on the namespace of some other root level host bridge. This patch also introduces a new load time option (pciehp_force) that allows us to bypass all _OSC/OSHP checking. Not supporting these methods seems to be be the most common ACPI firmware problem we've run into. This will still _not_ allow the pciehp driver to work correctly if the BIOS really doesn't support pciehp (i.e. if it doesn't generate a hotplug interrupt). Use this option with caution. Some BIOS's may deliberately not build any _OSC/OSHP methods to make sure it retains control the hotplug hardware. Using the pciehp_force parameter for such systems can lead to two separate entities trying to control the same hardware. Signed-off-by: Rajesh Shah <rajesh.shah@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2005-11-09[PATCH] sched: resched and cpu_idle reworkNick Piggin1-14/+23
Make some changes to the NEED_RESCHED and POLLING_NRFLAG to reduce confusion, and make their semantics rigid. Improves efficiency of resched_task and some cpu_idle routines. * In resched_task: - TIF_NEED_RESCHED is only cleared with the task's runqueue lock held, and as we hold it during resched_task, then there is no need for an atomic test and set there. The only other time this should be set is when the task's quantum expires, in the timer interrupt - this is protected against because the rq lock is irq-safe. - If TIF_NEED_RESCHED is set, then we don't need to do anything. It won't get unset until the task get's schedule()d off. - If we are running on the same CPU as the task we resched, then set TIF_NEED_RESCHED and no further action is required. - If we are running on another CPU, and TIF_POLLING_NRFLAG is *not* set after TIF_NEED_RESCHED has been set, then we need to send an IPI. Using these rules, we are able to remove the test and set operation in resched_task, and make clear the previously vague semantics of POLLING_NRFLAG. * In idle routines: - Enter cpu_idle with preempt disabled. When the need_resched() condition becomes true, explicitly call schedule(). This makes things a bit clearer (IMO), but haven't updated all architectures yet. - Many do a test and clear of TIF_NEED_RESCHED for some reason. According to the resched_task rules, this isn't needed (and actually breaks the assumption that TIF_NEED_RESCHED is only cleared with the runqueue lock held). So remove that. Generally one less locked memory op when switching to the idle thread. - Many idle routines clear TIF_POLLING_NRFLAG, and only set it in the inner most polling idle loops. The above resched_task semantics allow it to be set until before the last time need_resched() is checked before going into a halt requiring interrupt wakeup. Many idle routines simply never enter such a halt, and so POLLING_NRFLAG can be always left set, completely eliminating resched IPIs when rescheduling the idle task. POLLING_NRFLAG width can be increased, to reduce the chance of resched IPIs. Signed-off-by: Nick Piggin <npiggin@suse.de> Cc: Ingo Molnar <mingo@elte.hu> Cc: Con Kolivas <kernel@kolivas.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-07[PATCH] kfree cleanup: misc remaining driversJesper Juhl3-16/+8
This is the remaining misc drivers/ part of the big kfree cleanup patch. Remove pointless checks for NULL prior to calling kfree() in misc files in drivers/. Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Acked-by: Aristeu Sergio Rozanski Filho <aris@cathedrallabs.org> Acked-by: Roland Dreier <rolandd@cisco.com> Acked-by: Pierre Ossman <drzeus@drzeus.cx> Acked-by: Jean Delvare <khali@linux-fr.org> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Acked-by: Len Brown <len.brown@intel.com> Acked-by: "Antonino A. Daplas" <adaplas@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-11-07[PATCH] drivers/acpi: fix-up schedule_timeout() usageNishanth Aravamudan1-4/+2
Use schedule_timeout_interruptible() instead of set_current_state()/schedule_timeout() to reduce kernel size. Also use msecs_to_jiffies() instead of direct HZ division to avoid rounding errors. Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com> Cc: "Brown, Len" <len.brown@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30[PATCH] fix missing includesTim Schmielau1-0/+1
I recently picked up my older work to remove unnecessary #includes of sched.h, starting from a patch by Dave Jones to not include sched.h from module.h. This reduces the number of indirect includes of sched.h by ~300. Another ~400 pointless direct includes can be removed after this disentangling (patch to follow later). However, quite a few indirect includes need to be fixed up for this. In order to feed the patches through -mm with as little disturbance as possible, I've split out the fixes I accumulated up to now (complete for i386 and x86_64, more archs to follow later) and post them before the real patch. This way this large part of the patch is kept simple with only adding #includes, and all hunks are independent of each other. So if any hunk rejects or gets in the way of other patches, just drop it. My scripts will pick it up again in the next round. Signed-off-by: Tim Schmielau <tim@physik3.uni-rostock.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30[PATCH] introduce .valid callback for pm_opsShaohua Li1-0/+8
Add pm_ops.valid callback, so only the available pm states show in /sys/power/state. And this also makes an earlier states error report at enter_state before we do actual suspend/resume. Signed-off-by: Shaohua Li<shaohua.li@intel.com> Acked-by: Pavel Machek<pavel@suse.cz> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-29[PATCH] memory hotplug: move section_mem_map alloc to sparse.cDave Hansen1-3/+2
This basically keeps up from having to extern __kmalloc_section_memmap(). The vaddr_in_vmalloc_area() helper could go in a vmalloc header, but that header gets hard to work with, because it needs some arch-specific macros. Just stick it in here for now, instead of creating another header. Signed-off-by: Dave Hansen <haveblue@us.ibm.com> Signed-off-by: Lion Vollnhals <webmaster@schiggl.de> Signed-off-by: Jiri Slaby <xslaby@fi.muni.cz> Signed-off-by: Yasunori Goto <y-goto@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-19[PATCH] `unaligned access' in acpi get_root_bridge_busnr()Peter Chubb1-4/+4
In drivers/acpi/glue.c the address of an integer is cast to the address of an unsigned long. This breaks on systems where a long is larger than an int --- for a start the int can be misaligned; for a second the assignment through the pointer will overwrite part of the next variable. Signed-off-by: Peter Chubb <peterc@gelato.unsw.edu.au> Acked-by: "Brown, Len" <len.brown@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-17[PATCH] Fix /proc/acpi/events around suspendPavel Machek1-3/+2
Fix -EIO on /proc/acpi/events after suspends. This actually breaks suspending by power button in many setups. Signed-off-by: Pavel Machek <pavel@suse.cz> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-09-22[ACPI] clean up ACPICA 20050916's rscalc typedef syntaxLen Brown1-38/+38
Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-22[ACPI] handle ACPICA 20050916's acpi_resource.type renameLen Brown5-14/+14
Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-21[ACPI] ACPICA 20050916Robert Moore11-1733/+1597
Fixed a problem within the Resource Manager where support for the Generic Register descriptor was not fully implemented. This descriptor is now fully recognized, parsed, disassembled, and displayed. Restructured the Resource Manager code to utilize table-driven dispatch and lookup, eliminating many of the large switch() statements. This reduces overall subsystem code size and code complexity. Affects the resource parsing and construction, disassembly, and debug dump output. Cleaned up and restructured the debug dump output for all resource descriptors. Improved readability of the output and reduced code size. Fixed a problem where changes to internal data structures caused the optional ACPI_MUTEX_DEBUG code to fail compilation if specified. Signed-off-by: Robert Moore <Robert.Moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-10[PATCH] remove ACPI S4bios supportPavel Machek3-13/+1
Remove S4BIOS support. It is pretty useless, and only ever worked for _me_ once. (I do not think anyone else ever tried it). It was in feature-removal for a long time, and it should have been removed before. Signed-off-by: Pavel Machek <pavel@suse.cz> Signed-off-by: Adrian Bunk <bunk@stusta.de> Cc: "Brown, Len" <len.brown@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-09-09[PATCH] Fix CONFIG_ACPI_BLACKLIST_YEARviro@ZenIV.linux.org.uk1-2/+1
This makes ACPI_BLACKLIST_YEAR be consistently defined when ACPI is enabled, regardless of whether we're on x86 or not, and thus avoids bogus -Wundef warnings on ia64. Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-09-03[ACPI] revert bad processor_core.c patch for bug 5128Len Brown1-13/+10
Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-03[ACPI] build fix - processor_core.c w/ !CONFIG_SMPLen Brown1-1/+1
http://bugzilla.kernel.org/show_bug.cgi?id=5128 Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-03[ACPI] acpi_video_device_write_state() now worksLuming Yu1-1/+2
http://bugzilla.kernel.org/show_bug.cgi?id=5060 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-03[ACPI] fix processor_core.c for NR_CPUS > 256Venkatesh Pallipadi1-9/+12
http://bugzilla.kernel.org/show_bug.cgi?id=5128 Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-03[ACPI] fix run-time error checking in acpi_pci_irq_disable()Kenji Kaneshige1-4/+1
The 'bus' field in pci_dev structure should be checked before calling pci_read_config_byte() because pci_bus_read_config_byte() called by pci_read_config_byte() refers to 'bus' field. Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-03[ACPI] add static to function definitionsAdrian Bunk4-4/+5
Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-03[ACPI] ACPICA 20050902Robert Moore7-358/+331
Fixed a problem with the internal Owner ID allocation and deallocation mechanisms for control method execution and recursive method invocation. This should eliminate the OWNER_ID_LIMIT exceptions and "Invalid OwnerId" messages seen on some systems. Recursive method invocation depth is currently limited to 255. (Alexey Starikovskiy) http://bugzilla.kernel.org/show_bug.cgi?id=4892 Completely eliminated all vestiges of support for the "module-level executable code" until this support is fully implemented and debugged. This should eliminate the NO_RETURN_VALUE exceptions seen during table load on some systems that invoke this support. http://bugzilla.kernel.org/show_bug.cgi?id=5162 Fixed a problem within the resource manager code where the transaction flags for a 64-bit address descriptor were handled incorrectly in the type-specific flag byte. Consolidated duplicate code within the address descriptor resource manager code, reducing overall subsystem code size. Signed-off-by: Robert Moore <Robert.Moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-09-03[ACPI] revert owner-id-3.patchLen Brown4-34/+54
Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-31[ACPI] Error: Invalid owner_id: 00Alexey Y. Starikovskiy4-54/+34
Signed-off-by: Alexey Y. Starikovskiy <alexey.y.starikovskiy@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-29[ACPI] ACPICA 20050815Bob Moore3-10/+24
Implemented a full bytewise compare to determine if a table load request is attempting to load a duplicate table. The compare is performed if the table signatures and table lengths match. This will allow different tables with the same OEM Table ID and revision to be loaded. Although the BIOS is technically violating the ACPI spec when this happens -- it does happen -- so Linux must handle it. Signed-off-by: Robert Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-29Auto-update from upstreamLen Brown1-1/+5
2005-08-27[PATCH] acpi_shutdown: Only prepare for power off on power_offEric W. Biederman1-1/+5
When acpi_sleep_prepare was moved into a shutdown method we started calling it for all shutdowns. It appears this triggers some systems to power off on reboot. Avoid this by only calling acpi_sleep_prepare if we are going to power off the system. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-08-25merge ibm into testLen Brown1-314/+1044
2005-08-25[ACPI] IBM ThinkPad ACPI Extras Driver v0.12Borislav Deianov1-439/+1159
http://ibm-acpi.sf.net/ Signed-off-by: Borislav Deianov <borislav@users.sf.net> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-25[ACPI] delete CONFIG_ACPI_PCILen Brown3-34/+3
Delete the ability to build an ACPI kernel that does not include PCI support. When such a machine is created and it requires a tuned kernel, send a patch. http://bugzilla.kernel.org/show_bug.cgi?id=1364 Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-25[ACPI] remove "default m" from acpi/KconfigLen Brown1-19/+19
Andi Kleen suggested it was unconventional for us to "default m" on ACPI modules -- even though they are expected to be deployed as modules. But as "default n" would likely result in some users building nonsense kernels, we compromise to "default y". Distros are expected to continue to use =m in their configs. Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-25[ACPI] reduce use of EXPERIMENTAL in acpi/KconfigLen Brown1-5/+3
Distros are shipping modules we had marked EXPERIMENTAL, so clearly it has lost some meaning. Delete that dependency for shipping modules, retaining it only for ACPI_HOTKEY and ACPI_CONTAINER to emphasize that they lack testing on real hardware. Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-25[ACPI] IA64-related ACPI Kconfig fixesLen Brown1-1/+3
Build issues were mostly in the ACPI=n case -- don't do that. Select ACPI from IA64_GENERIC. Add some missing dependencies on ACPI. Mark BLACKLIST_YEAR and some laptop-only ACPI drivers as X86-only. Let me know when you get an IA64 Laptop. Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-24[ACPI] delete CONFIG_ACPI_BUSLen Brown2-7/+3
it is a synonym for CONFIG_ACPI Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-24[ACPI] delete CONFIG_ACPI_INTERPRETERLen Brown2-12/+2
it is a synonym for CONFIG_ACPI Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-24[ACPI] delete CONFIG_ACPI_BOOTLen Brown2-6/+2
it has been a synonym for CONFIG_ACPI since 2.6.12 Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-15Merge from-linus to-akpmLen Brown1-1/+1
2005-08-15Merge 'acpi-2.6.12' branch into to-akpmLen Brown1-3/+3
2005-08-15Merge to-linus-stable into to-akpmLen Brown1-3/+3
2005-08-15Merge ../to-linus-stable/Len Brown1-3/+3
2005-08-15[ACPI] re-enable platform-specific hotkey drivers by defaultLuming Yu1-3/+3
When both platform-specific and generic drivers exist, enable generic over-ride with "acpi_generic_hotkey". http://bugzilla.kernel.org/show_bug.cgi?id=4953 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-14Revert PCIBIOS_MIN_IO changes for 2.6.13Linus Torvalds1-1/+1
This reverts commits 71db63acff69618b3d9d3114bd061938150e146b [PATCH] increase PCIBIOS_MIN_IO on x86 and 0b2bfb4e7ff61f286676867c3508569bea6fbf7a ACPI: increase PCIBIOS_MIN_IO on x86 since Lukas Sandströ<lukass@etek.chalmers.se> reports that this breaks his on-board nvidia audio. We should re-visit this later. For now we revert the change Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-08-12[ACPI] don't complain about PCI root bridges without _SEGBjorn Helgaas1-3/+0
There are lots of single-PCI-segment machines that don't supply _SEG for the root bridges. The PCI root bridge driver silently assumes the segment to be zero in this case, so glue.c shouldn't complain either. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-11Merge acpi-2.6.12 to-akpmLen Brown1-112/+59
2005-08-11[ACPI] Lindent drivers/acpi/ec.cLen Brown1-480/+389
necessary for clean merge from acpi-2.6.12 to-akpm Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-11[ACPI] Fix "ec_burst=1" mode latency issueLuming Yu1-110/+59
http://bugzilla.kernel.org/show_bug.cgi?id=3851 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-05[ACPI] Lindent all ACPI filesLen Brown145-23325/+20549
Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-05[ACPI] whitespacePavel Machek4-67/+32
Signed-off-by: Pavel Machek <pavel@suse.cz> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-05[ACPI] Merge acpi-2.6.12 branch into 2.6.13-rc3Len Brown4-8/+19
Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-04[ACPI] ACPI_HOTPLUG_CPU Kconfig dependency updateAdrian Bunk1-5/+3
prevent: HOTPLUG_CPU=y ACPI_PROCESSOR=y ACPI_HOTPLUG_CPU=n Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-04[ACPI] lint: irqrouter_suspend() takes a pm_message_t, not a u32Andrew Morton1-4/+1
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-04[ACPI] acpi_remove_notify_handler() on video driver unloadKarol Kozimor1-0/+7
The video driver doesn't properly remove all the notify handlers on module unload. This has a side effect of subdevices failing to register on module reload, but sudden death looms if the handlers trigger after the module is unloaded. Signed-off-by: Karol Kozimor <sziwan@hell.org.pl> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-04[ACPI] acpi_pci_enable_irq() now checks for acpi_register_gsi() errorsKenji Kaneshige1-1/+8
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-04/home/lenb/src/to-akpm branch 'acpi-2.6.12'Len Brown61-2698/+3409
2005-08-04Merge master.kernel.org:/pub/scm/linux/kernel/git/lenb/to-linusLinus Torvalds3-7/+12
2005-08-04When a merge does not work automatically, git preventsLen Brown1-0/+1
commit from running until a change has been made in the destination. In this instance the desired result was to choose the destination version of the file and ignore the source version, but git would not allow that. Here I added a blank line to let git commit think I resolved a merge conflict.
2005-08-03Merge ../to-linus-stableLen Brown1-6/+0
2005-08-03/home/lenb/src/to-linus-stable branch 'acpi-2.6.12'Len Brown1-6/+0
2005-08-03[ACPI] S3 resume: avoid kmalloc() might_sleep oops symptomDavid Shaohua Li2-1/+12
ACPI now uses kmalloc(...,GPF_ATOMIC) during suspend/resume. http://bugzilla.kernel.org/show_bug.cgi?id=3469 Signed-off-by: David Shaohua Li <shaohua.li@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-03[ACPI] delete Warning: Encountered executable code at module level, ↵Len Brown1-6/+0
[AE_NOT_CONFIGURED] http://bugzilla.kernel.org/show_bug.cgi?id=4923 Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-03Merge master.kernel.org:/pub/scm/linux/kernel/git/lenb/to-linusLinus Torvalds6-309/+634
2005-08-03/home/lenb/src/to-linus branch 'acpi-2.6.12'Len Brown6-309/+634
2005-08-03Merge ../to-linusLen Brown6-309/+634
2005-08-03[ACPI] CONFIG_ACPI_HOTKEY is now "n" by defaultLuming Yu2-299/+396
For 2.6.12 behaviour, this (EXPERIMENTAL) driver should not be built. Update the driver source with latest from Luming. Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-03[ACPI] restore /proc/acpi/button/ (ala 2.6.12)Alexey Starikovskiy1-1/+205
Signed-off-by Alexey Starikovskiy <alexey.y.starikovskiy@intel.com> Signed-off-by Len Brown <len.brown@intel.com>
2005-08-03[ACPI] revert Embedded Controller to polling-mode by default (ala 2.6.12)Luming Yu1-5/+19
Burst mode isn't ready for prime time, but can be enabled for test via "ec_burst=1" Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-03[ACPI] PCI interrupt link suspend/resume - revert to 2.6.12 behaviourDavid Shaohua Li1-0/+11
This patch disables the PCI Interrupt Link refernece counts, which should not co-exist with the 2.6.12 irq_router.resume method or else a double acpi_pci_link_set() could result on resume. Signed-off-by: David Shaohua Li <shaohua.li@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-03[ACPI] fix 64-bit build warning in processor_idle.cLen Brown1-4/+3
Signed-off-by: Len Brown <len.brown@intel.com>
2005-08-02[PATCH] ACPI: increase PCIBIOS_MIN_IO on x86Ivan Kokshaysky1-1/+1
We have increased PCIBIOS_MIN_IO to 0x4000, but still want motherboard resources to be allocated properly. So we need to state 0x1000 (according to the comment) limit explicitely. Signed-off-by: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-08-01Revert ACPI interrupt resume changesLinus Torvalds1-20/+18
If there are devices that use interrupts over a suspend event, ACPI must restore the PCI interrupt links on resume. Anything else breaks any device that hasn't been converted to the new (dubious) PM rules. Drivers that need the irq free/re-aquire sequence can be done one by one independently of this one.
2005-07-30[ACPI] ACPICA 20050729 from Bob MooreRobert Moore23-362/+426
Implemented support to ignore an attempt to install/load a particular ACPI table more than once. Apparently there exists BIOS code that repeatedly attempts to load the same SSDT upon certain events. Thanks to Venkatesh Pallipadi. Restructured the main interface to the AML parser in order to correctly handle all exceptional conditions. This will prevent leakage of the OwnerId resource and should eliminate the AE_OWNER_ID_LIMIT exceptions seen on some machines. Thanks to Alexey Starikovskiy. Support for "module level code" has been disabled in this version due to a number of issues that have appeared on various machines. The support can be enabled by defining ACPI_ENABLE_MODULE_LEVEL_CODE during subsystem compilation. When the issues are fully resolved, the code will be enabled by default again. Modified the internal functions for debug print support to define the FunctionName parameter as a (const char *) for compatibility with compiler built-in macros such as __FUNCTION__, etc. Linted the entire ACPICA source tree for both 32-bit and 64-bit. Signed-off-by: Robert Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-29/home/lenb/src/to-linus branch 'acpi-2.6.12'Len Brown4-227/+885
2005-07-29Merge ../to-linusLen Brown4-241/+888
2005-07-29[ACPI] suspend/resume ACPI PCI Interrupt LinksDavid Shaohua Li2-42/+146
Add reference count and disable ACPI PCI Interrupt Link when no device still uses it. Warn when drivers have not released Link at suspend time. http://bugzilla.kernel.org/show_bug.cgi?id=3469 Signed-off-by: David Shaohua Li <shaohua.li@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-29[ACPI] delete boot-time printk()s from processor_idle.cVenkatesh Pallipadi1-2/+0
http://bugzilla.kernel.org/show_bug.cgi?id=4401 Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-29[ACPI] Add "ec_polling" boot optionLuming Yu1-171/+722
EC burst mode benefits many machines, some of them significantly. However, our current implementation fails on some machines such as Rafael's Asus L5D. This patch restores the alternative EC polling code, which can be enabled at boot time via "ec_polling" http://bugzilla.kernel.org/show_bug.cgi?id=4665 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-29[ACPI] address boot-freeze with updated DMI blacklist for c-statesDavid Shaohua Li1-9/+12
http://bugzilla.kernel.org/show_bug.cgi?id=4763 Signed-off-by: David Shaohua Li <shaohua.li@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-29[ACPI] Fix memset arguments in acpi processor_idle.cVenkatesh Pallipadi1-2/+4
http://bugzilla.kernel.org/show_bug.cgi?id=4954 Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-29[ACPI] Fix the regression with c1_default_handler on some systemsVenkatesh Pallipadi1-1/+1
where C-states come from FADT. Thanks to Kevin Radloff for identifying the issue and isolating it to exact line of code that is causing the issue. Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-29[ACPI] disable module level AML code (for now)Len Brown1-0/+2
It is important that we support module level code -- BIOS's implement it. But this implementation needs more testing. Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-29[ACPI] comment out prototypes for new unused debug routinesLen Brown1-2/+1
Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-26[PATCH] acpi: Don't call acpi_sleep_prepare from acpi_power_offEric W. Biederman1-21/+12
Now that all of the code paths that call acpi_power_off have been modified to call either call kernel_power_off (which calls apci_sleep_prepare by way of acpi_shutdown) or to call acpi_sleep_prepare directly it is redundant to call acpi_sleep_prepare from acpi_power_off. So simplify the code and simply don't call acpi_sleep_prepare. In addition there is a little error handling done so if we can't register the acpi class we don't hook pm_power_off. I think I have done the right thing with the CONFIG_PM define but I'm not certain. Can this code even be compiled if CONFIG_PM is false? Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-07-26[PATCH] acpi_power_off: Don't switch to the boot cpuEric W. Biederman1-1/+0
machine_power_off on i386 and x86_64 now switch to the boot cpu out of paranoia and because the MP Specification indicates it is a good idea on reboot, so for those architectures it is a noop. I can't see anything in the acpi spec that requires you to be on the boot cpu to power off the system, so this should not be an issue for ia64. In addition ia64 has the altix a massive multi-node system where switching to the boot cpu sounds insane as we may hot removed the boot cpu. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-07-23/home/lenb/linux-2.6 branch 'acpi-2.6.12'Luming Yu1-14/+3
2005-07-23ACPI: delete unnecessary EC console messagesLuming Yu1-14/+3
http://bugzilla.kernel.org/show_bug.cgi?id=4534 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-14ACPICA 20050708 from Bob Moore <robert.moore@intel.com>Robert Moore22-333/+377
The use of the CPU stack in the debug version of the subsystem has been considerably reduced. Previously, a debug structure was declared in every function that used the debug macros. This structure has been removed in favor of declaring the individual elements as parameters to the debug functions. This reduces the cumulative stack use during nested execution of ACPI function calls at the cost of a small increase in the code size of the debug version of the subsystem. With assistance from Alexey Starikovskiy and Len Brown. Added the ACPI_GET_FUNCTION_NAME macro to enable the compiler-dependent headers to define a macro that will return the current function name at runtime (such as __FUNCTION__ or _func_, etc.) The function name is used by the debug trace output. If ACPI_GET_FUNCTION_NAME is not defined in the compiler-dependent header, the function name is saved on the CPU stack (one pointer per function.) This mechanism is used because apparently there exists no standard ANSI-C defined macro that that returns the function name. Alexey Starikovskiy redesigned and reimplemented the "Owner ID" mechanism used to track namespace objects created/deleted by ACPI tables and control method execution. A bitmap is now used to allocate and free the IDs, thus solving the wraparound problem present in the previous implementation. The size of the namespace node descriptor was reduced by 2 bytes as a result. Removed the UINT32_BIT and UINT16_BIT types that were used for the bitfield flag definitions within the headers for the predefined ACPI tables. These have been replaced by UINT8_BIT in order to increase the code portability of the subsystem. If the use of UINT8 remains a problem, we may be forced to eliminate bitfields entirely because of a lack of portability. Alexey Starikovksiy enhanced the performance of acpi_ut_update_object_reference. This is a frequently used function and this improvement increases the performance of the entire subsystem. Alexey Starikovskiy fixed several possible memory leaks and the inverse - premature object deletion. Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-14[ACPI] revert R40 workaroundDavid Shaohua Li1-39/+3
Should not be necessary... http://bugme.osdl.org/show_bug.cgi?id=1038 Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-13ACPICA 20050617-0624 from Bob Moore <robert.moore@intel.com>Robert Moore40-1941/+2469
ACPICA 20050617: Moved the object cache operations into the OS interface layer (OSL) to allow the host OS to handle these operations if desired (for example, the Linux OSL will invoke the slab allocator). This support is optional; the compile time define ACPI_USE_LOCAL_CACHE may be used to utilize the original cache code in the ACPI CA core. The new OSL interfaces are shown below. See utalloc.c for an example implementation, and acpiosxf.h for the exact interface definitions. Thanks to Alexey Starikovskiy. acpi_os_create_cache acpi_os_delete_cache acpi_os_purge_cache acpi_os_acquire_object acpi_os_release_object Modified the interfaces to acpi_os_acquire_lock and acpi_os_release_lock to return and restore a flags parameter. This fits better with many OS lock models. Note: the current execution state (interrupt handler or not) is no longer passed to these interfaces. If necessary, the OSL must determine this state by itself, a simple and fast operation. Thanks to Alexey Starikovskiy. Fixed a problem in the ACPI table handling where a valid XSDT was assumed present if the revision of the RSDP was 2 or greater. According to the ACPI specification, the XSDT is optional in all cases, and the table manager therefore now checks for both an RSDP >=2 and a valid XSDT pointer. Otherwise, the RSDT pointer is used. Some ACPI 2.0 compliant BIOSs contain only the RSDT. Fixed an interpreter problem with the Mid() operator in the case of an input string where the resulting output string is of zero length. It now correctly returns a valid, null terminated string object instead of a string object with a null pointer. Fixed a problem with the control method argument handling to allow a store to an Arg object that already contains an object of type Device. The Device object is now correctly overwritten. Previously, an error was returned. ACPICA 20050624: Modified the new OSL cache interfaces to use ACPI_CACHE_T as the type for the host-defined cache object. This allows the OSL implementation to define and type this object in any manner desired, simplifying the OSL implementation. For example, ACPI_CACHE_T is defined as kmem_cache_t for Linux, and should be defined in the OS-specific header file for other operating systems as required. Changed the interface to AcpiOsAcquireObject to directly return the requested object as the function return (instead of ACPI_STATUS.) This change was made for performance reasons, since this is the purpose of the interface in the first place. acpi_os_acquire_object is now similar to the acpi_os_allocate interface. Thanks to Alexey Starikovskiy. Modified the initialization sequence in acpi_initialize_subsystem to call the OSL interface acpi_osl_initialize first, before any local initialization. This change was required because the global initialization now calls OSL interfaces. Restructured the code base to split some files because of size and/or because the code logically belonged in a separate file. New files are listed below. utilities/utcache.c /* Local cache interfaces */ utilities/utmutex.c /* Local mutex support */ utilities/utstate.c /* State object support */ parser/psloop.c /* Main AML parse loop */ Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-13ACPICA 20050526 from Bob Moore <robert.moore@intel.com>Robert Moore12-89/+196
Implemented support to execute Type 1 and Type 2 AML opcodes appearing at the module level (not within a control method.) These opcodes are executed exactly once at the time the table is loaded. This type of code was legal up until the release of ACPI 2.0B (2002) and is now supported within ACPI CA in order to provide backwards compatibility with earlier BIOS implementations. This eliminates the "Encountered executable code at module level" warning that was previously generated upon detection of such code. Fixed a problem in the interpreter where an AE_NOT_FOUND exception could inadvertently be generated during the lookup of namespace objects in the second pass parse of ACPI tables and control methods. It appears that this problem could occur during the resolution of forward references to namespace objects. Added the ACPI_MUTEX_DEBUG #ifdef to the acpi_ut_release_mutex function, corresponding to the same the deadlock detection debug code to be compiled out in the normal case, improving mutex performance (and overall subsystem performance) considerably. As suggested by Alexey Starikovskiy. Implemented a handful of miscellaneous fixes for possible memory leaks on error conditions and error handling control paths. These fixes were suggested by FreeBSD and the Coverity Prevent source code analysis tool. Added a check for a null RSDT pointer in acpi_get_firmware_table (tbxfroot.c) to prevent a fault in this error case. Signed-off-by Len Brown <len.brown@intel.com>
2005-07-13ACPICA from Bob Moore <robert.moore@intel.com>Robert Moore12-84/+80
Implemented support for PCI Express root bridges -- added support for device PNP0A08 in the root bridge search within AcpiEvPciConfigRegionSetup. acpi_ev_pci_config_region_setup(). The interpreter now automatically truncates incoming 64-bit constants to 32 bits if currently executing out of a 32-bit ACPI table (Revision < 2). This also affects the iASL compiler constant folding. (Note: as per below, the iASL compiler no longer allows 64-bit constants within 32-bit tables.) Fixed a problem where string and buffer objects with "static" pointers (pointers to initialization data within an ACPI table) were not handled consistently. The internal object copy operation now always copies the data to a newly allocated buffer, regardless of whether the source object is static or not. Fixed a problem with the FromBCD operator where an implicit result conversion was improperly performed while storing the result to the target operand. Since this is an "explicit conversion" operator, the implicit conversion should never be performed on the output. Fixed a problem with the CopyObject operator where a copy to an existing named object did not always completely overwrite the existing object stored at name. Specifically, a buffer-to-buffer copy did not delete the existing buffer. Replaced "interrupt_level" with "interrupt_number" in all GPE interfaces and structs for consistency. Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] merge acpi-2.6.12 branch into latest Linux 2.6.13-rc...Len Brown121-4152/+6405
Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] enable C2 and C3 idle power states on SMPVenkatesh Pallipadi3-66/+109
http://bugzilla.kernel.org/show_bug.cgi?id=4401 Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] EC GPE-disabled issueLuming Yu1-11/+9
http://bugzilla.kernel.org/show_bug.cgi?id=3851 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] fix merge error that broke CONFIG_ACPI_DEBUG=y buildLen Brown1-1/+1
Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] cleanup: delete !IA64_SGI_SN from acpi/KconfigJesse Barnes1-11/+0
Signed-off-by: Jesse Barnes <jbarnes@sgi.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] quiet dmesg related to ACPI PM of PCI devicesDavid Shaohua Li1-6/+4
DBG("No ACPI bus support for %s\n", dev->bus_id); http://bugzilla.kernel.org/show_bug.cgi?id=4277 Signed-off-by: David Shaohua Li <shaohua.li@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12ACPICA 20050408 from Bob MooreRobert Moore101-3598/+4390
Fixed three cases in the interpreter where an "index" argument to an ASL function was still (internally) 32 bits instead of the required 64 bits. This was the Index argument to the Index, Mid, and Match operators. The "strupr" function is now permanently local (acpi_ut_strupr), since this is not a POSIX-defined function and not present in most kernel-level C libraries. References to the C library strupr function have been removed from the headers. Completed the deployment of static functions/prototypes. All prototypes with the static attribute have been moved from the headers to the owning C file. ACPICA 20050329 from Bob Moore An error is now generated if an attempt is made to create a Buffer Field of length zero (A CreateField with a length operand of zero.) The interpreter now issues a warning whenever executable code at the module level is detected during ACPI table load. This will give some idea of the prevalence of this type of code. Implemented support for references to named objects (other than control methods) within package objects. Enhanced package object output for the debug object. Package objects are now completely dumped, showing all elements. Enhanced miscellaneous object output for the debug object. Any object can now be written to the debug object (for example, a device object can be written, and the type of the object will be displayed.) The "static" qualifier has been added to all local functions across the core subsystem. The number of "long" lines (> 80 chars) within the source has been significantly reduced, by about 1/3. Cleaned up all header files to ensure that all CA/iASL functions are prototyped (even static functions) and the formatting is consistent. Two new header files have been added, acopcode.h and acnames.h. Removed several obsolete functions that were no longer used. Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] Deprecate /proc/acpi/sleep in favor of /sys/power/stateLen Brown2-0/+17
Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] PNPACPI vs sound IRQDavid Shaohua Li1-2/+5
http://bugme.osdl.org/show_bug.cgi?id=4016 Written-by: David Shaohua Li <shaohua.li@intel.com> Acked-by: Adam Belay <abelay@novell.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] update /proc/acpi/processor/*/power even if only C1 supportVenkatesh Pallipadi1-7/+26
Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-12[ACPI] hotplug Processor consideration in acpi_bus_add()Keiichiro Tokunaga1-5/+7
Signed-off-by: Keiichiro Tokunaga <tokunaga.keiich@jp.fujitsu.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] fix debug-mode build warning in acpi/hotkey.cAndrew Morton1-1/+2
drivers/acpi/hotkey.c: In function `create_polling_proc': drivers/acpi/hotkey.c:334: warning: ISO C90 forbids mixed declarations and code Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] fix kmalloc size bug in acpi/video.cPaulo Marques1-7/+6
acpi_video_device_find_cap() used &p instead of *p when calculating storage size, thus allocating only 4 or 8 bytes instead of 12... Also, kfree(NULL) is legal, so remove some unneeded checks. From: Paulo Marques <pmarques@grupopie.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] fix potential NULL dereference in acpi/video.cAdrian Bunk1-1/+1
Found-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] check for kmalloc failure in toshiba_acpi.cPanagiotis Issaris1-0/+3
Signed-off-by: Panagiotis Issaris <takis@gna.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] fix build warningAndrew Morton1-1/+1
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] fix EC access widthLuming Yu1-18/+14
http://bugzilla.kernel.org/show_bug.cgi?id=4346 Written-by: David Shaohua Li and Luming Yu Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] Enable EC Burst ModeDmitry Torokhov1-114/+276
Fixes several Embedded Controller issues, including button failure and battery status AE_TIME failure. http://bugzilla.kernel.org/show_bug.cgi?id=3851 Based on patch by: Andi Kleen <ak@suse.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru> Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] pci_set_power_state() now callsDavid Shaohua Li1-1/+7
platform_pci_set_power_state() and ACPI can answer http://bugzilla.kernel.org/show_bug.cgi?id=4277 Signed-off-by: David Shaohua Li <shaohua.li@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] Bind PCI devices with ACPI devicesDavid Shaohua Li3-3/+365
Implement the framework for binding physical devices with ACPI devices. A physical bus like PCI bus should create a 'acpi_bus_type', with: .find_device: For device which has parent such as normal PCI devices. .find_bridge: It's for special devices, such as PCI root bridge or IDE controller. Such devices generally haven't a parent or ->bus. We use the special method to get an ACPI handle. Uses new field in struct device: firmware_data http://bugzilla.kernel.org/show_bug.cgi?id=4277 Signed-off-by: David Shaohua Li <shaohua.li@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] generic Hot Key supportLuming Yu7-1/+1054
See Documentation/acpi-hotkey.txt Use cmdline "acpi_specific_hotkey" to enable legacy platform specific drivers. http://bugzilla.kernel.org/show_bug.cgi?id=3887 Signed-off-by: Luming Yu <luming.yu@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] S3 Suspend to RAM: interrupt resume fixDavid Shaohua Li1-22/+14
Delete PCI Interrupt Link Device .resume method -- it is the device driver's job to request interrupts, not the Link's job to remember what the devices want. This addresses the issue of attempting to run the ACPI interpreter too early in resume, when interrupts are still disabled. http://bugzilla.kernel.org/show_bug.cgi?id=3469 Signed-off-by: David Shaohua Li <shaohua.li@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] ACPI poweroff fixAlexey Starikovskiy2-50/+105
Register an "acpi" system device to be notified of shutdown preparation. This depends on CONFIG_PM http://bugzilla.kernel.org/show_bug.cgi?id=4041 Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] CONFIG_ACPI now depends on CONFIG_PMLen Brown1-1/+2
Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] Allow simultaneous Fixed Feature and Control Method buttonsAlexey Starikovskiy1-244/+1
delete /proc/acpi/button http://bugzilla.kernel.org/show_bug.cgi?id=1920 Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-11[ACPI] update CONFIG_ACPI_CONTAINER Kconfig helpKeiichiro Tokunaga1-2/+7
Signed-off-by: Keiichiro Tokunaga <tokunaga.keiich@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Len Brown <len.brown@intel.com>
2005-07-02If ACPI doesn't find an irq listed, don't accept 0 as a valid PCI irq.Linus Torvalds1-1/+1
That zero just means that nothing else found any irq information either.
2005-06-27[PATCH] acpi bridge hotadd: Export the interface to get PCI id for an ACPI ↵Rajesh Shah1-6/+5
handle Export an acpi interface to get PCI domain/bus/devfn information from the corresponding namespace handle. Used by acpiphp code to transpate the device handle of the hot-plugged root bridge to the corresponding pci location information. Signed-off-by: Rajesh Shah <rajesh.shah@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2005-06-27[PATCH] acpi bridge hotadd: Allow ACPI .add and .start operations to be done ↵Rajesh Shah3-27/+103
independently Create new interfaces to recursively add an acpi namespace object to the acpi device list, and recursively start the namespace object. This is needed for ACPI based hotplug of a root bridge hierarchy where the add operation must be performed first and the start operation must be performed separately after the hot-plugged devices have been properly configured. Signed-off-by: Rajesh Shah <rajesh.shah@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2005-06-27[PATCH] acpi bridge hotadd: ACPI based root bridge hot-addRajesh Shah2-2/+38
When you hot-plug a (root) bridge hierarchy, it may have p2p bridges and devices attached to it that have not been configured by firmware. In this case, we need to configure the devices before starting them. This patch separates device start from device scan so that we can introduce the configuration step in the middle. I kept the existing semantics for pci_scan_bus() since there are a huge number of callers to that function. Also, I have no way of testing the changes I made to the parisc files, so this needs review by those folks. Sorry for the massive cross-post, this touches files in many different places. Signed-off-by: Rajesh Shah <rajesh.shah@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2005-06-25[PATCH] suspend/resume SMP supportLi Shaohua1-1/+1
Using CPU hotplug to support suspend/resume SMP. Both S3 and S4 use disable/enable_nonboot_cpus API. The S4 part is based on Pavel's original S4 SMP patch. Signed-off-by: Li Shaohua<shaohua.li@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-06-25ACPI: Make sure we call acpi_register_gsi() even for default PCI interrupt ↵Linus Torvalds1-0/+1
assignment That's the part that keeps track of the ELCR register, and we want to make sure that the PCI interrupts are properly marked level/low.
2005-06-21[PATCH] smp_processor_id() cleanupIngo Molnar1-1/+1
This patch implements a number of smp_processor_id() cleanup ideas that Arjan van de Ven and I came up with. The previous __smp_processor_id/_smp_processor_id/smp_processor_id API spaghetti was hard to follow both on the implementational and on the usage side. Some of the complexity arose from picking wrong names, some of the complexity comes from the fact that not all architectures defined __smp_processor_id. In the new code, there are two externally visible symbols: - smp_processor_id(): debug variant. - raw_smp_processor_id(): nondebug variant. Replaces all existing uses of _smp_processor_id() and __smp_processor_id(). Defined by every SMP architecture in include/asm-*/smp.h. There is one new internal symbol, dependent on DEBUG_PREEMPT: - debug_smp_processor_id(): internal debug variant, mapped to smp_processor_id(). Also, i moved debug_smp_processor_id() from lib/kernel_lock.c into a new lib/smp_processor_id.c file. All related comments got updated and/or clarified. I have build/boot tested the following 8 .config combinations on x86: {SMP,UP} x {PREEMPT,!PREEMPT} x {DEBUG_PREEMPT,!DEBUG_PREEMPT} I have also build/boot tested x64 on UP/PREEMPT/DEBUG_PREEMPT. (Other architectures are untested, but should work just fine.) Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Arjan van de Ven <arjan@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-06-20[PATCH] sysfs: (rest) if show/store is missing return -EIODmitry Torokhov1-2/+2
sysfs: fix the rest of the kernel so if an attribute doesn't implement show or store method read/write will return -EIO instead of 0 or -EINVAL or -EPERM. Signed-off-by: Dmitry Torokhov <dtor@mail.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2005-05-27[PATCH] ACPI build fixLen Brown1-3/+2
Fix 2.6.12 CONFIG_ACPI=n build regression. CONFIG_ACPI_BOOT shall be set only if CONFIG_ACPI. Signed-off-by: Len Brown <len.brown@intel.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-05-27[PATCH] VIA IRQ quirkLen Brown1-4/+0
Delete quirk_via_bridge(), restore quirk_via_irqpic() -- but now improved to be invoked upon device ENABLE, and now only for VIA devices -- not all devices behind VIA bridges. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Signed-off-by: Len Brown <len.brown@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-05-01[PATCH] DocBook: fix some descriptionsMartin Waitz1-2/+2
Some KernelDoc descriptions are updated to match the current code. No code changes. Signed-off-by: Martin Waitz <tali@admingilde.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-05-01[PATCH] Change synchronize_kernel to _rcu and _schedPaul E. McKenney1-1/+1
This patch changes calls to synchronize_kernel(), deprecated in the earlier "Deprecate synchronize_kernel, GPL replacement" patch to instead call the new synchronize_rcu() and synchronize_sched() APIs. Signed-off-by: Paul E. McKenney <paulmck@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>