diff options
| author | Linus Torvalds <torvalds@athlon.transmeta.com> | 2002-02-04 17:57:11 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@athlon.transmeta.com> | 2002-02-04 17:57:11 -0800 |
| commit | c8ebfc888f9ee93f2dc7cd62b3be66263755d99a (patch) | |
| tree | f449a3433c022ed8fd9aaa8f291a1b4e354fd5b9 /drivers/acpi/driver.c | |
| parent | 5d12a58c4049a4839abbbdf87dd189505513b1b6 (diff) | |
v2.4.1.2 -> v2.4.1.3
- Jens: better ordering of requests when unable to merge
- Neil Brown: make md work as a module again (we cannot autodetect
in modules, not enough background information)
- Neil Brown: raid5 SMP locking cleanups
- Neil Brown: nfsd: handle Irix NFS clients named pipe behavior and
dentry leak fix
- maestro3 shutdown fix
- fix dcache hash calculation that could cause bad hashes under certain
circumstances (Dean Gaudet)
- David Miller: networking and sparc updates
- Jeff Garzik: include file cleanups
- Andy Grover: ACPI update
- Coda-fs error return fixes
- rth: alpha Jensen update
Diffstat (limited to 'drivers/acpi/driver.c')
| -rw-r--r-- | drivers/acpi/driver.c | 41 |
1 files changed, 40 insertions, 1 deletions
diff --git a/drivers/acpi/driver.c b/drivers/acpi/driver.c index 241528fc6cb9..8863e468833f 100644 --- a/drivers/acpi/driver.c +++ b/drivers/acpi/driver.c @@ -60,6 +60,8 @@ static DECLARE_WAIT_QUEUE_HEAD(acpi_event_wait); static volatile int acpi_thread_pid = -1; +static int acpi_start = 1; + /************************************************/ /* DECLARE_TASK_QUEUE is defined in */ /* /usr/src/linux/include/linux/tqueue.h */ @@ -382,6 +384,19 @@ static struct ctl_table acpi_table[] = &acpi_c3_enter_latency, sizeof(acpi_c3_enter_latency), 0644, NULL, &acpi_do_ulong}, + {ACPI_C1_COUNT, "c1_count", + &acpi_c1_count, sizeof(acpi_c1_count), + 0644, NULL, &acpi_do_ulong}, + + {ACPI_C2_COUNT, "c2_count", + &acpi_c2_count, sizeof(acpi_c2_count), + 0644, NULL, &acpi_do_ulong}, + + {ACPI_C3_COUNT, "c3_count", + &acpi_c3_count, sizeof(acpi_c3_count), + 0644, NULL, &acpi_do_ulong}, + + /* until it actually works */ /* {ACPI_SLEEP, "sleep", NULL, 0, 0600, NULL, &acpi_do_sleep},*/ @@ -540,10 +555,16 @@ acpi_thread(void *context) int __init acpi_init(void) { - acpi_thread_pid = kernel_thread(acpi_thread, + if (acpi_start) { + acpi_thread_pid = kernel_thread(acpi_thread, NULL, (CLONE_FS | CLONE_FILES | CLONE_SIGHAND | SIGCHLD)); + } + else { + printk(KERN_INFO "ACPI: Disabled\n"); + } + return ((acpi_thread_pid >= 0) ? 0:-ENODEV); } @@ -571,3 +592,21 @@ acpi_exit(void) module_init(acpi_init); module_exit(acpi_exit); + +#ifndef MODULE +static int __init acpi_setup(char *str) +{ + while ((str != NULL) && (*str != '\0')) { + if (strncmp(str, "no-idle", 7) == 0) + acpi_use_idle = 0; + if (strncmp(str, "off", 3) == 0) + acpi_start = 0; + str = strchr(str, ','); + if (str != NULL) + str += strspn(str, ", \t"); + } + return 1; +} + +__setup("acpi=", acpi_setup); +#endif |
