[lkml]   [2003]   [Jun]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
SubjectExport 'acpi_disabled' symbol to modules...

The ACPI subsystem can be today (from a driver point of view) in
three configurations: not compiled (CONFIG_ACPI=n), compiled and
running or compiled and disabled (with acpi=off).

A driver which wants to use some ACPI exported routines (in my
case it's the sonypi driver which wants to use ec_read/ec_write),
needs to know exactly what the ACPI state is.

The only way to do this today (from what I've seen) is to do:

if (!acpi_disabled)
return ec_write(addr, value);
return my_ec_emulated_write(...);

This way on doing things needs however that the 'acpi_disabled'
variable be exported to modules.

Please apply the attached patch or advise on a better way to know
if ACPI is enabled or not (patch generated against the today 2.5 BK



===== arch/i386/kernel/setup.c 1.84 vs edited =====
--- 1.84/arch/i386/kernel/setup.c Sun Jun 8 00:17:53 2003
+++ edited/arch/i386/kernel/setup.c Tue Jun 10 10:02:00 2003
@@ -61,7 +61,8 @@
unsigned long mmu_cr4_features;

-int acpi_disabled __initdata = 0;
+int acpi_disabled;

int MCA_bus;
/* for MCA, but anyone else can use it if they want */
Stelian Pop <>
Alcove -
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:36    [W:0.053 / U:1.444 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site