git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git]
/
drivers
/
parisc
/
power.c
diff --git
a/drivers/parisc/power.c
b/drivers/parisc/power.c
index
ff75e92
..
0bcab83
100644
(file)
--- a/
drivers/parisc/power.c
+++ b/
drivers/parisc/power.c
@@
-2,7
+2,7
@@
* linux/arch/parisc/kernel/power.c
* HP PARISC soft power switch support driver
*
* linux/arch/parisc/kernel/power.c
* HP PARISC soft power switch support driver
*
- * Copyright (c) 2001-200
2
Helge Deller <deller@gmx.de>
+ * Copyright (c) 2001-200
5
Helge Deller <deller@gmx.de>
* All rights reserved.
*
*
* All rights reserved.
*
*
@@
-102,7
+102,7
@@
static DECLARE_WORK(poweroff_work, deferred_poweroff, NULL);
static void poweroff(void)
{
static void poweroff(void)
{
- static int powering_off;
+ static int powering_off
__read_mostly
;
if (powering_off)
return;
if (powering_off)
return;
@@
-113,7
+113,7
@@
static void poweroff(void)
/* local time-counter for shutdown */
/* local time-counter for shutdown */
-static int shutdown_timer;
+static int shutdown_timer
__read_mostly
;
/* check, give feedback and start shutdown after one second */
static void process_shutdown(void)
/* check, give feedback and start shutdown after one second */
static void process_shutdown(void)
@@
-139,7
+139,7
@@
static void process_shutdown(void)
DECLARE_TASKLET_DISABLED(power_tasklet, NULL, 0);
/* soft power switch enabled/disabled */
DECLARE_TASKLET_DISABLED(power_tasklet, NULL, 0);
/* soft power switch enabled/disabled */
-int pwrsw_enabled = 1;
+int pwrsw_enabled
__read_mostly
= 1;
/*
* On gecko style machines (e.g. 712/xx and 715/xx)
/*
* On gecko style machines (e.g. 712/xx and 715/xx)
@@
-149,7
+149,7
@@
int pwrsw_enabled = 1;
*/
static void gecko_tasklet_func(unsigned long unused)
{
*/
static void gecko_tasklet_func(unsigned long unused)
{
- if (
!pwrsw_enabled
)
+ if (
unlikely(!pwrsw_enabled)
)
return;
if (__getDIAG(25) & 0x80000000) {
return;
if (__getDIAG(25) & 0x80000000) {
@@
-173,7
+173,7
@@
static void polling_tasklet_func(unsigned long soft_power_reg)
{
unsigned long current_status;
{
unsigned long current_status;
- if (
!pwrsw_enabled
)
+ if (
unlikely(!pwrsw_enabled)
)
return;
current_status = gsc_readl(soft_power_reg);
return;
current_status = gsc_readl(soft_power_reg);
@@
-251,7
+251,8
@@
static int __init power_init(void)
}
/* Register a call for panic conditions. */
}
/* Register a call for panic conditions. */
- notifier_chain_register(&panic_notifier_list, &parisc_panic_block);
+ atomic_notifier_chain_register(&panic_notifier_list,
+ &parisc_panic_block);
tasklet_enable(&power_tasklet);
tasklet_enable(&power_tasklet);
@@
-264,7
+265,8
@@
static void __exit power_exit(void)
return;
tasklet_disable(&power_tasklet);
return;
tasklet_disable(&power_tasklet);
- notifier_chain_unregister(&panic_notifier_list, &parisc_panic_block);
+ atomic_notifier_chain_unregister(&panic_notifier_list,
+ &parisc_panic_block);
power_tasklet.func = NULL;
pdc_soft_power_button(0);
}
power_tasklet.func = NULL;
pdc_soft_power_button(0);
}