diff options
author | Olaf Hering <olh@suse.de> | 2005-07-27 14:45:17 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-07-27 19:26:08 -0400 |
commit | 44456d37b59d8e541936ed26d8b6e08d27e88ac1 (patch) | |
tree | 11ca6fa29b8cfb56ecef2d1f4f9dc2d9d71d2a2f /arch | |
parent | 02b775696fee75a04041d8d94db26a9462216d24 (diff) |
[PATCH] turn many #if $undefined_string into #ifdef $undefined_string
turn many #if $undefined_string into #ifdef $undefined_string to fix some
warnings after -Wno-def was added to global CFLAGS
Signed-off-by: Olaf Hering <olh@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/ppc64/kernel/udbg.c | 2 | ||||
-rw-r--r-- | arch/um/drivers/cow.h | 4 | ||||
-rw-r--r-- | arch/um/kernel/skas/syscall_user.c | 4 | ||||
-rw-r--r-- | arch/um/os-Linux/elf_aux.c | 1 | ||||
-rw-r--r-- | arch/x86_64/ia32/ia32_aout.c | 6 | ||||
-rw-r--r-- | arch/x86_64/kernel/smpboot.c | 10 |
6 files changed, 14 insertions, 13 deletions
diff --git a/arch/ppc64/kernel/udbg.c b/arch/ppc64/kernel/udbg.c index d4ccd6f1ef47..c0da45540f0f 100644 --- a/arch/ppc64/kernel/udbg.c +++ b/arch/ppc64/kernel/udbg.c | |||
@@ -141,7 +141,7 @@ void udbg_init_scc(struct device_node *np) | |||
141 | 141 | ||
142 | #endif /* CONFIG_PPC_PMAC */ | 142 | #endif /* CONFIG_PPC_PMAC */ |
143 | 143 | ||
144 | #if CONFIG_PPC_PMAC | 144 | #ifdef CONFIG_PPC_PMAC |
145 | static void udbg_real_putc(unsigned char c) | 145 | static void udbg_real_putc(unsigned char c) |
146 | { | 146 | { |
147 | while ((real_readb(sccc) & SCC_TXRDY) == 0) | 147 | while ((real_readb(sccc) & SCC_TXRDY) == 0) |
diff --git a/arch/um/drivers/cow.h b/arch/um/drivers/cow.h index 4fcbe8b1b77e..4fcf3a8d13f4 100644 --- a/arch/um/drivers/cow.h +++ b/arch/um/drivers/cow.h | |||
@@ -3,10 +3,10 @@ | |||
3 | 3 | ||
4 | #include <asm/types.h> | 4 | #include <asm/types.h> |
5 | 5 | ||
6 | #if __BYTE_ORDER == __BIG_ENDIAN | 6 | #if defined(__BIG_ENDIAN) |
7 | # define ntohll(x) (x) | 7 | # define ntohll(x) (x) |
8 | # define htonll(x) (x) | 8 | # define htonll(x) (x) |
9 | #elif __BYTE_ORDER == __LITTLE_ENDIAN | 9 | #elif defined(__LITTLE_ENDIAN) |
10 | # define ntohll(x) bswap_64(x) | 10 | # define ntohll(x) bswap_64(x) |
11 | # define htonll(x) bswap_64(x) | 11 | # define htonll(x) bswap_64(x) |
12 | #else | 12 | #else |
diff --git a/arch/um/kernel/skas/syscall_user.c b/arch/um/kernel/skas/syscall_user.c index 2828e6e37721..6b0664970147 100644 --- a/arch/um/kernel/skas/syscall_user.c +++ b/arch/um/kernel/skas/syscall_user.c | |||
@@ -15,7 +15,7 @@ | |||
15 | void handle_syscall(union uml_pt_regs *regs) | 15 | void handle_syscall(union uml_pt_regs *regs) |
16 | { | 16 | { |
17 | long result; | 17 | long result; |
18 | #if UML_CONFIG_SYSCALL_DEBUG | 18 | #ifdef UML_CONFIG_SYSCALL_DEBUG |
19 | int index; | 19 | int index; |
20 | 20 | ||
21 | index = record_syscall_start(UPT_SYSCALL_NR(regs)); | 21 | index = record_syscall_start(UPT_SYSCALL_NR(regs)); |
@@ -27,7 +27,7 @@ void handle_syscall(union uml_pt_regs *regs) | |||
27 | REGS_SET_SYSCALL_RETURN(regs->skas.regs, result); | 27 | REGS_SET_SYSCALL_RETURN(regs->skas.regs, result); |
28 | 28 | ||
29 | syscall_trace(regs, 1); | 29 | syscall_trace(regs, 1); |
30 | #if UML_CONFIG_SYSCALL_DEBUG | 30 | #ifdef UML_CONFIG_SYSCALL_DEBUG |
31 | record_syscall_end(index, result); | 31 | record_syscall_end(index, result); |
32 | #endif | 32 | #endif |
33 | } | 33 | } |
diff --git a/arch/um/os-Linux/elf_aux.c b/arch/um/os-Linux/elf_aux.c index f0d6060e3e57..5423b1ca17c4 100644 --- a/arch/um/os-Linux/elf_aux.c +++ b/arch/um/os-Linux/elf_aux.c | |||
@@ -11,6 +11,7 @@ | |||
11 | #include <stddef.h> | 11 | #include <stddef.h> |
12 | #include "init.h" | 12 | #include "init.h" |
13 | #include "elf_user.h" | 13 | #include "elf_user.h" |
14 | #include <asm/elf.h> | ||
14 | 15 | ||
15 | #if ELF_CLASS == ELFCLASS32 | 16 | #if ELF_CLASS == ELFCLASS32 |
16 | typedef Elf32_auxv_t elf_auxv_t; | 17 | typedef Elf32_auxv_t elf_auxv_t; |
diff --git a/arch/x86_64/ia32/ia32_aout.c b/arch/x86_64/ia32/ia32_aout.c index c12edf5d97f0..3e6780fa0186 100644 --- a/arch/x86_64/ia32/ia32_aout.c +++ b/arch/x86_64/ia32/ia32_aout.c | |||
@@ -42,7 +42,7 @@ extern int ia32_setup_arg_pages(struct linux_binprm *bprm, | |||
42 | static int load_aout_binary(struct linux_binprm *, struct pt_regs * regs); | 42 | static int load_aout_binary(struct linux_binprm *, struct pt_regs * regs); |
43 | static int load_aout_library(struct file*); | 43 | static int load_aout_library(struct file*); |
44 | 44 | ||
45 | #if CORE_DUMP | 45 | #ifdef CORE_DUMP |
46 | static int aout_core_dump(long signr, struct pt_regs * regs, struct file *file); | 46 | static int aout_core_dump(long signr, struct pt_regs * regs, struct file *file); |
47 | 47 | ||
48 | /* | 48 | /* |
@@ -103,7 +103,7 @@ static struct linux_binfmt aout_format = { | |||
103 | .module = THIS_MODULE, | 103 | .module = THIS_MODULE, |
104 | .load_binary = load_aout_binary, | 104 | .load_binary = load_aout_binary, |
105 | .load_shlib = load_aout_library, | 105 | .load_shlib = load_aout_library, |
106 | #if CORE_DUMP | 106 | #ifdef CORE_DUMP |
107 | .core_dump = aout_core_dump, | 107 | .core_dump = aout_core_dump, |
108 | #endif | 108 | #endif |
109 | .min_coredump = PAGE_SIZE | 109 | .min_coredump = PAGE_SIZE |
@@ -120,7 +120,7 @@ static void set_brk(unsigned long start, unsigned long end) | |||
120 | up_write(¤t->mm->mmap_sem); | 120 | up_write(¤t->mm->mmap_sem); |
121 | } | 121 | } |
122 | 122 | ||
123 | #if CORE_DUMP | 123 | #ifdef CORE_DUMP |
124 | /* | 124 | /* |
125 | * These are the only things you should do on a core-file: use only these | 125 | * These are the only things you should do on a core-file: use only these |
126 | * macros to write out all the necessary info. | 126 | * macros to write out all the necessary info. |
diff --git a/arch/x86_64/kernel/smpboot.c b/arch/x86_64/kernel/smpboot.c index e66edfa1f3b9..e773a794ec45 100644 --- a/arch/x86_64/kernel/smpboot.c +++ b/arch/x86_64/kernel/smpboot.c | |||
@@ -285,7 +285,7 @@ static __cpuinit void sync_tsc(void) | |||
285 | int i, done = 0; | 285 | int i, done = 0; |
286 | long delta, adj, adjust_latency = 0; | 286 | long delta, adj, adjust_latency = 0; |
287 | unsigned long flags, rt, master_time_stamp, bound; | 287 | unsigned long flags, rt, master_time_stamp, bound; |
288 | #if DEBUG_TSC_SYNC | 288 | #ifdef DEBUG_TSC_SYNC |
289 | static struct syncdebug { | 289 | static struct syncdebug { |
290 | long rt; /* roundtrip time */ | 290 | long rt; /* roundtrip time */ |
291 | long master; /* master's timestamp */ | 291 | long master; /* master's timestamp */ |
@@ -321,7 +321,7 @@ static __cpuinit void sync_tsc(void) | |||
321 | rdtscll(t); | 321 | rdtscll(t); |
322 | wrmsrl(MSR_IA32_TSC, t + adj); | 322 | wrmsrl(MSR_IA32_TSC, t + adj); |
323 | } | 323 | } |
324 | #if DEBUG_TSC_SYNC | 324 | #ifdef DEBUG_TSC_SYNC |
325 | t[i].rt = rt; | 325 | t[i].rt = rt; |
326 | t[i].master = master_time_stamp; | 326 | t[i].master = master_time_stamp; |
327 | t[i].diff = delta; | 327 | t[i].diff = delta; |
@@ -331,7 +331,7 @@ static __cpuinit void sync_tsc(void) | |||
331 | } | 331 | } |
332 | spin_unlock_irqrestore(&tsc_sync_lock, flags); | 332 | spin_unlock_irqrestore(&tsc_sync_lock, flags); |
333 | 333 | ||
334 | #if DEBUG_TSC_SYNC | 334 | #ifdef DEBUG_TSC_SYNC |
335 | for (i = 0; i < NUM_ROUNDS; ++i) | 335 | for (i = 0; i < NUM_ROUNDS; ++i) |
336 | printk("rt=%5ld master=%5ld diff=%5ld adjlat=%5ld\n", | 336 | printk("rt=%5ld master=%5ld diff=%5ld adjlat=%5ld\n", |
337 | t[i].rt, t[i].master, t[i].diff, t[i].lat); | 337 | t[i].rt, t[i].master, t[i].diff, t[i].lat); |
@@ -537,7 +537,7 @@ void __cpuinit start_secondary(void) | |||
537 | extern volatile unsigned long init_rsp; | 537 | extern volatile unsigned long init_rsp; |
538 | extern void (*initial_code)(void); | 538 | extern void (*initial_code)(void); |
539 | 539 | ||
540 | #if APIC_DEBUG | 540 | #ifdef APIC_DEBUG |
541 | static void inquire_remote_apic(int apicid) | 541 | static void inquire_remote_apic(int apicid) |
542 | { | 542 | { |
543 | unsigned i, regs[] = { APIC_ID >> 4, APIC_LVR >> 4, APIC_SPIV >> 4 }; | 543 | unsigned i, regs[] = { APIC_ID >> 4, APIC_LVR >> 4, APIC_SPIV >> 4 }; |
@@ -841,7 +841,7 @@ do_rest: | |||
841 | else | 841 | else |
842 | /* trampoline code not run */ | 842 | /* trampoline code not run */ |
843 | printk("Not responding.\n"); | 843 | printk("Not responding.\n"); |
844 | #if APIC_DEBUG | 844 | #ifdef APIC_DEBUG |
845 | inquire_remote_apic(apicid); | 845 | inquire_remote_apic(apicid); |
846 | #endif | 846 | #endif |
847 | } | 847 | } |