diff options
author | Linas Vepstas <linas@austin.ibm.com> | 2007-08-09 16:56:41 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2007-08-16 21:01:52 -0400 |
commit | 0f2342c85df4248bc1cd72421b13969a0782ed6a (patch) | |
tree | b72286b35e4bb7502ea504ae5e6ddebd6da725d8 /arch/powerpc/platforms/pseries/rtasd.c | |
parent | 79c0108d1b9db4864ab77b2a95dfa04f2dcf264c (diff) |
[POWERPC] pseries: Eliminate global error_log_cnt variable
Eliminate the use of error_log_cnt as a global var shared across
different directories. Pass it as a parameter instead.
Signed-off-by: Linas Vepstas <linas@austin.ibm.com>
----
Respin of earlier patch, with the CONFIG_PSERIES junk removed from the
header file.
arch/powerpc/kernel/nvram_64.c | 10 +++++-----
arch/powerpc/platforms/pseries/rtasd.c | 7 ++++---
include/asm-powerpc/nvram.h | 6 ++++--
3 files changed, 13 insertions(+), 10 deletions(-)
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/platforms/pseries/rtasd.c')
-rw-r--r-- | arch/powerpc/platforms/pseries/rtasd.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/powerpc/platforms/pseries/rtasd.c b/arch/powerpc/platforms/pseries/rtasd.c index b802a272bd29..30925d29bcea 100644 --- a/arch/powerpc/platforms/pseries/rtasd.c +++ b/arch/powerpc/platforms/pseries/rtasd.c | |||
@@ -56,7 +56,7 @@ static int full_rtas_msgs = 0; | |||
56 | /* Stop logging to nvram after first fatal error */ | 56 | /* Stop logging to nvram after first fatal error */ |
57 | static int no_more_logging; | 57 | static int no_more_logging; |
58 | 58 | ||
59 | volatile int error_log_cnt = 0; | 59 | static int error_log_cnt; |
60 | 60 | ||
61 | /* | 61 | /* |
62 | * Since we use 32 bit RTAS, the physical address of this must be below | 62 | * Since we use 32 bit RTAS, the physical address of this must be below |
@@ -218,7 +218,7 @@ void pSeries_log_error(char *buf, unsigned int err_type, int fatal) | |||
218 | 218 | ||
219 | /* Write error to NVRAM */ | 219 | /* Write error to NVRAM */ |
220 | if (!no_more_logging && !(err_type & ERR_FLAG_BOOT)) | 220 | if (!no_more_logging && !(err_type & ERR_FLAG_BOOT)) |
221 | nvram_write_error_log(buf, len, err_type); | 221 | nvram_write_error_log(buf, len, err_type, error_log_cnt); |
222 | 222 | ||
223 | /* | 223 | /* |
224 | * rtas errors can occur during boot, and we do want to capture | 224 | * rtas errors can occur during boot, and we do want to capture |
@@ -412,7 +412,8 @@ static int rtasd(void *unused) | |||
412 | 412 | ||
413 | /* See if we have any error stored in NVRAM */ | 413 | /* See if we have any error stored in NVRAM */ |
414 | memset(logdata, 0, rtas_error_log_max); | 414 | memset(logdata, 0, rtas_error_log_max); |
415 | rc = nvram_read_error_log(logdata, rtas_error_log_max, &err_type); | 415 | rc = nvram_read_error_log(logdata, rtas_error_log_max, |
416 | &err_type, &error_log_cnt); | ||
416 | 417 | ||
417 | if (!rc) { | 418 | if (!rc) { |
418 | if (err_type != ERR_FLAG_ALREADY_LOGGED) { | 419 | if (err_type != ERR_FLAG_ALREADY_LOGGED) { |