aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-powerpc/bug.h
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2005-11-01 05:54:38 -0500
committerPaul Mackerras <paulus@samba.org>2005-11-01 05:54:38 -0500
commit89003ebf9e6a9ccb2327caf72955edd86b274c14 (patch)
treeb4e7ff84b1b0aa0adccfac237981e45ea371553a /include/asm-powerpc/bug.h
parenta0e60b2033b30a6bb8479629001cf98e58e4079a (diff)
powerpc: Fix BUG/WARN macros for 64-bit
The bug_entry struct had an int in the middle of pointers and unsigned longs, and the inline asm that generated the bug table entries didn't insert the necessary padding, so the fields following it didn't get initialized properly and an oops resulted. This changes the int field (the line number) to a long so that all the fields are the same size and no padding is required. Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'include/asm-powerpc/bug.h')
-rw-r--r--include/asm-powerpc/bug.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/asm-powerpc/bug.h b/include/asm-powerpc/bug.h
index e4d028e87020..943e3d7dbcc7 100644
--- a/include/asm-powerpc/bug.h
+++ b/include/asm-powerpc/bug.h
@@ -13,7 +13,7 @@
13 13
14#ifdef __powerpc64__ 14#ifdef __powerpc64__
15#define BUG_TABLE_ENTRY(label, line, file, func) \ 15#define BUG_TABLE_ENTRY(label, line, file, func) \
16 ".llong " #label "\n .long " #line "\n .llong " #file ", " #func "\n" 16 ".llong " #label ", " #line ", " #file ", " #func "\n"
17#define TRAP_OP(ra, rb) "1: tdnei " #ra ", " #rb "\n" 17#define TRAP_OP(ra, rb) "1: tdnei " #ra ", " #rb "\n"
18#define DATA_TYPE long long 18#define DATA_TYPE long long
19#else 19#else
@@ -25,7 +25,7 @@
25 25
26struct bug_entry { 26struct bug_entry {
27 unsigned long bug_addr; 27 unsigned long bug_addr;
28 int line; 28 long line;
29 const char *file; 29 const char *file;
30 const char *function; 30 const char *function;
31}; 31};