diff options
author | David Woodhouse <dwmw2@infradead.org> | 2005-11-17 01:44:03 +0100 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2005-11-17 06:53:38 +0100 |
commit | 1e28a7ddd3e713384e9c6768e7c502031dc205e2 (patch) | |
tree | 7600b576b660a531b27a72bd2e9ff67031c4dadb /include/asm-powerpc/eeh.h | |
parent | [PATCH] powerpc: Fix database regression due to scheduler changes (diff) | |
download | linux-1e28a7ddd3e713384e9c6768e7c502031dc205e2.tar.xz linux-1e28a7ddd3e713384e9c6768e7c502031dc205e2.zip |
[PATCH] Avoid use of uninitialised spinlock in EEH.
If the kernel supports both G5 and pSeries, and CONFIG_EEH is enabled,
eeh_init() is (quite reasonably) never called when we boot on a G5. Yet
eeh_check_failure() still gets called. We should avoid doing that if
!eeh_subsystem_enabled.
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'include/asm-powerpc/eeh.h')
-rw-r--r-- | include/asm-powerpc/eeh.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/asm-powerpc/eeh.h b/include/asm-powerpc/eeh.h index 89f26ab31908..f8633aafe4ba 100644 --- a/include/asm-powerpc/eeh.h +++ b/include/asm-powerpc/eeh.h @@ -30,6 +30,8 @@ struct device_node; #ifdef CONFIG_EEH +extern int eeh_subsystem_enabled; + /* Values for eeh_mode bits in device_node */ #define EEH_MODE_SUPPORTED (1<<0) #define EEH_MODE_NOCHECK (1<<1) @@ -75,7 +77,7 @@ void eeh_remove_device(struct pci_dev *); * If this macro yields TRUE, the caller relays to eeh_check_failure() * which does further tests out of line. */ -#define EEH_POSSIBLE_ERROR(val, type) ((val) == (type)~0) +#define EEH_POSSIBLE_ERROR(val, type) ((val) == (type)~0 && eeh_subsystem_enabled) /* * Reads from a device which has been isolated by EEH will return |