Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
86768d2c
Commit
86768d2c
authored
Nov 30, 2004
by
Len Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge intel.com:/home/lenb/src/26-stable-dev
into intel.com:/home/lenb/src/26-latest-dev
parents
c502825f
99e7a1d6
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
45 additions
and
7 deletions
+45
-7
drivers/acpi/pci_link.c
drivers/acpi/pci_link.c
+8
-1
drivers/acpi/sleep/Makefile
drivers/acpi/sleep/Makefile
+2
-2
drivers/acpi/sleep/poweroff.c
drivers/acpi/sleep/poweroff.c
+2
-0
drivers/acpi/sleep/sleep.h
drivers/acpi/sleep/sleep.h
+1
-0
drivers/acpi/sleep/wakeup.c
drivers/acpi/sleep/wakeup.c
+30
-2
drivers/char/ipmi/ipmi_si_intf.c
drivers/char/ipmi/ipmi_si_intf.c
+2
-2
No files found.
drivers/acpi/pci_link.c
View file @
86768d2c
...
...
@@ -791,9 +791,16 @@ static int __init acpi_irq_penalty_update(char *str, int used)
return
1
;
}
/*
* We'd like PNP to call this routine for the
* single ISA_USED value for each legacy device.
* But instead it calls us with each POSSIBLE setting.
* There is no ISA_POSSIBLE weight, so we simply use
* the (small) PCI_USING penalty.
*/
void
acpi_penalize_isa_irq
(
int
irq
)
{
acpi_irq_penalty
[
irq
]
+=
PIRQ_PENALTY_
ISA_USED
;
acpi_irq_penalty
[
irq
]
+=
PIRQ_PENALTY_
PCI_USING
;
}
/*
...
...
drivers/acpi/sleep/Makefile
View file @
86768d2c
obj-y
:=
poweroff.o
obj-$(CONFIG_ACPI_SLEEP)
+=
main.o
wakeup.o
obj-y
:=
poweroff.o
wakeup.o
obj-$(CONFIG_ACPI_SLEEP)
+=
main.o
obj-$(CONFIG_ACPI_SLEEP_PROC_FS)
+=
proc.o
EXTRA_CFLAGS
+=
$(ACPI_CFLAGS)
drivers/acpi/sleep/poweroff.c
View file @
86768d2c
...
...
@@ -9,6 +9,7 @@
#include <linux/init.h>
#include <acpi/acpi_bus.h>
#include <linux/sched.h>
#include "sleep.h"
static
void
acpi_power_off
(
void
)
...
...
@@ -16,6 +17,7 @@ acpi_power_off (void)
printk
(
"%s called
\n
"
,
__FUNCTION__
);
/* Some SMP machines only can poweroff in boot CPU */
set_cpus_allowed
(
current
,
cpumask_of_cpu
(
0
));
acpi_wakeup_gpe_poweroff_prepare
();
acpi_enter_sleep_state_prep
(
ACPI_STATE_S5
);
ACPI_DISABLE_IRQS
();
acpi_enter_sleep_state
(
ACPI_STATE_S5
);
...
...
drivers/acpi/sleep/sleep.h
View file @
86768d2c
...
...
@@ -5,3 +5,4 @@ extern int acpi_suspend (u32 state);
extern
void
acpi_enable_wakeup_device_prep
(
u8
sleep_state
);
extern
void
acpi_enable_wakeup_device
(
u8
sleep_state
);
extern
void
acpi_disable_wakeup_device
(
u8
sleep_state
);
extern
void
acpi_wakeup_gpe_poweroff_prepare
(
void
);
drivers/acpi/sleep/wakeup.c
View file @
86768d2c
/*
* wakeup.c - support wakeup devices
* Copyright (C) 2004 Li Shaohua <shaohua.li@intel.com>
*/
#include <linux/init.h>
...
...
@@ -13,14 +14,16 @@
#define _COMPONENT ACPI_SYSTEM_COMPONENT
ACPI_MODULE_NAME
(
"wakeup_devices"
)
extern
struct
list_head
acpi_wakeup_device_list
;
extern
spinlock_t
acpi_device_lock
;
#ifdef CONFIG_ACPI_SLEEP
/**
* acpi_enable_wakeup_device_prep - prepare wakeup devices
* @sleep_state: ACPI state
* Enable all wakup devices power if the devices' wakeup level
* is higher than requested sleep level
*/
extern
struct
list_head
acpi_wakeup_device_list
;
extern
spinlock_t
acpi_device_lock
;
void
acpi_enable_wakeup_device_prep
(
...
...
@@ -179,3 +182,28 @@ static int __init acpi_wakeup_device_init(void)
}
late_initcall
(
acpi_wakeup_device_init
);
#endif
/*
* Disable all wakeup GPEs before power off.
*
* Since acpi_enter_sleep_state() will disable all
* RUNTIME GPEs, we simply mark all GPES that
* are not enabled for wakeup from S5 as RUNTIME.
*/
void
acpi_wakeup_gpe_poweroff_prepare
(
void
)
{
struct
list_head
*
node
,
*
next
;
list_for_each_safe
(
node
,
next
,
&
acpi_wakeup_device_list
)
{
struct
acpi_device
*
dev
=
container_of
(
node
,
struct
acpi_device
,
wakeup_list
);
/* The GPE can wakeup system from S5, don't touch it */
if
((
u32
)
dev
->
wakeup
.
sleep_state
==
ACPI_STATE_S5
)
continue
;
/* acpi_set_gpe_type will automatically disable GPE */
acpi_set_gpe_type
(
dev
->
wakeup
.
gpe_device
,
dev
->
wakeup
.
gpe_number
,
ACPI_GPE_TYPE_RUNTIME
);
}
}
drivers/char/ipmi/ipmi_si_intf.c
View file @
86768d2c
...
...
@@ -1370,7 +1370,7 @@ static int acpi_gpe_irq_setup(struct smi_info *info)
status
=
acpi_install_gpe_handler
(
NULL
,
info
->
irq
,
ACPI_GPE_LEVEL_TRIGGERED
,
ipmi_acpi_gpe
,
&
ipmi_acpi_gpe
,
info
);
if
(
status
!=
AE_OK
)
{
printk
(
KERN_WARNING
...
...
@@ -1390,7 +1390,7 @@ static void acpi_gpe_irq_cleanup(struct smi_info *info)
if
(
!
info
->
irq
)
return
;
acpi_remove_gpe_handler
(
NULL
,
info
->
irq
,
ipmi_acpi_gpe
);
acpi_remove_gpe_handler
(
NULL
,
info
->
irq
,
&
ipmi_acpi_gpe
);
}
/*
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment