diff options
Diffstat (limited to 'arch')
134 files changed, 1724 insertions, 1864 deletions
diff --git a/arch/arm/mach-pxa/generic.c b/arch/arm/mach-pxa/generic.c index 390524c4710f..b8cb79f899d5 100644 --- a/arch/arm/mach-pxa/generic.c +++ b/arch/arm/mach-pxa/generic.c | |||
@@ -36,6 +36,7 @@ | |||
36 | #include <asm/mach/map.h> | 36 | #include <asm/mach/map.h> |
37 | 37 | ||
38 | #include <asm/arch/pxa-regs.h> | 38 | #include <asm/arch/pxa-regs.h> |
39 | #include <asm/arch/gpio.h> | ||
39 | #include <asm/arch/udc.h> | 40 | #include <asm/arch/udc.h> |
40 | #include <asm/arch/pxafb.h> | 41 | #include <asm/arch/pxafb.h> |
41 | #include <asm/arch/mmc.h> | 42 | #include <asm/arch/mmc.h> |
@@ -106,13 +107,16 @@ unsigned long long sched_clock(void) | |||
106 | * Handy function to set GPIO alternate functions | 107 | * Handy function to set GPIO alternate functions |
107 | */ | 108 | */ |
108 | 109 | ||
109 | void pxa_gpio_mode(int gpio_mode) | 110 | int pxa_gpio_mode(int gpio_mode) |
110 | { | 111 | { |
111 | unsigned long flags; | 112 | unsigned long flags; |
112 | int gpio = gpio_mode & GPIO_MD_MASK_NR; | 113 | int gpio = gpio_mode & GPIO_MD_MASK_NR; |
113 | int fn = (gpio_mode & GPIO_MD_MASK_FN) >> 8; | 114 | int fn = (gpio_mode & GPIO_MD_MASK_FN) >> 8; |
114 | int gafr; | 115 | int gafr; |
115 | 116 | ||
117 | if (gpio > PXA_LAST_GPIO) | ||
118 | return -EINVAL; | ||
119 | |||
116 | local_irq_save(flags); | 120 | local_irq_save(flags); |
117 | if (gpio_mode & GPIO_DFLT_LOW) | 121 | if (gpio_mode & GPIO_DFLT_LOW) |
118 | GPCR(gpio) = GPIO_bit(gpio); | 122 | GPCR(gpio) = GPIO_bit(gpio); |
@@ -125,11 +129,33 @@ void pxa_gpio_mode(int gpio_mode) | |||
125 | gafr = GAFR(gpio) & ~(0x3 << (((gpio) & 0xf)*2)); | 129 | gafr = GAFR(gpio) & ~(0x3 << (((gpio) & 0xf)*2)); |
126 | GAFR(gpio) = gafr | (fn << (((gpio) & 0xf)*2)); | 130 | GAFR(gpio) = gafr | (fn << (((gpio) & 0xf)*2)); |
127 | local_irq_restore(flags); | 131 | local_irq_restore(flags); |
132 | |||
133 | return 0; | ||
128 | } | 134 | } |
129 | 135 | ||
130 | EXPORT_SYMBOL(pxa_gpio_mode); | 136 | EXPORT_SYMBOL(pxa_gpio_mode); |
131 | 137 | ||
132 | /* | 138 | /* |
139 | * Return GPIO level | ||
140 | */ | ||
141 | int pxa_gpio_get_value(unsigned gpio) | ||
142 | { | ||
143 | return __gpio_get_value(gpio); | ||
144 | } | ||
145 | |||
146 | EXPORT_SYMBOL(pxa_gpio_get_value); | ||
147 | |||
148 | /* | ||
149 | * Set output GPIO level | ||
150 | */ | ||
151 | void pxa_gpio_set_value(unsigned gpio, int value) | ||
152 | { | ||
153 | __gpio_set_value(gpio, value); | ||
154 | } | ||
155 | |||
156 | EXPORT_SYMBOL(pxa_gpio_set_value); | ||
157 | |||
158 | /* | ||
133 | * Routine to safely enable or disable a clock in the CKEN | 159 | * Routine to safely enable or disable a clock in the CKEN |
134 | */ | 160 | */ |
135 | void pxa_set_cken(int clock, int enable) | 161 | void pxa_set_cken(int clock, int enable) |
diff --git a/arch/arm/mach-sa1100/generic.c b/arch/arm/mach-sa1100/generic.c index e510295c2580..192a5a26cf2b 100644 --- a/arch/arm/mach-sa1100/generic.c +++ b/arch/arm/mach-sa1100/generic.c | |||
@@ -138,6 +138,36 @@ unsigned long long sched_clock(void) | |||
138 | return v; | 138 | return v; |
139 | } | 139 | } |
140 | 140 | ||
141 | int gpio_direction_input(unsigned gpio) | ||
142 | { | ||
143 | unsigned long flags; | ||
144 | |||
145 | if (gpio > GPIO_MAX) | ||
146 | return -EINVAL; | ||
147 | |||
148 | local_irq_save(flags); | ||
149 | GPDR &= ~GPIO_GPIO(gpio); | ||
150 | local_irq_restore(flags); | ||
151 | return 0; | ||
152 | } | ||
153 | |||
154 | EXPORT_SYMBOL(gpio_direction_input); | ||
155 | |||
156 | int gpio_direction_output(unsigned gpio) | ||
157 | { | ||
158 | unsigned long flags; | ||
159 | |||
160 | if (gpio > GPIO_MAX) | ||
161 | return -EINVAL; | ||
162 | |||
163 | local_irq_save(flags); | ||
164 | GPDR |= GPIO_GPIO(gpio); | ||
165 | local_irq_restore(flags); | ||
166 | return 0; | ||
167 | } | ||
168 | |||
169 | EXPORT_SYMBOL(gpio_direction_output); | ||
170 | |||
141 | /* | 171 | /* |
142 | * Default power-off for SA1100 | 172 | * Default power-off for SA1100 |
143 | */ | 173 | */ |
diff --git a/arch/i386/Makefile b/arch/i386/Makefile index f7ac1aea1d8a..bd28f9f9b4b7 100644 --- a/arch/i386/Makefile +++ b/arch/i386/Makefile | |||
@@ -31,7 +31,7 @@ LDFLAGS_vmlinux := --emit-relocs | |||
31 | endif | 31 | endif |
32 | CHECKFLAGS += -D__i386__ | 32 | CHECKFLAGS += -D__i386__ |
33 | 33 | ||
34 | CFLAGS += -pipe -msoft-float -mregparm=3 | 34 | CFLAGS += -pipe -msoft-float -mregparm=3 -freg-struct-return |
35 | 35 | ||
36 | # prevent gcc from keeping the stack 16 byte aligned | 36 | # prevent gcc from keeping the stack 16 byte aligned |
37 | CFLAGS += $(call cc-option,-mpreferred-stack-boundary=2) | 37 | CFLAGS += $(call cc-option,-mpreferred-stack-boundary=2) |
diff --git a/arch/i386/kernel/apic.c b/arch/i386/kernel/apic.c index 9655c233e6f1..7a2c9cbdb511 100644 --- a/arch/i386/kernel/apic.c +++ b/arch/i386/kernel/apic.c | |||
@@ -38,7 +38,6 @@ | |||
38 | #include <asm/hpet.h> | 38 | #include <asm/hpet.h> |
39 | #include <asm/i8253.h> | 39 | #include <asm/i8253.h> |
40 | #include <asm/nmi.h> | 40 | #include <asm/nmi.h> |
41 | #include <asm/idle.h> | ||
42 | 41 | ||
43 | #include <mach_apic.h> | 42 | #include <mach_apic.h> |
44 | #include <mach_apicdef.h> | 43 | #include <mach_apicdef.h> |
@@ -561,7 +560,6 @@ void fastcall smp_apic_timer_interrupt(struct pt_regs *regs) | |||
561 | * Besides, if we don't timer interrupts ignore the global | 560 | * Besides, if we don't timer interrupts ignore the global |
562 | * interrupt lock, which is the WrongThing (tm) to do. | 561 | * interrupt lock, which is the WrongThing (tm) to do. |
563 | */ | 562 | */ |
564 | exit_idle(); | ||
565 | irq_enter(); | 563 | irq_enter(); |
566 | local_apic_timer_interrupt(); | 564 | local_apic_timer_interrupt(); |
567 | irq_exit(); | 565 | irq_exit(); |
@@ -1221,7 +1219,6 @@ void smp_spurious_interrupt(struct pt_regs *regs) | |||
1221 | { | 1219 | { |
1222 | unsigned long v; | 1220 | unsigned long v; |
1223 | 1221 | ||
1224 | exit_idle(); | ||
1225 | irq_enter(); | 1222 | irq_enter(); |
1226 | /* | 1223 | /* |
1227 | * Check if this really is a spurious interrupt and ACK it | 1224 | * Check if this really is a spurious interrupt and ACK it |
@@ -1245,7 +1242,6 @@ void smp_error_interrupt(struct pt_regs *regs) | |||
1245 | { | 1242 | { |
1246 | unsigned long v, v1; | 1243 | unsigned long v, v1; |
1247 | 1244 | ||
1248 | exit_idle(); | ||
1249 | irq_enter(); | 1245 | irq_enter(); |
1250 | /* First tickle the hardware, only then report what went on. -- REW */ | 1246 | /* First tickle the hardware, only then report what went on. -- REW */ |
1251 | v = apic_read(APIC_ESR); | 1247 | v = apic_read(APIC_ESR); |
diff --git a/arch/i386/kernel/cpu/mcheck/p4.c b/arch/i386/kernel/cpu/mcheck/p4.c index 8359c19d3a23..504434a46011 100644 --- a/arch/i386/kernel/cpu/mcheck/p4.c +++ b/arch/i386/kernel/cpu/mcheck/p4.c | |||
@@ -12,7 +12,6 @@ | |||
12 | #include <asm/system.h> | 12 | #include <asm/system.h> |
13 | #include <asm/msr.h> | 13 | #include <asm/msr.h> |
14 | #include <asm/apic.h> | 14 | #include <asm/apic.h> |
15 | #include <asm/idle.h> | ||
16 | 15 | ||
17 | #include <asm/therm_throt.h> | 16 | #include <asm/therm_throt.h> |
18 | 17 | ||
@@ -60,7 +59,6 @@ static void (*vendor_thermal_interrupt)(struct pt_regs *regs) = unexpected_therm | |||
60 | 59 | ||
61 | fastcall void smp_thermal_interrupt(struct pt_regs *regs) | 60 | fastcall void smp_thermal_interrupt(struct pt_regs *regs) |
62 | { | 61 | { |
63 | exit_idle(); | ||
64 | irq_enter(); | 62 | irq_enter(); |
65 | vendor_thermal_interrupt(regs); | 63 | vendor_thermal_interrupt(regs); |
66 | irq_exit(); | 64 | irq_exit(); |
diff --git a/arch/i386/kernel/io_apic.c b/arch/i386/kernel/io_apic.c index 4ccebd454e25..6fec4dab70bb 100644 --- a/arch/i386/kernel/io_apic.c +++ b/arch/i386/kernel/io_apic.c | |||
@@ -343,7 +343,7 @@ static void set_ioapic_affinity_irq(unsigned int irq, cpumask_t cpumask) | |||
343 | break; | 343 | break; |
344 | entry = irq_2_pin + entry->next; | 344 | entry = irq_2_pin + entry->next; |
345 | } | 345 | } |
346 | set_native_irq_info(irq, cpumask); | 346 | irq_desc[irq].affinity = cpumask; |
347 | spin_unlock_irqrestore(&ioapic_lock, flags); | 347 | spin_unlock_irqrestore(&ioapic_lock, flags); |
348 | } | 348 | } |
349 | 349 | ||
@@ -1354,7 +1354,7 @@ static void __init setup_IO_APIC_irqs(void) | |||
1354 | } | 1354 | } |
1355 | spin_lock_irqsave(&ioapic_lock, flags); | 1355 | spin_lock_irqsave(&ioapic_lock, flags); |
1356 | __ioapic_write_entry(apic, pin, entry); | 1356 | __ioapic_write_entry(apic, pin, entry); |
1357 | set_native_irq_info(irq, TARGET_CPUS); | 1357 | irq_desc[irq].affinity = TARGET_CPUS; |
1358 | spin_unlock_irqrestore(&ioapic_lock, flags); | 1358 | spin_unlock_irqrestore(&ioapic_lock, flags); |
1359 | } | 1359 | } |
1360 | } | 1360 | } |
@@ -2585,7 +2585,7 @@ static void set_msi_irq_affinity(unsigned int irq, cpumask_t mask) | |||
2585 | msg.address_lo |= MSI_ADDR_DEST_ID(dest); | 2585 | msg.address_lo |= MSI_ADDR_DEST_ID(dest); |
2586 | 2586 | ||
2587 | write_msi_msg(irq, &msg); | 2587 | write_msi_msg(irq, &msg); |
2588 | set_native_irq_info(irq, mask); | 2588 | irq_desc[irq].affinity = mask; |
2589 | } | 2589 | } |
2590 | #endif /* CONFIG_SMP */ | 2590 | #endif /* CONFIG_SMP */ |
2591 | 2591 | ||
@@ -2669,7 +2669,7 @@ static void set_ht_irq_affinity(unsigned int irq, cpumask_t mask) | |||
2669 | dest = cpu_mask_to_apicid(mask); | 2669 | dest = cpu_mask_to_apicid(mask); |
2670 | 2670 | ||
2671 | target_ht_irq(irq, dest); | 2671 | target_ht_irq(irq, dest); |
2672 | set_native_irq_info(irq, mask); | 2672 | irq_desc[irq].affinity = mask; |
2673 | } | 2673 | } |
2674 | #endif | 2674 | #endif |
2675 | 2675 | ||
@@ -2875,7 +2875,7 @@ int io_apic_set_pci_routing (int ioapic, int pin, int irq, int edge_level, int a | |||
2875 | 2875 | ||
2876 | spin_lock_irqsave(&ioapic_lock, flags); | 2876 | spin_lock_irqsave(&ioapic_lock, flags); |
2877 | __ioapic_write_entry(ioapic, pin, entry); | 2877 | __ioapic_write_entry(ioapic, pin, entry); |
2878 | set_native_irq_info(irq, TARGET_CPUS); | 2878 | irq_desc[irq].affinity = TARGET_CPUS; |
2879 | spin_unlock_irqrestore(&ioapic_lock, flags); | 2879 | spin_unlock_irqrestore(&ioapic_lock, flags); |
2880 | 2880 | ||
2881 | return 0; | 2881 | return 0; |
diff --git a/arch/i386/kernel/irq.c b/arch/i386/kernel/irq.c index 0f2ca590bf23..8db8d514c9c0 100644 --- a/arch/i386/kernel/irq.c +++ b/arch/i386/kernel/irq.c | |||
@@ -18,8 +18,6 @@ | |||
18 | #include <linux/cpu.h> | 18 | #include <linux/cpu.h> |
19 | #include <linux/delay.h> | 19 | #include <linux/delay.h> |
20 | 20 | ||
21 | #include <asm/idle.h> | ||
22 | |||
23 | #include <asm/apic.h> | 21 | #include <asm/apic.h> |
24 | #include <asm/uaccess.h> | 22 | #include <asm/uaccess.h> |
25 | 23 | ||
@@ -77,7 +75,6 @@ fastcall unsigned int do_IRQ(struct pt_regs *regs) | |||
77 | union irq_ctx *curctx, *irqctx; | 75 | union irq_ctx *curctx, *irqctx; |
78 | u32 *isp; | 76 | u32 *isp; |
79 | #endif | 77 | #endif |
80 | exit_idle(); | ||
81 | 78 | ||
82 | if (unlikely((unsigned)irq >= NR_IRQS)) { | 79 | if (unlikely((unsigned)irq >= NR_IRQS)) { |
83 | printk(KERN_EMERG "%s: cannot handle IRQ %d\n", | 80 | printk(KERN_EMERG "%s: cannot handle IRQ %d\n", |
diff --git a/arch/i386/kernel/process.c b/arch/i386/kernel/process.c index bea304d48cdb..393a67d5d943 100644 --- a/arch/i386/kernel/process.c +++ b/arch/i386/kernel/process.c | |||
@@ -49,7 +49,6 @@ | |||
49 | #include <asm/i387.h> | 49 | #include <asm/i387.h> |
50 | #include <asm/desc.h> | 50 | #include <asm/desc.h> |
51 | #include <asm/vm86.h> | 51 | #include <asm/vm86.h> |
52 | #include <asm/idle.h> | ||
53 | #ifdef CONFIG_MATH_EMULATION | 52 | #ifdef CONFIG_MATH_EMULATION |
54 | #include <asm/math_emu.h> | 53 | #include <asm/math_emu.h> |
55 | #endif | 54 | #endif |
@@ -82,42 +81,6 @@ void (*pm_idle)(void); | |||
82 | EXPORT_SYMBOL(pm_idle); | 81 | EXPORT_SYMBOL(pm_idle); |
83 | static DEFINE_PER_CPU(unsigned int, cpu_idle_state); | 82 | static DEFINE_PER_CPU(unsigned int, cpu_idle_state); |
84 | 83 | ||
85 | static ATOMIC_NOTIFIER_HEAD(idle_notifier); | ||
86 | |||
87 | void idle_notifier_register(struct notifier_block *n) | ||
88 | { | ||
89 | atomic_notifier_chain_register(&idle_notifier, n); | ||
90 | } | ||
91 | |||
92 | void idle_notifier_unregister(struct notifier_block *n) | ||
93 | { | ||
94 | atomic_notifier_chain_unregister(&idle_notifier, n); | ||
95 | } | ||
96 | |||
97 | static DEFINE_PER_CPU(volatile unsigned long, idle_state); | ||
98 | |||
99 | void enter_idle(void) | ||
100 | { | ||
101 | /* needs to be atomic w.r.t. interrupts, not against other CPUs */ | ||
102 | __set_bit(0, &__get_cpu_var(idle_state)); | ||
103 | atomic_notifier_call_chain(&idle_notifier, IDLE_START, NULL); | ||
104 | } | ||
105 | |||
106 | static void __exit_idle(void) | ||
107 | { | ||
108 | /* needs to be atomic w.r.t. interrupts, not against other CPUs */ | ||
109 | if (__test_and_clear_bit(0, &__get_cpu_var(idle_state)) == 0) | ||
110 | return; | ||
111 | atomic_notifier_call_chain(&idle_notifier, IDLE_END, NULL); | ||
112 | } | ||
113 | |||
114 | void exit_idle(void) | ||
115 | { | ||
116 | if (current->pid) | ||
117 | return; | ||
118 | __exit_idle(); | ||
119 | } | ||
120 | |||
121 | void disable_hlt(void) | 84 | void disable_hlt(void) |
122 | { | 85 | { |
123 | hlt_counter++; | 86 | hlt_counter++; |
@@ -168,7 +131,6 @@ EXPORT_SYMBOL(default_idle); | |||
168 | */ | 131 | */ |
169 | static void poll_idle (void) | 132 | static void poll_idle (void) |
170 | { | 133 | { |
171 | local_irq_enable(); | ||
172 | cpu_relax(); | 134 | cpu_relax(); |
173 | } | 135 | } |
174 | 136 | ||
@@ -229,16 +191,7 @@ void cpu_idle(void) | |||
229 | play_dead(); | 191 | play_dead(); |
230 | 192 | ||
231 | __get_cpu_var(irq_stat).idle_timestamp = jiffies; | 193 | __get_cpu_var(irq_stat).idle_timestamp = jiffies; |
232 | |||
233 | /* | ||
234 | * Idle routines should keep interrupts disabled | ||
235 | * from here on, until they go to idle. | ||
236 | * Otherwise, idle callbacks can misfire. | ||
237 | */ | ||
238 | local_irq_disable(); | ||
239 | enter_idle(); | ||
240 | idle(); | 194 | idle(); |
241 | __exit_idle(); | ||
242 | } | 195 | } |
243 | tick_nohz_restart_sched_tick(); | 196 | tick_nohz_restart_sched_tick(); |
244 | preempt_enable_no_resched(); | 197 | preempt_enable_no_resched(); |
@@ -293,11 +246,7 @@ void mwait_idle_with_hints(unsigned long eax, unsigned long ecx) | |||
293 | __monitor((void *)¤t_thread_info()->flags, 0, 0); | 246 | __monitor((void *)¤t_thread_info()->flags, 0, 0); |
294 | smp_mb(); | 247 | smp_mb(); |
295 | if (!need_resched()) | 248 | if (!need_resched()) |
296 | __sti_mwait(eax, ecx); | 249 | __mwait(eax, ecx); |
297 | else | ||
298 | local_irq_enable(); | ||
299 | } else { | ||
300 | local_irq_enable(); | ||
301 | } | 250 | } |
302 | } | 251 | } |
303 | 252 | ||
diff --git a/arch/i386/kernel/smp.c b/arch/i386/kernel/smp.c index 9bd9637ae692..0e8977871b1f 100644 --- a/arch/i386/kernel/smp.c +++ b/arch/i386/kernel/smp.c | |||
@@ -23,7 +23,6 @@ | |||
23 | 23 | ||
24 | #include <asm/mtrr.h> | 24 | #include <asm/mtrr.h> |
25 | #include <asm/tlbflush.h> | 25 | #include <asm/tlbflush.h> |
26 | #include <asm/idle.h> | ||
27 | #include <mach_apic.h> | 26 | #include <mach_apic.h> |
28 | 27 | ||
29 | /* | 28 | /* |
@@ -624,7 +623,6 @@ fastcall void smp_call_function_interrupt(struct pt_regs *regs) | |||
624 | /* | 623 | /* |
625 | * At this point the info structure may be out of scope unless wait==1 | 624 | * At this point the info structure may be out of scope unless wait==1 |
626 | */ | 625 | */ |
627 | exit_idle(); | ||
628 | irq_enter(); | 626 | irq_enter(); |
629 | (*func)(info); | 627 | (*func)(info); |
630 | irq_exit(); | 628 | irq_exit(); |
diff --git a/arch/ia64/kernel/msi_ia64.c b/arch/ia64/kernel/msi_ia64.c index 0d05450c91c4..e7220900ea14 100644 --- a/arch/ia64/kernel/msi_ia64.c +++ b/arch/ia64/kernel/msi_ia64.c | |||
@@ -60,7 +60,7 @@ static void ia64_set_msi_irq_affinity(unsigned int irq, cpumask_t cpu_mask) | |||
60 | msg.address_lo = addr; | 60 | msg.address_lo = addr; |
61 | 61 | ||
62 | write_msi_msg(irq, &msg); | 62 | write_msi_msg(irq, &msg); |
63 | set_native_irq_info(irq, cpu_mask); | 63 | irq_desc[irq].affinity = cpu_mask; |
64 | } | 64 | } |
65 | #endif /* CONFIG_SMP */ | 65 | #endif /* CONFIG_SMP */ |
66 | 66 | ||
diff --git a/arch/ia64/sn/kernel/msi_sn.c b/arch/ia64/sn/kernel/msi_sn.c index ea3dc38d73fd..49873aa4a37d 100644 --- a/arch/ia64/sn/kernel/msi_sn.c +++ b/arch/ia64/sn/kernel/msi_sn.c | |||
@@ -204,7 +204,7 @@ static void sn_set_msi_irq_affinity(unsigned int irq, cpumask_t cpu_mask) | |||
204 | msg.address_lo = (u32)(bus_addr & 0x00000000ffffffff); | 204 | msg.address_lo = (u32)(bus_addr & 0x00000000ffffffff); |
205 | 205 | ||
206 | write_msi_msg(irq, &msg); | 206 | write_msi_msg(irq, &msg); |
207 | set_native_irq_info(irq, cpu_mask); | 207 | irq_desc[irq].affinity = cpu_mask; |
208 | } | 208 | } |
209 | #endif /* CONFIG_SMP */ | 209 | #endif /* CONFIG_SMP */ |
210 | 210 | ||
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index c6f74f1c6398..58e97886d771 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig | |||
@@ -274,6 +274,7 @@ config MIPS_ATLAS | |||
274 | select SYS_SUPPORTS_BIG_ENDIAN | 274 | select SYS_SUPPORTS_BIG_ENDIAN |
275 | select SYS_SUPPORTS_LITTLE_ENDIAN | 275 | select SYS_SUPPORTS_LITTLE_ENDIAN |
276 | select SYS_SUPPORTS_MULTITHREADING if EXPERIMENTAL | 276 | select SYS_SUPPORTS_MULTITHREADING if EXPERIMENTAL |
277 | select SYS_SUPPORTS_SMARTMIPS | ||
277 | select GENERIC_HARDIRQS_NO__DO_IRQ | 278 | select GENERIC_HARDIRQS_NO__DO_IRQ |
278 | help | 279 | help |
279 | This enables support for the MIPS Technologies Atlas evaluation | 280 | This enables support for the MIPS Technologies Atlas evaluation |
@@ -305,6 +306,7 @@ config MIPS_MALTA | |||
305 | select SYS_SUPPORTS_BIG_ENDIAN | 306 | select SYS_SUPPORTS_BIG_ENDIAN |
306 | select SYS_SUPPORTS_LITTLE_ENDIAN | 307 | select SYS_SUPPORTS_LITTLE_ENDIAN |
307 | select SYS_SUPPORTS_MULTITHREADING | 308 | select SYS_SUPPORTS_MULTITHREADING |
309 | select SYS_SUPPORTS_SMARTMIPS | ||
308 | help | 310 | help |
309 | This enables support for the MIPS Technologies Malta evaluation | 311 | This enables support for the MIPS Technologies Malta evaluation |
310 | board. | 312 | board. |
@@ -322,6 +324,7 @@ config MIPS_SEAD | |||
322 | select SYS_SUPPORTS_64BIT_KERNEL if EXPERIMENTAL | 324 | select SYS_SUPPORTS_64BIT_KERNEL if EXPERIMENTAL |
323 | select SYS_SUPPORTS_BIG_ENDIAN | 325 | select SYS_SUPPORTS_BIG_ENDIAN |
324 | select SYS_SUPPORTS_LITTLE_ENDIAN | 326 | select SYS_SUPPORTS_LITTLE_ENDIAN |
327 | select SYS_SUPPORTS_SMARTMIPS | ||
325 | help | 328 | help |
326 | This enables support for the MIPS Technologies SEAD evaluation | 329 | This enables support for the MIPS Technologies SEAD evaluation |
327 | board. | 330 | board. |
@@ -1641,6 +1644,18 @@ config 64BIT_PHYS_ADDR | |||
1641 | config CPU_HAS_LLSC | 1644 | config CPU_HAS_LLSC |
1642 | bool | 1645 | bool |
1643 | 1646 | ||
1647 | config CPU_HAS_SMARTMIPS | ||
1648 | depends on SYS_SUPPORTS_SMARTMIPS | ||
1649 | bool "Support for the SmartMIPS ASE" | ||
1650 | help | ||
1651 | SmartMIPS is a extension of the MIPS32 architecture aimed at | ||
1652 | increased security at both hardware and software level for | ||
1653 | smartcards. Enabling this option will allow proper use of the | ||
1654 | SmartMIPS instructions by Linux applications. However a kernel with | ||
1655 | this option will not work on a MIPS core without SmartMIPS core. If | ||
1656 | you don't know you probably don't have SmartMIPS and should say N | ||
1657 | here. | ||
1658 | |||
1644 | config CPU_HAS_WB | 1659 | config CPU_HAS_WB |
1645 | bool | 1660 | bool |
1646 | 1661 | ||
@@ -1704,6 +1719,9 @@ config CPU_SUPPORTS_HIGHMEM | |||
1704 | config SYS_SUPPORTS_HIGHMEM | 1719 | config SYS_SUPPORTS_HIGHMEM |
1705 | bool | 1720 | bool |
1706 | 1721 | ||
1722 | config SYS_SUPPORTS_SMARTMIPS | ||
1723 | bool | ||
1724 | |||
1707 | config ARCH_FLATMEM_ENABLE | 1725 | config ARCH_FLATMEM_ENABLE |
1708 | def_bool y | 1726 | def_bool y |
1709 | depends on !NUMA | 1727 | depends on !NUMA |
diff --git a/arch/mips/Makefile b/arch/mips/Makefile index c68b5d3e5d18..92bca6ad6ab1 100644 --- a/arch/mips/Makefile +++ b/arch/mips/Makefile | |||
@@ -103,6 +103,8 @@ predef-le += -DMIPSEL -D_MIPSEL -D__MIPSEL -D__MIPSEL__ | |||
103 | cflags-$(CONFIG_CPU_BIG_ENDIAN) += $(shell $(CC) -dumpmachine |grep -q 'mips.*el-.*' && echo -EB $(undef-all) $(predef-be)) | 103 | cflags-$(CONFIG_CPU_BIG_ENDIAN) += $(shell $(CC) -dumpmachine |grep -q 'mips.*el-.*' && echo -EB $(undef-all) $(predef-be)) |
104 | cflags-$(CONFIG_CPU_LITTLE_ENDIAN) += $(shell $(CC) -dumpmachine |grep -q 'mips.*el-.*' || echo -EL $(undef-all) $(predef-le)) | 104 | cflags-$(CONFIG_CPU_LITTLE_ENDIAN) += $(shell $(CC) -dumpmachine |grep -q 'mips.*el-.*' || echo -EL $(undef-all) $(predef-le)) |
105 | 105 | ||
106 | cflags-$(CONFIG_CPU_HAS_SMARTMIPS) += $(call cc-option,-msmartmips) | ||
107 | |||
106 | cflags-$(CONFIG_SB1XXX_CORELIS) += $(call cc-option,-mno-sched-prolog) \ | 108 | cflags-$(CONFIG_SB1XXX_CORELIS) += $(call cc-option,-mno-sched-prolog) \ |
107 | -fno-omit-frame-pointer | 109 | -fno-omit-frame-pointer |
108 | 110 | ||
diff --git a/arch/mips/cobalt/mtd.c b/arch/mips/cobalt/mtd.c index 01d8ec77fe9c..2b088ef3839a 100644 --- a/arch/mips/cobalt/mtd.c +++ b/arch/mips/cobalt/mtd.c | |||
@@ -24,7 +24,7 @@ | |||
24 | 24 | ||
25 | static struct mtd_partition cobalt_mtd_partitions[] = { | 25 | static struct mtd_partition cobalt_mtd_partitions[] = { |
26 | { | 26 | { |
27 | .name = "Colo", | 27 | .name = "firmware", |
28 | .offset = 0x0, | 28 | .offset = 0x0, |
29 | .size = 0x80000, | 29 | .size = 0x80000, |
30 | }, | 30 | }, |
diff --git a/arch/mips/configs/atlas_defconfig b/arch/mips/configs/atlas_defconfig index 45874d1038d3..458894933a4c 100644 --- a/arch/mips/configs/atlas_defconfig +++ b/arch/mips/configs/atlas_defconfig | |||
@@ -139,10 +139,12 @@ CONFIG_MIPS_MT_DISABLED=y | |||
139 | CONFIG_SYS_SUPPORTS_MULTITHREADING=y | 139 | CONFIG_SYS_SUPPORTS_MULTITHREADING=y |
140 | # CONFIG_64BIT_PHYS_ADDR is not set | 140 | # CONFIG_64BIT_PHYS_ADDR is not set |
141 | CONFIG_CPU_HAS_LLSC=y | 141 | CONFIG_CPU_HAS_LLSC=y |
142 | # CONFIG_CPU_HAS_SMARTMIPS is not set | ||
142 | CONFIG_CPU_HAS_SYNC=y | 143 | CONFIG_CPU_HAS_SYNC=y |
143 | CONFIG_GENERIC_HARDIRQS=y | 144 | CONFIG_GENERIC_HARDIRQS=y |
144 | CONFIG_GENERIC_IRQ_PROBE=y | 145 | CONFIG_GENERIC_IRQ_PROBE=y |
145 | CONFIG_CPU_SUPPORTS_HIGHMEM=y | 146 | CONFIG_CPU_SUPPORTS_HIGHMEM=y |
147 | CONFIG_SYS_SUPPORTS_SMARTMIPS=y | ||
146 | CONFIG_ARCH_FLATMEM_ENABLE=y | 148 | CONFIG_ARCH_FLATMEM_ENABLE=y |
147 | CONFIG_SELECT_MEMORY_MODEL=y | 149 | CONFIG_SELECT_MEMORY_MODEL=y |
148 | CONFIG_FLATMEM_MANUAL=y | 150 | CONFIG_FLATMEM_MANUAL=y |
diff --git a/arch/mips/configs/bigsur_defconfig b/arch/mips/configs/bigsur_defconfig index b4cdd3e7cdfc..aa05e294ea62 100644 --- a/arch/mips/configs/bigsur_defconfig +++ b/arch/mips/configs/bigsur_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:35 2007 | 4 | # Tue Feb 20 21:47:22 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -417,6 +417,7 @@ CONFIG_PREVENT_FIRMWARE_BUILD=y | |||
417 | # | 417 | # |
418 | # Plug and Play support | 418 | # Plug and Play support |
419 | # | 419 | # |
420 | # CONFIG_PNPACPI is not set | ||
420 | 421 | ||
421 | # | 422 | # |
422 | # Block devices | 423 | # Block devices |
@@ -589,6 +590,7 @@ CONFIG_NET_SB1250_MAC=y | |||
589 | # CONFIG_TIGON3 is not set | 590 | # CONFIG_TIGON3 is not set |
590 | # CONFIG_BNX2 is not set | 591 | # CONFIG_BNX2 is not set |
591 | # CONFIG_QLA3XXX is not set | 592 | # CONFIG_QLA3XXX is not set |
593 | # CONFIG_ATL1 is not set | ||
592 | 594 | ||
593 | # | 595 | # |
594 | # Ethernet (10000 Mbit) | 596 | # Ethernet (10000 Mbit) |
@@ -1025,7 +1027,6 @@ CONFIG_FORCED_INLINING=y | |||
1025 | CONFIG_CROSSCOMPILE=y | 1027 | CONFIG_CROSSCOMPILE=y |
1026 | CONFIG_CMDLINE="" | 1028 | CONFIG_CMDLINE="" |
1027 | # CONFIG_DEBUG_STACK_USAGE is not set | 1029 | # CONFIG_DEBUG_STACK_USAGE is not set |
1028 | # CONFIG_KGDB is not set | ||
1029 | # CONFIG_SB1XXX_CORELIS is not set | 1030 | # CONFIG_SB1XXX_CORELIS is not set |
1030 | # CONFIG_RUNTIME_DEBUG is not set | 1031 | # CONFIG_RUNTIME_DEBUG is not set |
1031 | 1032 | ||
diff --git a/arch/mips/configs/capcella_defconfig b/arch/mips/configs/capcella_defconfig index b05469e0bcd0..b2594fa556f3 100644 --- a/arch/mips/configs/capcella_defconfig +++ b/arch/mips/configs/capcella_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:36 2007 | 4 | # Tue Feb 20 21:47:22 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -388,6 +388,7 @@ CONFIG_CONNECTOR=m | |||
388 | # | 388 | # |
389 | # Plug and Play support | 389 | # Plug and Play support |
390 | # | 390 | # |
391 | # CONFIG_PNPACPI is not set | ||
391 | 392 | ||
392 | # | 393 | # |
393 | # Block devices | 394 | # Block devices |
diff --git a/arch/mips/configs/cobalt_defconfig b/arch/mips/configs/cobalt_defconfig index f88c40fc9948..9090a7aba6c1 100644 --- a/arch/mips/configs/cobalt_defconfig +++ b/arch/mips/configs/cobalt_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Mon Feb 19 14:51:58 2007 | 4 | # Tue Feb 20 21:47:24 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -425,7 +425,7 @@ CONFIG_MTD_CFI_UTIL=y | |||
425 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set | 425 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set |
426 | CONFIG_MTD_PHYSMAP=y | 426 | CONFIG_MTD_PHYSMAP=y |
427 | CONFIG_MTD_PHYSMAP_START=0x0 | 427 | CONFIG_MTD_PHYSMAP_START=0x0 |
428 | CONFIG_MTD_PHYSMAP_LEN=0 | 428 | CONFIG_MTD_PHYSMAP_LEN=0x0 |
429 | CONFIG_MTD_PHYSMAP_BANKWIDTH=0 | 429 | CONFIG_MTD_PHYSMAP_BANKWIDTH=0 |
430 | # CONFIG_MTD_PLATRAM is not set | 430 | # CONFIG_MTD_PLATRAM is not set |
431 | 431 | ||
@@ -449,7 +449,6 @@ CONFIG_MTD_PHYSMAP_BANKWIDTH=0 | |||
449 | # NAND Flash Device Drivers | 449 | # NAND Flash Device Drivers |
450 | # | 450 | # |
451 | # CONFIG_MTD_NAND is not set | 451 | # CONFIG_MTD_NAND is not set |
452 | # CONFIG_MTD_NAND_CAFE is not set | ||
453 | 452 | ||
454 | # | 453 | # |
455 | # OneNAND Flash Device Drivers | 454 | # OneNAND Flash Device Drivers |
@@ -464,6 +463,7 @@ CONFIG_MTD_PHYSMAP_BANKWIDTH=0 | |||
464 | # | 463 | # |
465 | # Plug and Play support | 464 | # Plug and Play support |
466 | # | 465 | # |
466 | # CONFIG_PNPACPI is not set | ||
467 | 467 | ||
468 | # | 468 | # |
469 | # Block devices | 469 | # Block devices |
@@ -658,6 +658,7 @@ CONFIG_TULIP=y | |||
658 | # CONFIG_TIGON3 is not set | 658 | # CONFIG_TIGON3 is not set |
659 | # CONFIG_BNX2 is not set | 659 | # CONFIG_BNX2 is not set |
660 | CONFIG_QLA3XXX=y | 660 | CONFIG_QLA3XXX=y |
661 | # CONFIG_ATL1 is not set | ||
661 | 662 | ||
662 | # | 663 | # |
663 | # Ethernet (10000 Mbit) | 664 | # Ethernet (10000 Mbit) |
diff --git a/arch/mips/configs/db1000_defconfig b/arch/mips/configs/db1000_defconfig index 1db19f1bfd4d..4cb8cf4255a2 100644 --- a/arch/mips/configs/db1000_defconfig +++ b/arch/mips/configs/db1000_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:39 2007 | 4 | # Tue Feb 20 21:47:24 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -548,6 +548,7 @@ CONFIG_MTD_ALCHEMY=y | |||
548 | # | 548 | # |
549 | # Plug and Play support | 549 | # Plug and Play support |
550 | # | 550 | # |
551 | # CONFIG_PNPACPI is not set | ||
551 | 552 | ||
552 | # | 553 | # |
553 | # Block devices | 554 | # Block devices |
@@ -1103,6 +1104,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1103 | CONFIG_LOG_BUF_SHIFT=14 | 1104 | CONFIG_LOG_BUF_SHIFT=14 |
1104 | CONFIG_CROSSCOMPILE=y | 1105 | CONFIG_CROSSCOMPILE=y |
1105 | CONFIG_CMDLINE="" | 1106 | CONFIG_CMDLINE="" |
1107 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1106 | 1108 | ||
1107 | # | 1109 | # |
1108 | # Security options | 1110 | # Security options |
diff --git a/arch/mips/configs/db1100_defconfig b/arch/mips/configs/db1100_defconfig index 529e6ebe2a8d..d86dedf27fc4 100644 --- a/arch/mips/configs/db1100_defconfig +++ b/arch/mips/configs/db1100_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:39 2007 | 4 | # Tue Feb 20 21:47:24 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -537,6 +537,7 @@ CONFIG_MTD_ALCHEMY=y | |||
537 | # | 537 | # |
538 | # Plug and Play support | 538 | # Plug and Play support |
539 | # | 539 | # |
540 | # CONFIG_PNPACPI is not set | ||
540 | 541 | ||
541 | # | 542 | # |
542 | # Block devices | 543 | # Block devices |
@@ -1103,6 +1104,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1103 | CONFIG_LOG_BUF_SHIFT=14 | 1104 | CONFIG_LOG_BUF_SHIFT=14 |
1104 | CONFIG_CROSSCOMPILE=y | 1105 | CONFIG_CROSSCOMPILE=y |
1105 | CONFIG_CMDLINE="" | 1106 | CONFIG_CMDLINE="" |
1107 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1106 | 1108 | ||
1107 | # | 1109 | # |
1108 | # Security options | 1110 | # Security options |
diff --git a/arch/mips/configs/db1200_defconfig b/arch/mips/configs/db1200_defconfig index 9e86dcd3c31e..c24b6008345e 100644 --- a/arch/mips/configs/db1200_defconfig +++ b/arch/mips/configs/db1200_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:40 2007 | 4 | # Tue Feb 20 21:47:25 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -541,6 +541,7 @@ CONFIG_MTD_NAND_IDS=y | |||
541 | # | 541 | # |
542 | # Plug and Play support | 542 | # Plug and Play support |
543 | # | 543 | # |
544 | # CONFIG_PNPACPI is not set | ||
544 | 545 | ||
545 | # | 546 | # |
546 | # Block devices | 547 | # Block devices |
@@ -1185,6 +1186,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1185 | CONFIG_LOG_BUF_SHIFT=14 | 1186 | CONFIG_LOG_BUF_SHIFT=14 |
1186 | CONFIG_CROSSCOMPILE=y | 1187 | CONFIG_CROSSCOMPILE=y |
1187 | CONFIG_CMDLINE="mem=48M" | 1188 | CONFIG_CMDLINE="mem=48M" |
1189 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1188 | 1190 | ||
1189 | # | 1191 | # |
1190 | # Security options | 1192 | # Security options |
diff --git a/arch/mips/configs/db1500_defconfig b/arch/mips/configs/db1500_defconfig index 9c944611edaa..baad2c5223ba 100644 --- a/arch/mips/configs/db1500_defconfig +++ b/arch/mips/configs/db1500_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:41 2007 | 4 | # Tue Feb 20 21:47:26 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -542,7 +542,6 @@ CONFIG_MTD_ALCHEMY=y | |||
542 | # NAND Flash Device Drivers | 542 | # NAND Flash Device Drivers |
543 | # | 543 | # |
544 | # CONFIG_MTD_NAND is not set | 544 | # CONFIG_MTD_NAND is not set |
545 | # CONFIG_MTD_NAND_CAFE is not set | ||
546 | 545 | ||
547 | # | 546 | # |
548 | # OneNAND Flash Device Drivers | 547 | # OneNAND Flash Device Drivers |
@@ -557,6 +556,7 @@ CONFIG_MTD_ALCHEMY=y | |||
557 | # | 556 | # |
558 | # Plug and Play support | 557 | # Plug and Play support |
559 | # | 558 | # |
559 | # CONFIG_PNPACPI is not set | ||
560 | 560 | ||
561 | # | 561 | # |
562 | # Block devices | 562 | # Block devices |
@@ -715,6 +715,7 @@ CONFIG_MIPS_AU1X00_ENET=y | |||
715 | # CONFIG_TIGON3 is not set | 715 | # CONFIG_TIGON3 is not set |
716 | # CONFIG_BNX2 is not set | 716 | # CONFIG_BNX2 is not set |
717 | CONFIG_QLA3XXX=m | 717 | CONFIG_QLA3XXX=m |
718 | # CONFIG_ATL1 is not set | ||
718 | 719 | ||
719 | # | 720 | # |
720 | # Ethernet (10000 Mbit) | 721 | # Ethernet (10000 Mbit) |
@@ -1145,6 +1146,7 @@ CONFIG_USB_MON=y | |||
1145 | # CONFIG_USB_RIO500 is not set | 1146 | # CONFIG_USB_RIO500 is not set |
1146 | # CONFIG_USB_LEGOTOWER is not set | 1147 | # CONFIG_USB_LEGOTOWER is not set |
1147 | # CONFIG_USB_LCD is not set | 1148 | # CONFIG_USB_LCD is not set |
1149 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1148 | # CONFIG_USB_LED is not set | 1150 | # CONFIG_USB_LED is not set |
1149 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 1151 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
1150 | # CONFIG_USB_CYTHERM is not set | 1152 | # CONFIG_USB_CYTHERM is not set |
@@ -1402,6 +1404,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1402 | CONFIG_LOG_BUF_SHIFT=14 | 1404 | CONFIG_LOG_BUF_SHIFT=14 |
1403 | CONFIG_CROSSCOMPILE=y | 1405 | CONFIG_CROSSCOMPILE=y |
1404 | CONFIG_CMDLINE="" | 1406 | CONFIG_CMDLINE="" |
1407 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1405 | 1408 | ||
1406 | # | 1409 | # |
1407 | # Security options | 1410 | # Security options |
diff --git a/arch/mips/configs/db1550_defconfig b/arch/mips/configs/db1550_defconfig index 5b18d5da9858..c29fdab0423a 100644 --- a/arch/mips/configs/db1550_defconfig +++ b/arch/mips/configs/db1550_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:42 2007 | 4 | # Tue Feb 20 21:47:27 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -562,6 +562,7 @@ CONFIG_MTD_NAND_AU1550=m | |||
562 | # | 562 | # |
563 | # Plug and Play support | 563 | # Plug and Play support |
564 | # | 564 | # |
565 | # CONFIG_PNPACPI is not set | ||
565 | 566 | ||
566 | # | 567 | # |
567 | # Block devices | 568 | # Block devices |
@@ -751,6 +752,7 @@ CONFIG_MIPS_AU1X00_ENET=y | |||
751 | # CONFIG_TIGON3 is not set | 752 | # CONFIG_TIGON3 is not set |
752 | # CONFIG_BNX2 is not set | 753 | # CONFIG_BNX2 is not set |
753 | CONFIG_QLA3XXX=m | 754 | CONFIG_QLA3XXX=m |
755 | # CONFIG_ATL1 is not set | ||
754 | 756 | ||
755 | # | 757 | # |
756 | # Ethernet (10000 Mbit) | 758 | # Ethernet (10000 Mbit) |
@@ -1219,6 +1221,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1219 | CONFIG_LOG_BUF_SHIFT=14 | 1221 | CONFIG_LOG_BUF_SHIFT=14 |
1220 | CONFIG_CROSSCOMPILE=y | 1222 | CONFIG_CROSSCOMPILE=y |
1221 | CONFIG_CMDLINE="" | 1223 | CONFIG_CMDLINE="" |
1224 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1222 | 1225 | ||
1223 | # | 1226 | # |
1224 | # Security options | 1227 | # Security options |
diff --git a/arch/mips/configs/ddb5477_defconfig b/arch/mips/configs/ddb5477_defconfig index 121018886189..f4b316d2cd70 100644 --- a/arch/mips/configs/ddb5477_defconfig +++ b/arch/mips/configs/ddb5477_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:43 2007 | 4 | # Tue Feb 20 21:47:28 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -386,6 +386,7 @@ CONFIG_PROC_EVENTS=y | |||
386 | # | 386 | # |
387 | # Plug and Play support | 387 | # Plug and Play support |
388 | # | 388 | # |
389 | # CONFIG_PNPACPI is not set | ||
389 | 390 | ||
390 | # | 391 | # |
391 | # Block devices | 392 | # Block devices |
@@ -925,6 +926,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
925 | CONFIG_LOG_BUF_SHIFT=14 | 926 | CONFIG_LOG_BUF_SHIFT=14 |
926 | CONFIG_CROSSCOMPILE=y | 927 | CONFIG_CROSSCOMPILE=y |
927 | CONFIG_CMDLINE="ip=any" | 928 | CONFIG_CMDLINE="ip=any" |
929 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
928 | 930 | ||
929 | # | 931 | # |
930 | # Security options | 932 | # Security options |
diff --git a/arch/mips/configs/decstation_defconfig b/arch/mips/configs/decstation_defconfig index 2d717455a82f..9c38e5c77761 100644 --- a/arch/mips/configs/decstation_defconfig +++ b/arch/mips/configs/decstation_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:44 2007 | 4 | # Tue Feb 20 21:47:28 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -398,6 +398,7 @@ CONFIG_CONNECTOR=m | |||
398 | # | 398 | # |
399 | # Plug and Play support | 399 | # Plug and Play support |
400 | # | 400 | # |
401 | # CONFIG_PNPACPI is not set | ||
401 | 402 | ||
402 | # | 403 | # |
403 | # Block devices | 404 | # Block devices |
diff --git a/arch/mips/configs/e55_defconfig b/arch/mips/configs/e55_defconfig index 0ee2fbb35f14..922af379aa41 100644 --- a/arch/mips/configs/e55_defconfig +++ b/arch/mips/configs/e55_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:44 2007 | 4 | # Tue Feb 20 21:47:28 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -294,6 +294,7 @@ CONFIG_PREVENT_FIRMWARE_BUILD=y | |||
294 | # Plug and Play support | 294 | # Plug and Play support |
295 | # | 295 | # |
296 | # CONFIG_PNP is not set | 296 | # CONFIG_PNP is not set |
297 | # CONFIG_PNPACPI is not set | ||
297 | 298 | ||
298 | # | 299 | # |
299 | # Block devices | 300 | # Block devices |
diff --git a/arch/mips/configs/emma2rh_defconfig b/arch/mips/configs/emma2rh_defconfig index 218fe6e5f2db..c0db8f14713d 100644 --- a/arch/mips/configs/emma2rh_defconfig +++ b/arch/mips/configs/emma2rh_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:46 2007 | 4 | # Tue Feb 20 21:47:29 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -611,7 +611,6 @@ CONFIG_MTD_PHYSMAP_BANKWIDTH=2 | |||
611 | # NAND Flash Device Drivers | 611 | # NAND Flash Device Drivers |
612 | # | 612 | # |
613 | # CONFIG_MTD_NAND is not set | 613 | # CONFIG_MTD_NAND is not set |
614 | # CONFIG_MTD_NAND_CAFE is not set | ||
615 | 614 | ||
616 | # | 615 | # |
617 | # OneNAND Flash Device Drivers | 616 | # OneNAND Flash Device Drivers |
@@ -626,6 +625,7 @@ CONFIG_MTD_PHYSMAP_BANKWIDTH=2 | |||
626 | # | 625 | # |
627 | # Plug and Play support | 626 | # Plug and Play support |
628 | # | 627 | # |
628 | # CONFIG_PNPACPI is not set | ||
629 | 629 | ||
630 | # | 630 | # |
631 | # Block devices | 631 | # Block devices |
@@ -1039,6 +1039,7 @@ CONFIG_HWMON=y | |||
1039 | # CONFIG_SENSORS_ADM1021 is not set | 1039 | # CONFIG_SENSORS_ADM1021 is not set |
1040 | # CONFIG_SENSORS_ADM1025 is not set | 1040 | # CONFIG_SENSORS_ADM1025 is not set |
1041 | # CONFIG_SENSORS_ADM1026 is not set | 1041 | # CONFIG_SENSORS_ADM1026 is not set |
1042 | # CONFIG_SENSORS_ADM1029 is not set | ||
1042 | # CONFIG_SENSORS_ADM1031 is not set | 1043 | # CONFIG_SENSORS_ADM1031 is not set |
1043 | # CONFIG_SENSORS_ADM9240 is not set | 1044 | # CONFIG_SENSORS_ADM9240 is not set |
1044 | # CONFIG_SENSORS_ASB100 is not set | 1045 | # CONFIG_SENSORS_ASB100 is not set |
diff --git a/arch/mips/configs/ev64120_defconfig b/arch/mips/configs/ev64120_defconfig index 5ad4870ad5eb..ce088b36291d 100644 --- a/arch/mips/configs/ev64120_defconfig +++ b/arch/mips/configs/ev64120_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:46 2007 | 4 | # Tue Feb 20 21:47:30 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -391,6 +391,7 @@ CONFIG_CONNECTOR=m | |||
391 | # | 391 | # |
392 | # Plug and Play support | 392 | # Plug and Play support |
393 | # | 393 | # |
394 | # CONFIG_PNPACPI is not set | ||
394 | 395 | ||
395 | # | 396 | # |
396 | # Block devices | 397 | # Block devices |
@@ -520,6 +521,7 @@ CONFIG_NET_ETHERNET=y | |||
520 | # CONFIG_TIGON3 is not set | 521 | # CONFIG_TIGON3 is not set |
521 | # CONFIG_BNX2 is not set | 522 | # CONFIG_BNX2 is not set |
522 | CONFIG_QLA3XXX=m | 523 | CONFIG_QLA3XXX=m |
524 | # CONFIG_ATL1 is not set | ||
523 | 525 | ||
524 | # | 526 | # |
525 | # Ethernet (10000 Mbit) | 527 | # Ethernet (10000 Mbit) |
@@ -914,6 +916,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
914 | CONFIG_LOG_BUF_SHIFT=14 | 916 | CONFIG_LOG_BUF_SHIFT=14 |
915 | CONFIG_CROSSCOMPILE=y | 917 | CONFIG_CROSSCOMPILE=y |
916 | CONFIG_CMDLINE="console=ttyS0,115200 root=/dev/nfs rw nfsroot=192.168.1.1:/mnt/disk2/fs.gal ip=192.168.1.211:192.168.1.1:::gt::" | 918 | CONFIG_CMDLINE="console=ttyS0,115200 root=/dev/nfs rw nfsroot=192.168.1.1:/mnt/disk2/fs.gal ip=192.168.1.211:192.168.1.1:::gt::" |
919 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
917 | 920 | ||
918 | # | 921 | # |
919 | # Security options | 922 | # Security options |
diff --git a/arch/mips/configs/excite_defconfig b/arch/mips/configs/excite_defconfig index 5e179fe599b3..82f204d080b7 100644 --- a/arch/mips/configs/excite_defconfig +++ b/arch/mips/configs/excite_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:47 2007 | 4 | # Tue Feb 20 21:47:31 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -451,6 +451,7 @@ CONFIG_MTD_NAND_VERIFY_WRITE=y | |||
451 | # CONFIG_MTD_NAND_ECC_SMC is not set | 451 | # CONFIG_MTD_NAND_ECC_SMC is not set |
452 | CONFIG_MTD_NAND_IDS=y | 452 | CONFIG_MTD_NAND_IDS=y |
453 | # CONFIG_MTD_NAND_DISKONCHIP is not set | 453 | # CONFIG_MTD_NAND_DISKONCHIP is not set |
454 | # CONFIG_MTD_NAND_BASLER_EXCITE is not set | ||
454 | # CONFIG_MTD_NAND_CAFE is not set | 455 | # CONFIG_MTD_NAND_CAFE is not set |
455 | # CONFIG_MTD_NAND_NANDSIM is not set | 456 | # CONFIG_MTD_NAND_NANDSIM is not set |
456 | 457 | ||
@@ -467,6 +468,7 @@ CONFIG_MTD_NAND_IDS=y | |||
467 | # | 468 | # |
468 | # Plug and Play support | 469 | # Plug and Play support |
469 | # | 470 | # |
471 | # CONFIG_PNPACPI is not set | ||
470 | 472 | ||
471 | # | 473 | # |
472 | # Block devices | 474 | # Block devices |
@@ -638,6 +640,7 @@ CONFIG_NETDEVICES=y | |||
638 | # CONFIG_TIGON3 is not set | 640 | # CONFIG_TIGON3 is not set |
639 | # CONFIG_BNX2 is not set | 641 | # CONFIG_BNX2 is not set |
640 | CONFIG_QLA3XXX=m | 642 | CONFIG_QLA3XXX=m |
643 | # CONFIG_ATL1 is not set | ||
641 | 644 | ||
642 | # | 645 | # |
643 | # Ethernet (10000 Mbit) | 646 | # Ethernet (10000 Mbit) |
@@ -1008,6 +1011,7 @@ CONFIG_USB_HID=m | |||
1008 | # CONFIG_USB_RIO500 is not set | 1011 | # CONFIG_USB_RIO500 is not set |
1009 | # CONFIG_USB_LEGOTOWER is not set | 1012 | # CONFIG_USB_LEGOTOWER is not set |
1010 | # CONFIG_USB_LCD is not set | 1013 | # CONFIG_USB_LCD is not set |
1014 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1011 | # CONFIG_USB_LED is not set | 1015 | # CONFIG_USB_LED is not set |
1012 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 1016 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
1013 | # CONFIG_USB_CYTHERM is not set | 1017 | # CONFIG_USB_CYTHERM is not set |
@@ -1277,6 +1281,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1277 | CONFIG_LOG_BUF_SHIFT=14 | 1281 | CONFIG_LOG_BUF_SHIFT=14 |
1278 | CONFIG_CROSSCOMPILE=y | 1282 | CONFIG_CROSSCOMPILE=y |
1279 | CONFIG_CMDLINE="" | 1283 | CONFIG_CMDLINE="" |
1284 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1280 | 1285 | ||
1281 | # | 1286 | # |
1282 | # Security options | 1287 | # Security options |
diff --git a/arch/mips/configs/ip22_defconfig b/arch/mips/configs/ip22_defconfig index 864de219eb67..cb81f13bd45a 100644 --- a/arch/mips/configs/ip22_defconfig +++ b/arch/mips/configs/ip22_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:48 2007 | 4 | # Tue Feb 20 21:47:32 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -620,6 +620,7 @@ CONFIG_CONNECTOR=m | |||
620 | # | 620 | # |
621 | # Plug and Play support | 621 | # Plug and Play support |
622 | # | 622 | # |
623 | # CONFIG_PNPACPI is not set | ||
623 | 624 | ||
624 | # | 625 | # |
625 | # Block devices | 626 | # Block devices |
diff --git a/arch/mips/configs/ip27_defconfig b/arch/mips/configs/ip27_defconfig index 7b2f5f8397a2..46f6ac4083b9 100644 --- a/arch/mips/configs/ip27_defconfig +++ b/arch/mips/configs/ip27_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:49 2007 | 4 | # Tue Feb 20 21:47:32 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -456,6 +456,7 @@ CONFIG_CONNECTOR=m | |||
456 | # | 456 | # |
457 | # Plug and Play support | 457 | # Plug and Play support |
458 | # | 458 | # |
459 | # CONFIG_PNPACPI is not set | ||
459 | 460 | ||
460 | # | 461 | # |
461 | # Block devices | 462 | # Block devices |
@@ -672,6 +673,7 @@ CONFIG_SGI_IOC3_ETH=y | |||
672 | # CONFIG_TIGON3 is not set | 673 | # CONFIG_TIGON3 is not set |
673 | # CONFIG_BNX2 is not set | 674 | # CONFIG_BNX2 is not set |
674 | CONFIG_QLA3XXX=m | 675 | CONFIG_QLA3XXX=m |
676 | # CONFIG_ATL1 is not set | ||
675 | 677 | ||
676 | # | 678 | # |
677 | # Ethernet (10000 Mbit) | 679 | # Ethernet (10000 Mbit) |
@@ -1060,6 +1062,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1060 | CONFIG_LOG_BUF_SHIFT=15 | 1062 | CONFIG_LOG_BUF_SHIFT=15 |
1061 | CONFIG_CROSSCOMPILE=y | 1063 | CONFIG_CROSSCOMPILE=y |
1062 | CONFIG_CMDLINE="" | 1064 | CONFIG_CMDLINE="" |
1065 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1063 | 1066 | ||
1064 | # | 1067 | # |
1065 | # Security options | 1068 | # Security options |
diff --git a/arch/mips/configs/ip32_defconfig b/arch/mips/configs/ip32_defconfig index 14398e8a1768..d9e5000d5329 100644 --- a/arch/mips/configs/ip32_defconfig +++ b/arch/mips/configs/ip32_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:50 2007 | 4 | # Tue Feb 20 21:47:33 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -396,6 +396,7 @@ CONFIG_PROC_EVENTS=y | |||
396 | # | 396 | # |
397 | # Plug and Play support | 397 | # Plug and Play support |
398 | # | 398 | # |
399 | # CONFIG_PNPACPI is not set | ||
399 | 400 | ||
400 | # | 401 | # |
401 | # Block devices | 402 | # Block devices |
@@ -600,6 +601,7 @@ CONFIG_SGI_O2MACE_ETH=y | |||
600 | # CONFIG_TIGON3 is not set | 601 | # CONFIG_TIGON3 is not set |
601 | # CONFIG_BNX2 is not set | 602 | # CONFIG_BNX2 is not set |
602 | CONFIG_QLA3XXX=y | 603 | CONFIG_QLA3XXX=y |
604 | # CONFIG_ATL1 is not set | ||
603 | 605 | ||
604 | # | 606 | # |
605 | # Ethernet (10000 Mbit) | 607 | # Ethernet (10000 Mbit) |
diff --git a/arch/mips/configs/jaguar-atx_defconfig b/arch/mips/configs/jaguar-atx_defconfig index b38978794a5a..57ef0c45a62b 100644 --- a/arch/mips/configs/jaguar-atx_defconfig +++ b/arch/mips/configs/jaguar-atx_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:51 2007 | 4 | # Tue Feb 20 21:47:33 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -375,6 +375,7 @@ CONFIG_CONNECTOR=m | |||
375 | # | 375 | # |
376 | # Plug and Play support | 376 | # Plug and Play support |
377 | # | 377 | # |
378 | # CONFIG_PNPACPI is not set | ||
378 | 379 | ||
379 | # | 380 | # |
380 | # Block devices | 381 | # Block devices |
@@ -518,9 +519,6 @@ CONFIG_EEPRO100=y | |||
518 | # CONFIG_TIGON3 is not set | 519 | # CONFIG_TIGON3 is not set |
519 | # CONFIG_BNX2 is not set | 520 | # CONFIG_BNX2 is not set |
520 | CONFIG_MV643XX_ETH=y | 521 | CONFIG_MV643XX_ETH=y |
521 | CONFIG_MV643XX_ETH_0=y | ||
522 | CONFIG_MV643XX_ETH_1=y | ||
523 | CONFIG_MV643XX_ETH_2=y | ||
524 | CONFIG_QLA3XXX=m | 522 | CONFIG_QLA3XXX=m |
525 | 523 | ||
526 | # | 524 | # |
@@ -833,6 +831,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
833 | CONFIG_LOG_BUF_SHIFT=14 | 831 | CONFIG_LOG_BUF_SHIFT=14 |
834 | CONFIG_CROSSCOMPILE=y | 832 | CONFIG_CROSSCOMPILE=y |
835 | CONFIG_CMDLINE="" | 833 | CONFIG_CMDLINE="" |
834 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
836 | 835 | ||
837 | # | 836 | # |
838 | # Security options | 837 | # Security options |
diff --git a/arch/mips/configs/jazz_defconfig b/arch/mips/configs/jazz_defconfig index dacf0a618d57..21d979f8326c 100644 --- a/arch/mips/configs/jazz_defconfig +++ b/arch/mips/configs/jazz_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:52 2007 | 4 | # Tue Feb 20 21:47:33 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -646,6 +646,7 @@ CONFIG_PARPORT_1284=y | |||
646 | # Plug and Play support | 646 | # Plug and Play support |
647 | # | 647 | # |
648 | # CONFIG_PNP is not set | 648 | # CONFIG_PNP is not set |
649 | # CONFIG_PNPACPI is not set | ||
649 | 650 | ||
650 | # | 651 | # |
651 | # Block devices | 652 | # Block devices |
diff --git a/arch/mips/configs/jmr3927_defconfig b/arch/mips/configs/jmr3927_defconfig index 29ed772455f1..9ebb522fbbbd 100644 --- a/arch/mips/configs/jmr3927_defconfig +++ b/arch/mips/configs/jmr3927_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:53 2007 | 4 | # Tue Feb 20 21:47:34 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -384,6 +384,7 @@ CONFIG_PROC_EVENTS=y | |||
384 | # | 384 | # |
385 | # Plug and Play support | 385 | # Plug and Play support |
386 | # | 386 | # |
387 | # CONFIG_PNPACPI is not set | ||
387 | 388 | ||
388 | # | 389 | # |
389 | # Block devices | 390 | # Block devices |
@@ -513,6 +514,7 @@ CONFIG_NET_ETHERNET=y | |||
513 | # CONFIG_TIGON3 is not set | 514 | # CONFIG_TIGON3 is not set |
514 | # CONFIG_BNX2 is not set | 515 | # CONFIG_BNX2 is not set |
515 | CONFIG_QLA3XXX=y | 516 | CONFIG_QLA3XXX=y |
517 | # CONFIG_ATL1 is not set | ||
516 | 518 | ||
517 | # | 519 | # |
518 | # Ethernet (10000 Mbit) | 520 | # Ethernet (10000 Mbit) |
diff --git a/arch/mips/configs/lasat200_defconfig b/arch/mips/configs/lasat200_defconfig index a1437b34e18f..b3f767ff1c5a 100644 --- a/arch/mips/configs/lasat200_defconfig +++ b/arch/mips/configs/lasat200_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:54 2007 | 4 | # Tue Feb 20 21:47:34 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -454,7 +454,6 @@ CONFIG_MTD_LASAT=y | |||
454 | # NAND Flash Device Drivers | 454 | # NAND Flash Device Drivers |
455 | # | 455 | # |
456 | # CONFIG_MTD_NAND is not set | 456 | # CONFIG_MTD_NAND is not set |
457 | # CONFIG_MTD_NAND_CAFE is not set | ||
458 | 457 | ||
459 | # | 458 | # |
460 | # OneNAND Flash Device Drivers | 459 | # OneNAND Flash Device Drivers |
@@ -469,6 +468,7 @@ CONFIG_MTD_LASAT=y | |||
469 | # | 468 | # |
470 | # Plug and Play support | 469 | # Plug and Play support |
471 | # | 470 | # |
471 | # CONFIG_PNPACPI is not set | ||
472 | 472 | ||
473 | # | 473 | # |
474 | # Block devices | 474 | # Block devices |
@@ -654,6 +654,7 @@ CONFIG_NET_ETHERNET=y | |||
654 | # CONFIG_TIGON3 is not set | 654 | # CONFIG_TIGON3 is not set |
655 | # CONFIG_BNX2 is not set | 655 | # CONFIG_BNX2 is not set |
656 | CONFIG_QLA3XXX=m | 656 | CONFIG_QLA3XXX=m |
657 | # CONFIG_ATL1 is not set | ||
657 | 658 | ||
658 | # | 659 | # |
659 | # Ethernet (10000 Mbit) | 660 | # Ethernet (10000 Mbit) |
diff --git a/arch/mips/configs/malta_defconfig b/arch/mips/configs/malta_defconfig index 8d21bb96349e..a5f379d626d6 100644 --- a/arch/mips/configs/malta_defconfig +++ b/arch/mips/configs/malta_defconfig | |||
@@ -145,6 +145,7 @@ CONFIG_SYS_SUPPORTS_MULTITHREADING=y | |||
145 | CONFIG_MIPS_MT_FPAFF=y | 145 | CONFIG_MIPS_MT_FPAFF=y |
146 | # CONFIG_64BIT_PHYS_ADDR is not set | 146 | # CONFIG_64BIT_PHYS_ADDR is not set |
147 | CONFIG_CPU_HAS_LLSC=y | 147 | CONFIG_CPU_HAS_LLSC=y |
148 | # CONFIG_CPU_HAS_SMARTMIPS is not set | ||
148 | CONFIG_CPU_MIPSR2_IRQ_VI=y | 149 | CONFIG_CPU_MIPSR2_IRQ_VI=y |
149 | CONFIG_CPU_MIPSR2_SRS=y | 150 | CONFIG_CPU_MIPSR2_SRS=y |
150 | CONFIG_CPU_HAS_SYNC=y | 151 | CONFIG_CPU_HAS_SYNC=y |
@@ -152,6 +153,7 @@ CONFIG_GENERIC_HARDIRQS=y | |||
152 | CONFIG_GENERIC_IRQ_PROBE=y | 153 | CONFIG_GENERIC_IRQ_PROBE=y |
153 | CONFIG_IRQ_PER_CPU=y | 154 | CONFIG_IRQ_PER_CPU=y |
154 | CONFIG_CPU_SUPPORTS_HIGHMEM=y | 155 | CONFIG_CPU_SUPPORTS_HIGHMEM=y |
156 | CONFIG_SYS_SUPPORTS_SMARTMIPS=y | ||
155 | CONFIG_ARCH_FLATMEM_ENABLE=y | 157 | CONFIG_ARCH_FLATMEM_ENABLE=y |
156 | CONFIG_SELECT_MEMORY_MODEL=y | 158 | CONFIG_SELECT_MEMORY_MODEL=y |
157 | CONFIG_FLATMEM_MANUAL=y | 159 | CONFIG_FLATMEM_MANUAL=y |
diff --git a/arch/mips/configs/mipssim_defconfig b/arch/mips/configs/mipssim_defconfig index 2acb99bf2eca..5ff53e184912 100644 --- a/arch/mips/configs/mipssim_defconfig +++ b/arch/mips/configs/mipssim_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:56 2007 | 4 | # Tue Feb 20 21:47:35 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -436,6 +436,7 @@ CONFIG_FIB_RULES=y | |||
436 | # | 436 | # |
437 | # Plug and Play support | 437 | # Plug and Play support |
438 | # | 438 | # |
439 | # CONFIG_PNPACPI is not set | ||
439 | 440 | ||
440 | # | 441 | # |
441 | # Block devices | 442 | # Block devices |
@@ -878,7 +879,6 @@ CONFIG_FORCED_INLINING=y | |||
878 | CONFIG_CROSSCOMPILE=y | 879 | CONFIG_CROSSCOMPILE=y |
879 | CONFIG_CMDLINE="nfsroot=192.168.192.169:/u1/mipsel,timeo=20 ip=dhcp" | 880 | CONFIG_CMDLINE="nfsroot=192.168.192.169:/u1/mipsel,timeo=20 ip=dhcp" |
880 | # CONFIG_DEBUG_STACK_USAGE is not set | 881 | # CONFIG_DEBUG_STACK_USAGE is not set |
881 | # CONFIG_KGDB is not set | ||
882 | # CONFIG_RUNTIME_DEBUG is not set | 882 | # CONFIG_RUNTIME_DEBUG is not set |
883 | # CONFIG_MIPS_UNCACHED is not set | 883 | # CONFIG_MIPS_UNCACHED is not set |
884 | 884 | ||
diff --git a/arch/mips/configs/mpc30x_defconfig b/arch/mips/configs/mpc30x_defconfig index d52a5a4877da..750e6445c613 100644 --- a/arch/mips/configs/mpc30x_defconfig +++ b/arch/mips/configs/mpc30x_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:56 2007 | 4 | # Tue Feb 20 21:47:35 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -405,6 +405,7 @@ CONFIG_CONNECTOR=m | |||
405 | # | 405 | # |
406 | # Plug and Play support | 406 | # Plug and Play support |
407 | # | 407 | # |
408 | # CONFIG_PNPACPI is not set | ||
408 | 409 | ||
409 | # | 410 | # |
410 | # Block devices | 411 | # Block devices |
@@ -531,6 +532,7 @@ CONFIG_MII=m | |||
531 | # CONFIG_TIGON3 is not set | 532 | # CONFIG_TIGON3 is not set |
532 | # CONFIG_BNX2 is not set | 533 | # CONFIG_BNX2 is not set |
533 | CONFIG_QLA3XXX=m | 534 | CONFIG_QLA3XXX=m |
535 | # CONFIG_ATL1 is not set | ||
534 | 536 | ||
535 | # | 537 | # |
536 | # Ethernet (10000 Mbit) | 538 | # Ethernet (10000 Mbit) |
@@ -883,6 +885,7 @@ CONFIG_USB_PEGASUS=m | |||
883 | # CONFIG_USB_RIO500 is not set | 885 | # CONFIG_USB_RIO500 is not set |
884 | # CONFIG_USB_LEGOTOWER is not set | 886 | # CONFIG_USB_LEGOTOWER is not set |
885 | # CONFIG_USB_LCD is not set | 887 | # CONFIG_USB_LCD is not set |
888 | # CONFIG_USB_BERRY_CHARGE is not set | ||
886 | # CONFIG_USB_LED is not set | 889 | # CONFIG_USB_LED is not set |
887 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 890 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
888 | # CONFIG_USB_CYTHERM is not set | 891 | # CONFIG_USB_CYTHERM is not set |
diff --git a/arch/mips/configs/ocelot_3_defconfig b/arch/mips/configs/ocelot_3_defconfig index 746106b88bab..2febd0a7fba2 100644 --- a/arch/mips/configs/ocelot_3_defconfig +++ b/arch/mips/configs/ocelot_3_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:58 2007 | 4 | # Tue Feb 20 21:47:35 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -496,6 +496,7 @@ CONFIG_CONNECTOR=m | |||
496 | # | 496 | # |
497 | # Plug and Play support | 497 | # Plug and Play support |
498 | # | 498 | # |
499 | # CONFIG_PNPACPI is not set | ||
499 | 500 | ||
500 | # | 501 | # |
501 | # Block devices | 502 | # Block devices |
@@ -713,9 +714,6 @@ CONFIG_E100=y | |||
713 | # CONFIG_TIGON3 is not set | 714 | # CONFIG_TIGON3 is not set |
714 | # CONFIG_BNX2 is not set | 715 | # CONFIG_BNX2 is not set |
715 | CONFIG_MV643XX_ETH=y | 716 | CONFIG_MV643XX_ETH=y |
716 | CONFIG_MV643XX_ETH_0=y | ||
717 | CONFIG_MV643XX_ETH_1=y | ||
718 | CONFIG_MV643XX_ETH_2=y | ||
719 | CONFIG_QLA3XXX=m | 717 | CONFIG_QLA3XXX=m |
720 | # CONFIG_ATL1 is not set | 718 | # CONFIG_ATL1 is not set |
721 | 719 | ||
diff --git a/arch/mips/configs/ocelot_c_defconfig b/arch/mips/configs/ocelot_c_defconfig index 4b32b270df39..b8f457300bbf 100644 --- a/arch/mips/configs/ocelot_c_defconfig +++ b/arch/mips/configs/ocelot_c_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:58 2007 | 4 | # Tue Feb 20 21:47:36 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -393,6 +393,7 @@ CONFIG_PROC_EVENTS=y | |||
393 | # | 393 | # |
394 | # Plug and Play support | 394 | # Plug and Play support |
395 | # | 395 | # |
396 | # CONFIG_PNPACPI is not set | ||
396 | 397 | ||
397 | # | 398 | # |
398 | # Block devices | 399 | # Block devices |
@@ -523,6 +524,7 @@ CONFIG_NET_ETHERNET=y | |||
523 | # CONFIG_BNX2 is not set | 524 | # CONFIG_BNX2 is not set |
524 | # CONFIG_MV643XX_ETH is not set | 525 | # CONFIG_MV643XX_ETH is not set |
525 | CONFIG_QLA3XXX=y | 526 | CONFIG_QLA3XXX=y |
527 | # CONFIG_ATL1 is not set | ||
526 | 528 | ||
527 | # | 529 | # |
528 | # Ethernet (10000 Mbit) | 530 | # Ethernet (10000 Mbit) |
diff --git a/arch/mips/configs/ocelot_defconfig b/arch/mips/configs/ocelot_defconfig index 674631b09c99..8ade072271cd 100644 --- a/arch/mips/configs/ocelot_defconfig +++ b/arch/mips/configs/ocelot_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:59 2007 | 4 | # Tue Feb 20 21:47:36 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -390,6 +390,7 @@ CONFIG_PROC_EVENTS=y | |||
390 | # | 390 | # |
391 | # Plug and Play support | 391 | # Plug and Play support |
392 | # | 392 | # |
393 | # CONFIG_PNPACPI is not set | ||
393 | 394 | ||
394 | # | 395 | # |
395 | # Block devices | 396 | # Block devices |
@@ -854,6 +855,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
854 | CONFIG_LOG_BUF_SHIFT=14 | 855 | CONFIG_LOG_BUF_SHIFT=14 |
855 | CONFIG_CROSSCOMPILE=y | 856 | CONFIG_CROSSCOMPILE=y |
856 | CONFIG_CMDLINE="" | 857 | CONFIG_CMDLINE="" |
858 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
857 | 859 | ||
858 | # | 860 | # |
859 | # Security options | 861 | # Security options |
diff --git a/arch/mips/configs/ocelot_g_defconfig b/arch/mips/configs/ocelot_g_defconfig index 260026392347..d20a2216c11d 100644 --- a/arch/mips/configs/ocelot_g_defconfig +++ b/arch/mips/configs/ocelot_g_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:00 2007 | 4 | # Tue Feb 20 21:47:36 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -392,6 +392,7 @@ CONFIG_PROC_EVENTS=y | |||
392 | # | 392 | # |
393 | # Plug and Play support | 393 | # Plug and Play support |
394 | # | 394 | # |
395 | # CONFIG_PNPACPI is not set | ||
395 | 396 | ||
396 | # | 397 | # |
397 | # Block devices | 398 | # Block devices |
@@ -522,6 +523,7 @@ CONFIG_GALILEO_64240_ETH=y | |||
522 | # CONFIG_TIGON3 is not set | 523 | # CONFIG_TIGON3 is not set |
523 | # CONFIG_BNX2 is not set | 524 | # CONFIG_BNX2 is not set |
524 | CONFIG_QLA3XXX=y | 525 | CONFIG_QLA3XXX=y |
526 | # CONFIG_ATL1 is not set | ||
525 | 527 | ||
526 | # | 528 | # |
527 | # Ethernet (10000 Mbit) | 529 | # Ethernet (10000 Mbit) |
diff --git a/arch/mips/configs/pb1100_defconfig b/arch/mips/configs/pb1100_defconfig index 05a33a2aeb25..33fcc8133bc0 100644 --- a/arch/mips/configs/pb1100_defconfig +++ b/arch/mips/configs/pb1100_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:01 2007 | 4 | # Tue Feb 20 21:47:37 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -549,6 +549,7 @@ CONFIG_MTD_ALCHEMY=y | |||
549 | # | 549 | # |
550 | # Plug and Play support | 550 | # Plug and Play support |
551 | # | 551 | # |
552 | # CONFIG_PNPACPI is not set | ||
552 | 553 | ||
553 | # | 554 | # |
554 | # Block devices | 555 | # Block devices |
@@ -1096,6 +1097,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1096 | CONFIG_LOG_BUF_SHIFT=14 | 1097 | CONFIG_LOG_BUF_SHIFT=14 |
1097 | CONFIG_CROSSCOMPILE=y | 1098 | CONFIG_CROSSCOMPILE=y |
1098 | CONFIG_CMDLINE="" | 1099 | CONFIG_CMDLINE="" |
1100 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1099 | 1101 | ||
1100 | # | 1102 | # |
1101 | # Security options | 1103 | # Security options |
diff --git a/arch/mips/configs/pb1500_defconfig b/arch/mips/configs/pb1500_defconfig index 34a6bee589bd..e07c55dc8dc1 100644 --- a/arch/mips/configs/pb1500_defconfig +++ b/arch/mips/configs/pb1500_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:02 2007 | 4 | # Tue Feb 20 21:47:37 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -541,7 +541,6 @@ CONFIG_MTD_ALCHEMY=y | |||
541 | # NAND Flash Device Drivers | 541 | # NAND Flash Device Drivers |
542 | # | 542 | # |
543 | # CONFIG_MTD_NAND is not set | 543 | # CONFIG_MTD_NAND is not set |
544 | # CONFIG_MTD_NAND_CAFE is not set | ||
545 | 544 | ||
546 | # | 545 | # |
547 | # OneNAND Flash Device Drivers | 546 | # OneNAND Flash Device Drivers |
@@ -556,6 +555,7 @@ CONFIG_MTD_ALCHEMY=y | |||
556 | # | 555 | # |
557 | # Plug and Play support | 556 | # Plug and Play support |
558 | # | 557 | # |
558 | # CONFIG_PNPACPI is not set | ||
559 | 559 | ||
560 | # | 560 | # |
561 | # Block devices | 561 | # Block devices |
@@ -745,6 +745,7 @@ CONFIG_MIPS_AU1X00_ENET=y | |||
745 | # CONFIG_TIGON3 is not set | 745 | # CONFIG_TIGON3 is not set |
746 | # CONFIG_BNX2 is not set | 746 | # CONFIG_BNX2 is not set |
747 | CONFIG_QLA3XXX=m | 747 | CONFIG_QLA3XXX=m |
748 | # CONFIG_ATL1 is not set | ||
748 | 749 | ||
749 | # | 750 | # |
750 | # Ethernet (10000 Mbit) | 751 | # Ethernet (10000 Mbit) |
@@ -1213,6 +1214,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1213 | CONFIG_LOG_BUF_SHIFT=14 | 1214 | CONFIG_LOG_BUF_SHIFT=14 |
1214 | CONFIG_CROSSCOMPILE=y | 1215 | CONFIG_CROSSCOMPILE=y |
1215 | CONFIG_CMDLINE="" | 1216 | CONFIG_CMDLINE="" |
1217 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1216 | 1218 | ||
1217 | # | 1219 | # |
1218 | # Security options | 1220 | # Security options |
diff --git a/arch/mips/configs/pb1550_defconfig b/arch/mips/configs/pb1550_defconfig index e3bff462e62e..df210dd22476 100644 --- a/arch/mips/configs/pb1550_defconfig +++ b/arch/mips/configs/pb1550_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:03 2007 | 4 | # Tue Feb 20 21:47:37 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -542,7 +542,6 @@ CONFIG_MTD_ALCHEMY=y | |||
542 | # NAND Flash Device Drivers | 542 | # NAND Flash Device Drivers |
543 | # | 543 | # |
544 | # CONFIG_MTD_NAND is not set | 544 | # CONFIG_MTD_NAND is not set |
545 | # CONFIG_MTD_NAND_CAFE is not set | ||
546 | 545 | ||
547 | # | 546 | # |
548 | # OneNAND Flash Device Drivers | 547 | # OneNAND Flash Device Drivers |
@@ -557,6 +556,7 @@ CONFIG_MTD_ALCHEMY=y | |||
557 | # | 556 | # |
558 | # Plug and Play support | 557 | # Plug and Play support |
559 | # | 558 | # |
559 | # CONFIG_PNPACPI is not set | ||
560 | 560 | ||
561 | # | 561 | # |
562 | # Block devices | 562 | # Block devices |
@@ -746,6 +746,7 @@ CONFIG_MIPS_AU1X00_ENET=y | |||
746 | # CONFIG_TIGON3 is not set | 746 | # CONFIG_TIGON3 is not set |
747 | # CONFIG_BNX2 is not set | 747 | # CONFIG_BNX2 is not set |
748 | CONFIG_QLA3XXX=m | 748 | CONFIG_QLA3XXX=m |
749 | # CONFIG_ATL1 is not set | ||
749 | 750 | ||
750 | # | 751 | # |
751 | # Ethernet (10000 Mbit) | 752 | # Ethernet (10000 Mbit) |
@@ -1206,6 +1207,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1206 | CONFIG_LOG_BUF_SHIFT=14 | 1207 | CONFIG_LOG_BUF_SHIFT=14 |
1207 | CONFIG_CROSSCOMPILE=y | 1208 | CONFIG_CROSSCOMPILE=y |
1208 | CONFIG_CMDLINE="" | 1209 | CONFIG_CMDLINE="" |
1210 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1209 | 1211 | ||
1210 | # | 1212 | # |
1211 | # Security options | 1213 | # Security options |
diff --git a/arch/mips/configs/pnx8550-jbs_defconfig b/arch/mips/configs/pnx8550-jbs_defconfig index 009b3f87b44e..106a1641c0b5 100644 --- a/arch/mips/configs/pnx8550-jbs_defconfig +++ b/arch/mips/configs/pnx8550-jbs_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:04 2007 | 4 | # Tue Feb 20 21:47:38 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -389,6 +389,7 @@ CONFIG_FW_LOADER=y | |||
389 | # | 389 | # |
390 | # Plug and Play support | 390 | # Plug and Play support |
391 | # | 391 | # |
392 | # CONFIG_PNPACPI is not set | ||
392 | 393 | ||
393 | # | 394 | # |
394 | # Block devices | 395 | # Block devices |
@@ -962,6 +963,7 @@ CONFIG_USB_MON=y | |||
962 | # CONFIG_USB_RIO500 is not set | 963 | # CONFIG_USB_RIO500 is not set |
963 | # CONFIG_USB_LEGOTOWER is not set | 964 | # CONFIG_USB_LEGOTOWER is not set |
964 | # CONFIG_USB_LCD is not set | 965 | # CONFIG_USB_LCD is not set |
966 | # CONFIG_USB_BERRY_CHARGE is not set | ||
965 | # CONFIG_USB_LED is not set | 967 | # CONFIG_USB_LED is not set |
966 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 968 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
967 | # CONFIG_USB_CYTHERM is not set | 969 | # CONFIG_USB_CYTHERM is not set |
@@ -1229,6 +1231,7 @@ CONFIG_CROSSCOMPILE=y | |||
1229 | CONFIG_CMDLINE="console=ttyS1,38400n8 kgdb=ttyS0 root=/dev/nfs ip=bootp" | 1231 | CONFIG_CMDLINE="console=ttyS1,38400n8 kgdb=ttyS0 root=/dev/nfs ip=bootp" |
1230 | # CONFIG_DEBUG_STACK_USAGE is not set | 1232 | # CONFIG_DEBUG_STACK_USAGE is not set |
1231 | # CONFIG_KGDB is not set | 1233 | # CONFIG_KGDB is not set |
1234 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1232 | # CONFIG_RUNTIME_DEBUG is not set | 1235 | # CONFIG_RUNTIME_DEBUG is not set |
1233 | # CONFIG_MIPS_UNCACHED is not set | 1236 | # CONFIG_MIPS_UNCACHED is not set |
1234 | 1237 | ||
diff --git a/arch/mips/configs/pnx8550-stb810_defconfig b/arch/mips/configs/pnx8550-stb810_defconfig index 5bd377bdbb2c..8caa2cd1aa7c 100644 --- a/arch/mips/configs/pnx8550-stb810_defconfig +++ b/arch/mips/configs/pnx8550-stb810_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:04 2007 | 4 | # Tue Feb 20 21:47:38 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -386,6 +386,7 @@ CONFIG_PREVENT_FIRMWARE_BUILD=y | |||
386 | # | 386 | # |
387 | # Plug and Play support | 387 | # Plug and Play support |
388 | # | 388 | # |
389 | # CONFIG_PNPACPI is not set | ||
389 | 390 | ||
390 | # | 391 | # |
391 | # Block devices | 392 | # Block devices |
@@ -952,6 +953,7 @@ CONFIG_USB_MON=y | |||
952 | # CONFIG_USB_RIO500 is not set | 953 | # CONFIG_USB_RIO500 is not set |
953 | # CONFIG_USB_LEGOTOWER is not set | 954 | # CONFIG_USB_LEGOTOWER is not set |
954 | # CONFIG_USB_LCD is not set | 955 | # CONFIG_USB_LCD is not set |
956 | # CONFIG_USB_BERRY_CHARGE is not set | ||
955 | # CONFIG_USB_LED is not set | 957 | # CONFIG_USB_LED is not set |
956 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 958 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
957 | # CONFIG_USB_CYTHERM is not set | 959 | # CONFIG_USB_CYTHERM is not set |
@@ -1219,6 +1221,7 @@ CONFIG_CROSSCOMPILE=y | |||
1219 | CONFIG_CMDLINE="console=ttyS1,38400n8 kgdb=ttyS0 root=/dev/nfs ip=bootp" | 1221 | CONFIG_CMDLINE="console=ttyS1,38400n8 kgdb=ttyS0 root=/dev/nfs ip=bootp" |
1220 | # CONFIG_DEBUG_STACK_USAGE is not set | 1222 | # CONFIG_DEBUG_STACK_USAGE is not set |
1221 | # CONFIG_KGDB is not set | 1223 | # CONFIG_KGDB is not set |
1224 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1222 | # CONFIG_RUNTIME_DEBUG is not set | 1225 | # CONFIG_RUNTIME_DEBUG is not set |
1223 | # CONFIG_MIPS_UNCACHED is not set | 1226 | # CONFIG_MIPS_UNCACHED is not set |
1224 | 1227 | ||
diff --git a/arch/mips/configs/pnx8550-v2pci_defconfig b/arch/mips/configs/pnx8550-v2pci_defconfig index cc694709ba65..43f1becec2a4 100644 --- a/arch/mips/configs/pnx8550-v2pci_defconfig +++ b/arch/mips/configs/pnx8550-v2pci_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:06 2007 | 4 | # Tue Feb 20 21:47:39 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -474,6 +474,7 @@ CONFIG_FW_LOADER=y | |||
474 | # | 474 | # |
475 | # Plug and Play support | 475 | # Plug and Play support |
476 | # | 476 | # |
477 | # CONFIG_PNPACPI is not set | ||
477 | 478 | ||
478 | # | 479 | # |
479 | # Block devices | 480 | # Block devices |
@@ -987,6 +988,7 @@ CONFIG_HWMON=y | |||
987 | # CONFIG_SENSORS_ADM1021 is not set | 988 | # CONFIG_SENSORS_ADM1021 is not set |
988 | # CONFIG_SENSORS_ADM1025 is not set | 989 | # CONFIG_SENSORS_ADM1025 is not set |
989 | # CONFIG_SENSORS_ADM1026 is not set | 990 | # CONFIG_SENSORS_ADM1026 is not set |
991 | # CONFIG_SENSORS_ADM1029 is not set | ||
990 | # CONFIG_SENSORS_ADM1031 is not set | 992 | # CONFIG_SENSORS_ADM1031 is not set |
991 | # CONFIG_SENSORS_ADM9240 is not set | 993 | # CONFIG_SENSORS_ADM9240 is not set |
992 | # CONFIG_SENSORS_ASB100 is not set | 994 | # CONFIG_SENSORS_ASB100 is not set |
@@ -1209,6 +1211,7 @@ CONFIG_USB_MON=y | |||
1209 | # CONFIG_USB_RIO500 is not set | 1211 | # CONFIG_USB_RIO500 is not set |
1210 | # CONFIG_USB_LEGOTOWER is not set | 1212 | # CONFIG_USB_LEGOTOWER is not set |
1211 | # CONFIG_USB_LCD is not set | 1213 | # CONFIG_USB_LCD is not set |
1214 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1212 | # CONFIG_USB_LED is not set | 1215 | # CONFIG_USB_LED is not set |
1213 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 1216 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
1214 | # CONFIG_USB_CYTHERM is not set | 1217 | # CONFIG_USB_CYTHERM is not set |
@@ -1466,6 +1469,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1466 | CONFIG_LOG_BUF_SHIFT=14 | 1469 | CONFIG_LOG_BUF_SHIFT=14 |
1467 | CONFIG_CROSSCOMPILE=y | 1470 | CONFIG_CROSSCOMPILE=y |
1468 | CONFIG_CMDLINE="" | 1471 | CONFIG_CMDLINE="" |
1472 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1469 | 1473 | ||
1470 | # | 1474 | # |
1471 | # Security options | 1475 | # Security options |
diff --git a/arch/mips/configs/qemu_defconfig b/arch/mips/configs/qemu_defconfig index c18c5e71d8ac..f68396d19f9a 100644 --- a/arch/mips/configs/qemu_defconfig +++ b/arch/mips/configs/qemu_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:06 2007 | 4 | # Tue Feb 20 21:47:39 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -348,6 +348,7 @@ CONFIG_PROC_EVENTS=y | |||
348 | # Plug and Play support | 348 | # Plug and Play support |
349 | # | 349 | # |
350 | # CONFIG_PNP is not set | 350 | # CONFIG_PNP is not set |
351 | # CONFIG_PNPACPI is not set | ||
351 | 352 | ||
352 | # | 353 | # |
353 | # Block devices | 354 | # Block devices |
diff --git a/arch/mips/configs/rbhma4500_defconfig b/arch/mips/configs/rbhma4500_defconfig index 678f23217c9a..a6a824fcc874 100644 --- a/arch/mips/configs/rbhma4500_defconfig +++ b/arch/mips/configs/rbhma4500_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:07 2007 | 4 | # Tue Feb 20 21:47:39 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -560,7 +560,6 @@ CONFIG_MTD_CFI_UTIL=y | |||
560 | # NAND Flash Device Drivers | 560 | # NAND Flash Device Drivers |
561 | # | 561 | # |
562 | # CONFIG_MTD_NAND is not set | 562 | # CONFIG_MTD_NAND is not set |
563 | # CONFIG_MTD_NAND_CAFE is not set | ||
564 | 563 | ||
565 | # | 564 | # |
566 | # OneNAND Flash Device Drivers | 565 | # OneNAND Flash Device Drivers |
@@ -576,6 +575,7 @@ CONFIG_MTD_CFI_UTIL=y | |||
576 | # Plug and Play support | 575 | # Plug and Play support |
577 | # | 576 | # |
578 | # CONFIG_PNP is not set | 577 | # CONFIG_PNP is not set |
578 | # CONFIG_PNPACPI is not set | ||
579 | 579 | ||
580 | # | 580 | # |
581 | # Block devices | 581 | # Block devices |
@@ -1191,6 +1191,7 @@ CONFIG_USB_MON=y | |||
1191 | # CONFIG_USB_RIO500 is not set | 1191 | # CONFIG_USB_RIO500 is not set |
1192 | # CONFIG_USB_LEGOTOWER is not set | 1192 | # CONFIG_USB_LEGOTOWER is not set |
1193 | # CONFIG_USB_LCD is not set | 1193 | # CONFIG_USB_LCD is not set |
1194 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1194 | # CONFIG_USB_LED is not set | 1195 | # CONFIG_USB_LED is not set |
1195 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 1196 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
1196 | # CONFIG_USB_CYTHERM is not set | 1197 | # CONFIG_USB_CYTHERM is not set |
@@ -1462,6 +1463,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1462 | CONFIG_LOG_BUF_SHIFT=14 | 1463 | CONFIG_LOG_BUF_SHIFT=14 |
1463 | CONFIG_CROSSCOMPILE=y | 1464 | CONFIG_CROSSCOMPILE=y |
1464 | CONFIG_CMDLINE="" | 1465 | CONFIG_CMDLINE="" |
1466 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
1465 | 1467 | ||
1466 | # | 1468 | # |
1467 | # Security options | 1469 | # Security options |
diff --git a/arch/mips/configs/rm200_defconfig b/arch/mips/configs/rm200_defconfig index 0417e86ab627..bee3702d501d 100644 --- a/arch/mips/configs/rm200_defconfig +++ b/arch/mips/configs/rm200_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:09 2007 | 4 | # Tue Feb 20 21:47:40 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -661,6 +661,7 @@ CONFIG_PARPORT_NOT_PC=y | |||
661 | # Plug and Play support | 661 | # Plug and Play support |
662 | # | 662 | # |
663 | # CONFIG_PNP is not set | 663 | # CONFIG_PNP is not set |
664 | # CONFIG_PNPACPI is not set | ||
664 | 665 | ||
665 | # | 666 | # |
666 | # Block devices | 667 | # Block devices |
@@ -1397,6 +1398,7 @@ CONFIG_USB_AUERSWALD=m | |||
1397 | CONFIG_USB_RIO500=m | 1398 | CONFIG_USB_RIO500=m |
1398 | CONFIG_USB_LEGOTOWER=m | 1399 | CONFIG_USB_LEGOTOWER=m |
1399 | CONFIG_USB_LCD=m | 1400 | CONFIG_USB_LCD=m |
1401 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1400 | CONFIG_USB_LED=m | 1402 | CONFIG_USB_LED=m |
1401 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 1403 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
1402 | CONFIG_USB_CYTHERM=m | 1404 | CONFIG_USB_CYTHERM=m |
diff --git a/arch/mips/configs/sb1250-swarm_defconfig b/arch/mips/configs/sb1250-swarm_defconfig index 533df6fd8b4d..3c891ed10141 100644 --- a/arch/mips/configs/sb1250-swarm_defconfig +++ b/arch/mips/configs/sb1250-swarm_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:09 2007 | 4 | # Tue Feb 20 21:47:40 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -424,6 +424,7 @@ CONFIG_CONNECTOR=m | |||
424 | # | 424 | # |
425 | # Plug and Play support | 425 | # Plug and Play support |
426 | # | 426 | # |
427 | # CONFIG_PNPACPI is not set | ||
427 | 428 | ||
428 | # | 429 | # |
429 | # Block devices | 430 | # Block devices |
@@ -581,6 +582,7 @@ CONFIG_NET_SB1250_MAC=y | |||
581 | # CONFIG_TIGON3 is not set | 582 | # CONFIG_TIGON3 is not set |
582 | # CONFIG_BNX2 is not set | 583 | # CONFIG_BNX2 is not set |
583 | CONFIG_QLA3XXX=m | 584 | CONFIG_QLA3XXX=m |
585 | # CONFIG_ATL1 is not set | ||
584 | 586 | ||
585 | # | 587 | # |
586 | # Ethernet (10000 Mbit) | 588 | # Ethernet (10000 Mbit) |
@@ -945,6 +947,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
945 | CONFIG_LOG_BUF_SHIFT=15 | 947 | CONFIG_LOG_BUF_SHIFT=15 |
946 | CONFIG_CROSSCOMPILE=y | 948 | CONFIG_CROSSCOMPILE=y |
947 | CONFIG_CMDLINE="" | 949 | CONFIG_CMDLINE="" |
950 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
948 | # CONFIG_SB1XXX_CORELIS is not set | 951 | # CONFIG_SB1XXX_CORELIS is not set |
949 | 952 | ||
950 | # | 953 | # |
diff --git a/arch/mips/configs/sead_defconfig b/arch/mips/configs/sead_defconfig index 38816fe264a9..e31d964a053b 100644 --- a/arch/mips/configs/sead_defconfig +++ b/arch/mips/configs/sead_defconfig | |||
@@ -129,10 +129,12 @@ CONFIG_MIPS_MT_DISABLED=y | |||
129 | # CONFIG_MIPS_VPE_LOADER is not set | 129 | # CONFIG_MIPS_VPE_LOADER is not set |
130 | # CONFIG_64BIT_PHYS_ADDR is not set | 130 | # CONFIG_64BIT_PHYS_ADDR is not set |
131 | CONFIG_CPU_HAS_LLSC=y | 131 | CONFIG_CPU_HAS_LLSC=y |
132 | # CONFIG_CPU_HAS_SMARTMIPS is not set | ||
132 | CONFIG_CPU_HAS_SYNC=y | 133 | CONFIG_CPU_HAS_SYNC=y |
133 | CONFIG_GENERIC_HARDIRQS=y | 134 | CONFIG_GENERIC_HARDIRQS=y |
134 | CONFIG_GENERIC_IRQ_PROBE=y | 135 | CONFIG_GENERIC_IRQ_PROBE=y |
135 | CONFIG_CPU_SUPPORTS_HIGHMEM=y | 136 | CONFIG_CPU_SUPPORTS_HIGHMEM=y |
137 | CONFIG_SYS_SUPPORTS_SMARTMIPS=y | ||
136 | CONFIG_ARCH_FLATMEM_ENABLE=y | 138 | CONFIG_ARCH_FLATMEM_ENABLE=y |
137 | CONFIG_SELECT_MEMORY_MODEL=y | 139 | CONFIG_SELECT_MEMORY_MODEL=y |
138 | CONFIG_FLATMEM_MANUAL=y | 140 | CONFIG_FLATMEM_MANUAL=y |
diff --git a/arch/mips/configs/tb0226_defconfig b/arch/mips/configs/tb0226_defconfig index c2f7c8cea1e8..5771c1aee76a 100644 --- a/arch/mips/configs/tb0226_defconfig +++ b/arch/mips/configs/tb0226_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:11 2007 | 4 | # Tue Feb 20 21:47:41 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -396,6 +396,7 @@ CONFIG_CONNECTOR=m | |||
396 | # | 396 | # |
397 | # Plug and Play support | 397 | # Plug and Play support |
398 | # | 398 | # |
399 | # CONFIG_PNPACPI is not set | ||
399 | 400 | ||
400 | # | 401 | # |
401 | # Block devices | 402 | # Block devices |
@@ -920,6 +921,7 @@ CONFIG_USB_STORAGE=y | |||
920 | # CONFIG_USB_RIO500 is not set | 921 | # CONFIG_USB_RIO500 is not set |
921 | # CONFIG_USB_LEGOTOWER is not set | 922 | # CONFIG_USB_LEGOTOWER is not set |
922 | # CONFIG_USB_LCD is not set | 923 | # CONFIG_USB_LCD is not set |
924 | # CONFIG_USB_BERRY_CHARGE is not set | ||
923 | # CONFIG_USB_LED is not set | 925 | # CONFIG_USB_LED is not set |
924 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 926 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
925 | # CONFIG_USB_CYTHERM is not set | 927 | # CONFIG_USB_CYTHERM is not set |
diff --git a/arch/mips/configs/tb0229_defconfig b/arch/mips/configs/tb0229_defconfig index 33b788089ab5..a8eb4b182d34 100644 --- a/arch/mips/configs/tb0229_defconfig +++ b/arch/mips/configs/tb0229_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:12 2007 | 4 | # Tue Feb 20 21:47:41 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -397,6 +397,7 @@ CONFIG_PREVENT_FIRMWARE_BUILD=y | |||
397 | # | 397 | # |
398 | # Plug and Play support | 398 | # Plug and Play support |
399 | # | 399 | # |
400 | # CONFIG_PNPACPI is not set | ||
400 | 401 | ||
401 | # | 402 | # |
402 | # Block devices | 403 | # Block devices |
@@ -530,6 +531,7 @@ CONFIG_R8169=y | |||
530 | # CONFIG_TIGON3 is not set | 531 | # CONFIG_TIGON3 is not set |
531 | # CONFIG_BNX2 is not set | 532 | # CONFIG_BNX2 is not set |
532 | CONFIG_QLA3XXX=m | 533 | CONFIG_QLA3XXX=m |
534 | # CONFIG_ATL1 is not set | ||
533 | 535 | ||
534 | # | 536 | # |
535 | # Ethernet (10000 Mbit) | 537 | # Ethernet (10000 Mbit) |
@@ -819,6 +821,7 @@ CONFIG_USB_MON=y | |||
819 | # CONFIG_USB_RIO500 is not set | 821 | # CONFIG_USB_RIO500 is not set |
820 | # CONFIG_USB_LEGOTOWER is not set | 822 | # CONFIG_USB_LEGOTOWER is not set |
821 | # CONFIG_USB_LCD is not set | 823 | # CONFIG_USB_LCD is not set |
824 | # CONFIG_USB_BERRY_CHARGE is not set | ||
822 | # CONFIG_USB_LED is not set | 825 | # CONFIG_USB_LED is not set |
823 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 826 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
824 | # CONFIG_USB_CYTHERM is not set | 827 | # CONFIG_USB_CYTHERM is not set |
diff --git a/arch/mips/configs/tb0287_defconfig b/arch/mips/configs/tb0287_defconfig index d180586d6385..69b87304fdbc 100644 --- a/arch/mips/configs/tb0287_defconfig +++ b/arch/mips/configs/tb0287_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:13 2007 | 4 | # Tue Feb 20 21:47:41 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -409,6 +409,7 @@ CONFIG_PREVENT_FIRMWARE_BUILD=y | |||
409 | # | 409 | # |
410 | # Plug and Play support | 410 | # Plug and Play support |
411 | # | 411 | # |
412 | # CONFIG_PNPACPI is not set | ||
412 | 413 | ||
413 | # | 414 | # |
414 | # Block devices | 415 | # Block devices |
@@ -675,6 +676,7 @@ CONFIG_R8169=y | |||
675 | # CONFIG_TIGON3 is not set | 676 | # CONFIG_TIGON3 is not set |
676 | # CONFIG_BNX2 is not set | 677 | # CONFIG_BNX2 is not set |
677 | # CONFIG_QLA3XXX is not set | 678 | # CONFIG_QLA3XXX is not set |
679 | # CONFIG_ATL1 is not set | ||
678 | 680 | ||
679 | # | 681 | # |
680 | # Ethernet (10000 Mbit) | 682 | # Ethernet (10000 Mbit) |
@@ -1016,6 +1018,7 @@ CONFIG_USB_MON=y | |||
1016 | # CONFIG_USB_RIO500 is not set | 1018 | # CONFIG_USB_RIO500 is not set |
1017 | # CONFIG_USB_LEGOTOWER is not set | 1019 | # CONFIG_USB_LEGOTOWER is not set |
1018 | # CONFIG_USB_LCD is not set | 1020 | # CONFIG_USB_LCD is not set |
1021 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1019 | # CONFIG_USB_LED is not set | 1022 | # CONFIG_USB_LED is not set |
1020 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 1023 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
1021 | # CONFIG_USB_CYTHERM is not set | 1024 | # CONFIG_USB_CYTHERM is not set |
diff --git a/arch/mips/configs/workpad_defconfig b/arch/mips/configs/workpad_defconfig index 570f0c1475b3..2abbd6827720 100644 --- a/arch/mips/configs/workpad_defconfig +++ b/arch/mips/configs/workpad_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:13 2007 | 4 | # Tue Feb 20 21:47:42 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -396,6 +396,7 @@ CONFIG_CONNECTOR=m | |||
396 | # Plug and Play support | 396 | # Plug and Play support |
397 | # | 397 | # |
398 | # CONFIG_PNP is not set | 398 | # CONFIG_PNP is not set |
399 | # CONFIG_PNPACPI is not set | ||
399 | 400 | ||
400 | # | 401 | # |
401 | # Block devices | 402 | # Block devices |
diff --git a/arch/mips/configs/wrppmc_defconfig b/arch/mips/configs/wrppmc_defconfig index 08f3190dda89..44b6b7c1fdb6 100644 --- a/arch/mips/configs/wrppmc_defconfig +++ b/arch/mips/configs/wrppmc_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:14 2007 | 4 | # Tue Feb 20 21:47:42 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -400,6 +400,7 @@ CONFIG_PREVENT_FIRMWARE_BUILD=y | |||
400 | # | 400 | # |
401 | # Plug and Play support | 401 | # Plug and Play support |
402 | # | 402 | # |
403 | # CONFIG_PNPACPI is not set | ||
403 | 404 | ||
404 | # | 405 | # |
405 | # Block devices | 406 | # Block devices |
diff --git a/arch/mips/configs/yosemite_defconfig b/arch/mips/configs/yosemite_defconfig index aa69fee321d2..f24e1c6fc484 100644 --- a/arch/mips/configs/yosemite_defconfig +++ b/arch/mips/configs/yosemite_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:28:15 2007 | 4 | # Tue Feb 20 21:47:42 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -381,6 +381,7 @@ CONFIG_CONNECTOR=m | |||
381 | # | 381 | # |
382 | # Plug and Play support | 382 | # Plug and Play support |
383 | # | 383 | # |
384 | # CONFIG_PNPACPI is not set | ||
384 | 385 | ||
385 | # | 386 | # |
386 | # Block devices | 387 | # Block devices |
@@ -841,6 +842,7 @@ CONFIG_CROSSCOMPILE=y | |||
841 | CONFIG_CMDLINE="" | 842 | CONFIG_CMDLINE="" |
842 | # CONFIG_DEBUG_STACK_USAGE is not set | 843 | # CONFIG_DEBUG_STACK_USAGE is not set |
843 | # CONFIG_KGDB is not set | 844 | # CONFIG_KGDB is not set |
845 | CONFIG_SYS_SUPPORTS_KGDB=y | ||
844 | # CONFIG_RUNTIME_DEBUG is not set | 846 | # CONFIG_RUNTIME_DEBUG is not set |
845 | 847 | ||
846 | # | 848 | # |
diff --git a/arch/mips/defconfig b/arch/mips/defconfig index 6c2a233e36cb..8cb8f5919194 100644 --- a/arch/mips/defconfig +++ b/arch/mips/defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.20 |
4 | # Sun Feb 18 21:27:34 2007 | 4 | # Tue Feb 20 21:47:14 2007 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
@@ -620,6 +620,7 @@ CONFIG_CONNECTOR=m | |||
620 | # | 620 | # |
621 | # Plug and Play support | 621 | # Plug and Play support |
622 | # | 622 | # |
623 | # CONFIG_PNPACPI is not set | ||
623 | 624 | ||
624 | # | 625 | # |
625 | # Block devices | 626 | # Block devices |
diff --git a/arch/mips/kernel/asm-offsets.c b/arch/mips/kernel/asm-offsets.c index c0b089d47181..222de465db73 100644 --- a/arch/mips/kernel/asm-offsets.c +++ b/arch/mips/kernel/asm-offsets.c | |||
@@ -64,6 +64,9 @@ void output_ptreg_defines(void) | |||
64 | offset("#define PT_R31 ", struct pt_regs, regs[31]); | 64 | offset("#define PT_R31 ", struct pt_regs, regs[31]); |
65 | offset("#define PT_LO ", struct pt_regs, lo); | 65 | offset("#define PT_LO ", struct pt_regs, lo); |
66 | offset("#define PT_HI ", struct pt_regs, hi); | 66 | offset("#define PT_HI ", struct pt_regs, hi); |
67 | #ifdef CONFIG_CPU_HAS_SMARTMIPS | ||
68 | offset("#define PT_ACX ", struct pt_regs, acx); | ||
69 | #endif | ||
67 | offset("#define PT_EPC ", struct pt_regs, cp0_epc); | 70 | offset("#define PT_EPC ", struct pt_regs, cp0_epc); |
68 | offset("#define PT_BVADDR ", struct pt_regs, cp0_badvaddr); | 71 | offset("#define PT_BVADDR ", struct pt_regs, cp0_badvaddr); |
69 | offset("#define PT_STATUS ", struct pt_regs, cp0_status); | 72 | offset("#define PT_STATUS ", struct pt_regs, cp0_status); |
@@ -246,6 +249,7 @@ void output_sc_defines(void) | |||
246 | text("/* Linux sigcontext offsets. */"); | 249 | text("/* Linux sigcontext offsets. */"); |
247 | offset("#define SC_REGS ", struct sigcontext, sc_regs); | 250 | offset("#define SC_REGS ", struct sigcontext, sc_regs); |
248 | offset("#define SC_FPREGS ", struct sigcontext, sc_fpregs); | 251 | offset("#define SC_FPREGS ", struct sigcontext, sc_fpregs); |
252 | offset("#define SC_ACX ", struct sigcontext, sc_acx); | ||
249 | offset("#define SC_MDHI ", struct sigcontext, sc_mdhi); | 253 | offset("#define SC_MDHI ", struct sigcontext, sc_mdhi); |
250 | offset("#define SC_MDLO ", struct sigcontext, sc_mdlo); | 254 | offset("#define SC_MDLO ", struct sigcontext, sc_mdlo); |
251 | offset("#define SC_PC ", struct sigcontext, sc_pc); | 255 | offset("#define SC_PC ", struct sigcontext, sc_pc); |
diff --git a/arch/mips/kernel/ptrace.c b/arch/mips/kernel/ptrace.c index 258d74fd0b63..201ae194d1b8 100644 --- a/arch/mips/kernel/ptrace.c +++ b/arch/mips/kernel/ptrace.c | |||
@@ -236,6 +236,11 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
236 | case MMLO: | 236 | case MMLO: |
237 | tmp = regs->lo; | 237 | tmp = regs->lo; |
238 | break; | 238 | break; |
239 | #ifdef CONFIG_CPU_HAS_SMARTMIPS | ||
240 | case ACX: | ||
241 | tmp = regs->acx; | ||
242 | break; | ||
243 | #endif | ||
239 | case FPC_CSR: | 244 | case FPC_CSR: |
240 | tmp = child->thread.fpu.fcr31; | 245 | tmp = child->thread.fpu.fcr31; |
241 | break; | 246 | break; |
@@ -362,6 +367,11 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
362 | case MMLO: | 367 | case MMLO: |
363 | regs->lo = data; | 368 | regs->lo = data; |
364 | break; | 369 | break; |
370 | #ifdef CONFIG_CPU_HAS_SMARTMIPS | ||
371 | case ACX: | ||
372 | regs->acx = data; | ||
373 | break; | ||
374 | #endif | ||
365 | case FPC_CSR: | 375 | case FPC_CSR: |
366 | child->thread.fpu.fcr31 = data; | 376 | child->thread.fpu.fcr31 = data; |
367 | break; | 377 | break; |
diff --git a/arch/mips/kernel/signal.c b/arch/mips/kernel/signal.c index adbfb95e42d0..f091786187a6 100644 --- a/arch/mips/kernel/signal.c +++ b/arch/mips/kernel/signal.c | |||
@@ -89,6 +89,9 @@ int setup_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc) | |||
89 | for (i = 1; i < 32; i++) | 89 | for (i = 1; i < 32; i++) |
90 | err |= __put_user(regs->regs[i], &sc->sc_regs[i]); | 90 | err |= __put_user(regs->regs[i], &sc->sc_regs[i]); |
91 | 91 | ||
92 | #ifdef CONFIG_CPU_HAS_SMARTMIPS | ||
93 | err |= __put_user(regs->acx, &sc->sc_acx); | ||
94 | #endif | ||
92 | err |= __put_user(regs->hi, &sc->sc_mdhi); | 95 | err |= __put_user(regs->hi, &sc->sc_mdhi); |
93 | err |= __put_user(regs->lo, &sc->sc_mdlo); | 96 | err |= __put_user(regs->lo, &sc->sc_mdlo); |
94 | if (cpu_has_dsp) { | 97 | if (cpu_has_dsp) { |
@@ -132,6 +135,10 @@ int restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc) | |||
132 | current_thread_info()->restart_block.fn = do_no_restart_syscall; | 135 | current_thread_info()->restart_block.fn = do_no_restart_syscall; |
133 | 136 | ||
134 | err |= __get_user(regs->cp0_epc, &sc->sc_pc); | 137 | err |= __get_user(regs->cp0_epc, &sc->sc_pc); |
138 | |||
139 | #ifdef CONFIG_CPU_HAS_SMARTMIPS | ||
140 | err |= __get_user(regs->acx, &sc->sc_acx); | ||
141 | #endif | ||
135 | err |= __get_user(regs->hi, &sc->sc_mdhi); | 142 | err |= __get_user(regs->hi, &sc->sc_mdhi); |
136 | err |= __get_user(regs->lo, &sc->sc_mdlo); | 143 | err |= __get_user(regs->lo, &sc->sc_mdlo); |
137 | if (cpu_has_dsp) { | 144 | if (cpu_has_dsp) { |
diff --git a/arch/mips/kernel/smp.c b/arch/mips/kernel/smp.c index 0555fc554f65..c46e479c992b 100644 --- a/arch/mips/kernel/smp.c +++ b/arch/mips/kernel/smp.c | |||
@@ -51,31 +51,14 @@ int __cpu_logical_map[NR_CPUS]; /* Map logical to physical */ | |||
51 | EXPORT_SYMBOL(phys_cpu_present_map); | 51 | EXPORT_SYMBOL(phys_cpu_present_map); |
52 | EXPORT_SYMBOL(cpu_online_map); | 52 | EXPORT_SYMBOL(cpu_online_map); |
53 | 53 | ||
54 | /* This happens early in bootup, can't really do it better */ | ||
54 | static void smp_tune_scheduling (void) | 55 | static void smp_tune_scheduling (void) |
55 | { | 56 | { |
56 | struct cache_desc *cd = ¤t_cpu_data.scache; | 57 | struct cache_desc *cd = ¤t_cpu_data.scache; |
57 | unsigned long cachesize; /* kB */ | 58 | unsigned long cachesize = cd->linesz * cd->sets * cd->ways; |
58 | unsigned long cpu_khz; | ||
59 | 59 | ||
60 | /* | 60 | if (cachesize > max_cache_size) |
61 | * Crude estimate until we actually meassure ... | 61 | max_cache_size = cachesize; |
62 | */ | ||
63 | cpu_khz = loops_per_jiffy * 2 * HZ / 1000; | ||
64 | |||
65 | /* | ||
66 | * Rough estimation for SMP scheduling, this is the number of | ||
67 | * cycles it takes for a fully memory-limited process to flush | ||
68 | * the SMP-local cache. | ||
69 | * | ||
70 | * (For a P5 this pretty much means we will choose another idle | ||
71 | * CPU almost always at wakeup time (this is due to the small | ||
72 | * L1 cache), on PIIs it's around 50-100 usecs, depending on | ||
73 | * the cache size) | ||
74 | */ | ||
75 | if (!cpu_khz) | ||
76 | return; | ||
77 | |||
78 | cachesize = cd->linesz * cd->sets * cd->ways; | ||
79 | } | 62 | } |
80 | 63 | ||
81 | extern void __init calibrate_delay(void); | 64 | extern void __init calibrate_delay(void); |
diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c index 2aa208b99da8..18f56a9dbcfa 100644 --- a/arch/mips/kernel/traps.c +++ b/arch/mips/kernel/traps.c | |||
@@ -229,6 +229,9 @@ void show_regs(struct pt_regs *regs) | |||
229 | printk("\n"); | 229 | printk("\n"); |
230 | } | 230 | } |
231 | 231 | ||
232 | #ifdef CONFIG_CPU_HAS_SMARTMIPS | ||
233 | printk("Acx : %0*lx\n", field, regs->acx); | ||
234 | #endif | ||
232 | printk("Hi : %0*lx\n", field, regs->hi); | 235 | printk("Hi : %0*lx\n", field, regs->hi); |
233 | printk("Lo : %0*lx\n", field, regs->lo); | 236 | printk("Lo : %0*lx\n", field, regs->lo); |
234 | 237 | ||
diff --git a/arch/mips/mm/ioremap.c b/arch/mips/mm/ioremap.c index fc2c96f0a1fd..cea7d0ea36e4 100644 --- a/arch/mips/mm/ioremap.c +++ b/arch/mips/mm/ioremap.c | |||
@@ -6,13 +6,98 @@ | |||
6 | * (C) Copyright 1995 1996 Linus Torvalds | 6 | * (C) Copyright 1995 1996 Linus Torvalds |
7 | * (C) Copyright 2001, 2002 Ralf Baechle | 7 | * (C) Copyright 2001, 2002 Ralf Baechle |
8 | */ | 8 | */ |
9 | #include <linux/mm.h> | ||
10 | #include <linux/module.h> | 9 | #include <linux/module.h> |
11 | #include <asm/addrspace.h> | 10 | #include <asm/addrspace.h> |
12 | #include <asm/byteorder.h> | 11 | #include <asm/byteorder.h> |
13 | 12 | ||
14 | #include <linux/vmalloc.h> | 13 | #include <linux/vmalloc.h> |
15 | #include <linux/io.h> | 14 | #include <asm/cacheflush.h> |
15 | #include <asm/io.h> | ||
16 | #include <asm/tlbflush.h> | ||
17 | |||
18 | static inline void remap_area_pte(pte_t * pte, unsigned long address, | ||
19 | phys_t size, phys_t phys_addr, unsigned long flags) | ||
20 | { | ||
21 | phys_t end; | ||
22 | unsigned long pfn; | ||
23 | pgprot_t pgprot = __pgprot(_PAGE_GLOBAL | _PAGE_PRESENT | __READABLE | ||
24 | | __WRITEABLE | flags); | ||
25 | |||
26 | address &= ~PMD_MASK; | ||
27 | end = address + size; | ||
28 | if (end > PMD_SIZE) | ||
29 | end = PMD_SIZE; | ||
30 | if (address >= end) | ||
31 | BUG(); | ||
32 | pfn = phys_addr >> PAGE_SHIFT; | ||
33 | do { | ||
34 | if (!pte_none(*pte)) { | ||
35 | printk("remap_area_pte: page already exists\n"); | ||
36 | BUG(); | ||
37 | } | ||
38 | set_pte(pte, pfn_pte(pfn, pgprot)); | ||
39 | address += PAGE_SIZE; | ||
40 | pfn++; | ||
41 | pte++; | ||
42 | } while (address && (address < end)); | ||
43 | } | ||
44 | |||
45 | static inline int remap_area_pmd(pmd_t * pmd, unsigned long address, | ||
46 | phys_t size, phys_t phys_addr, unsigned long flags) | ||
47 | { | ||
48 | phys_t end; | ||
49 | |||
50 | address &= ~PGDIR_MASK; | ||
51 | end = address + size; | ||
52 | if (end > PGDIR_SIZE) | ||
53 | end = PGDIR_SIZE; | ||
54 | phys_addr -= address; | ||
55 | if (address >= end) | ||
56 | BUG(); | ||
57 | do { | ||
58 | pte_t * pte = pte_alloc_kernel(pmd, address); | ||
59 | if (!pte) | ||
60 | return -ENOMEM; | ||
61 | remap_area_pte(pte, address, end - address, address + phys_addr, flags); | ||
62 | address = (address + PMD_SIZE) & PMD_MASK; | ||
63 | pmd++; | ||
64 | } while (address && (address < end)); | ||
65 | return 0; | ||
66 | } | ||
67 | |||
68 | static int remap_area_pages(unsigned long address, phys_t phys_addr, | ||
69 | phys_t size, unsigned long flags) | ||
70 | { | ||
71 | int error; | ||
72 | pgd_t * dir; | ||
73 | unsigned long end = address + size; | ||
74 | |||
75 | phys_addr -= address; | ||
76 | dir = pgd_offset(&init_mm, address); | ||
77 | flush_cache_all(); | ||
78 | if (address >= end) | ||
79 | BUG(); | ||
80 | do { | ||
81 | pud_t *pud; | ||
82 | pmd_t *pmd; | ||
83 | |||
84 | error = -ENOMEM; | ||
85 | pud = pud_alloc(&init_mm, dir, address); | ||
86 | if (!pud) | ||
87 | break; | ||
88 | pmd = pmd_alloc(&init_mm, pud, address); | ||
89 | if (!pmd) | ||
90 | break; | ||
91 | if (remap_area_pmd(pmd, address, end - address, | ||
92 | phys_addr + address, flags)) | ||
93 | break; | ||
94 | error = 0; | ||
95 | address = (address + PGDIR_SIZE) & PGDIR_MASK; | ||
96 | dir++; | ||
97 | } while (address && (address < end)); | ||
98 | flush_tlb_all(); | ||
99 | return error; | ||
100 | } | ||
16 | 101 | ||
17 | /* | 102 | /* |
18 | * Generic mapping function (not visible outside): | 103 | * Generic mapping function (not visible outside): |
@@ -36,7 +121,6 @@ void __iomem * __ioremap(phys_t phys_addr, phys_t size, unsigned long flags) | |||
36 | unsigned long offset; | 121 | unsigned long offset; |
37 | phys_t last_addr; | 122 | phys_t last_addr; |
38 | void * addr; | 123 | void * addr; |
39 | pgprot_t pgprot; | ||
40 | 124 | ||
41 | phys_addr = fixup_bigphys_addr(phys_addr, size); | 125 | phys_addr = fixup_bigphys_addr(phys_addr, size); |
42 | 126 | ||
@@ -68,9 +152,6 @@ void __iomem * __ioremap(phys_t phys_addr, phys_t size, unsigned long flags) | |||
68 | return NULL; | 152 | return NULL; |
69 | } | 153 | } |
70 | 154 | ||
71 | pgprot = __pgprot(_PAGE_GLOBAL | _PAGE_PRESENT | __READABLE | ||
72 | | __WRITEABLE | flags); | ||
73 | |||
74 | /* | 155 | /* |
75 | * Mappings have to be page-aligned | 156 | * Mappings have to be page-aligned |
76 | */ | 157 | */ |
@@ -85,8 +166,7 @@ void __iomem * __ioremap(phys_t phys_addr, phys_t size, unsigned long flags) | |||
85 | if (!area) | 166 | if (!area) |
86 | return NULL; | 167 | return NULL; |
87 | addr = area->addr; | 168 | addr = area->addr; |
88 | if (ioremap_page_range((unsigned long)addr, (unsigned long)addr + size, | 169 | if (remap_area_pages((unsigned long) addr, phys_addr, size, flags)) { |
89 | phys_addr, pgprot)) { | ||
90 | vunmap(addr); | 170 | vunmap(addr); |
91 | return NULL; | 171 | return NULL; |
92 | } | 172 | } |
diff --git a/arch/mips/momentum/jaguar_atx/platform.c b/arch/mips/momentum/jaguar_atx/platform.c index c78ba3025af4..3df36eda75af 100644 --- a/arch/mips/momentum/jaguar_atx/platform.c +++ b/arch/mips/momentum/jaguar_atx/platform.c | |||
@@ -200,7 +200,7 @@ static int __init mv643xx_eth_add_pds(void) | |||
200 | int ret; | 200 | int ret; |
201 | 201 | ||
202 | get_mac(mac); | 202 | get_mac(mac); |
203 | eth_mac_add(eth1_mac_addr, mac, 0); | 203 | eth_mac_add(eth0_mac_addr, mac, 0); |
204 | eth_mac_add(eth1_mac_addr, mac, 1); | 204 | eth_mac_add(eth1_mac_addr, mac, 1); |
205 | eth_mac_add(eth2_mac_addr, mac, 2); | 205 | eth_mac_add(eth2_mac_addr, mac, 2); |
206 | ret = platform_add_devices(mv643xx_eth_pd_devs, | 206 | ret = platform_add_devices(mv643xx_eth_pd_devs, |
diff --git a/arch/mips/momentum/ocelot_3/platform.c b/arch/mips/momentum/ocelot_3/platform.c index 0ab8d231cf7d..024aef25f372 100644 --- a/arch/mips/momentum/ocelot_3/platform.c +++ b/arch/mips/momentum/ocelot_3/platform.c | |||
@@ -200,7 +200,7 @@ static int __init mv643xx_eth_add_pds(void) | |||
200 | int ret; | 200 | int ret; |
201 | 201 | ||
202 | get_mac(mac); | 202 | get_mac(mac); |
203 | eth_mac_add(eth1_mac_addr, mac, 0); | 203 | eth_mac_add(eth0_mac_addr, mac, 0); |
204 | eth_mac_add(eth1_mac_addr, mac, 1); | 204 | eth_mac_add(eth1_mac_addr, mac, 1); |
205 | eth_mac_add(eth2_mac_addr, mac, 2); | 205 | eth_mac_add(eth2_mac_addr, mac, 2); |
206 | ret = platform_add_devices(mv643xx_eth_pd_devs, | 206 | ret = platform_add_devices(mv643xx_eth_pd_devs, |
diff --git a/arch/mips/momentum/ocelot_c/platform.c b/arch/mips/momentum/ocelot_c/platform.c index 8e381d447573..fac8b2499387 100644 --- a/arch/mips/momentum/ocelot_c/platform.c +++ b/arch/mips/momentum/ocelot_c/platform.c | |||
@@ -174,7 +174,7 @@ static int __init mv643xx_eth_add_pds(void) | |||
174 | int ret; | 174 | int ret; |
175 | 175 | ||
176 | get_mac(mac); | 176 | get_mac(mac); |
177 | eth_mac_add(eth1_mac_addr, mac, 0); | 177 | eth_mac_add(eth0_mac_addr, mac, 0); |
178 | eth_mac_add(eth1_mac_addr, mac, 1); | 178 | eth_mac_add(eth1_mac_addr, mac, 1); |
179 | ret = platform_add_devices(mv643xx_eth_pd_devs, | 179 | ret = platform_add_devices(mv643xx_eth_pd_devs, |
180 | ARRAY_SIZE(mv643xx_eth_pd_devs)); | 180 | ARRAY_SIZE(mv643xx_eth_pd_devs)); |
diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig index 28da4e71c443..3d73545e8c48 100644 --- a/arch/parisc/Kconfig +++ b/arch/parisc/Kconfig | |||
@@ -37,6 +37,11 @@ config GENERIC_FIND_NEXT_BIT | |||
37 | bool | 37 | bool |
38 | default y | 38 | default y |
39 | 39 | ||
40 | config GENERIC_BUG | ||
41 | bool | ||
42 | default y | ||
43 | depends on BUG | ||
44 | |||
40 | config GENERIC_HWEIGHT | 45 | config GENERIC_HWEIGHT |
41 | bool | 46 | bool |
42 | default y | 47 | default y |
@@ -45,6 +50,10 @@ config GENERIC_CALIBRATE_DELAY | |||
45 | bool | 50 | bool |
46 | default y | 51 | default y |
47 | 52 | ||
53 | config GENERIC_TIME | ||
54 | bool | ||
55 | default y | ||
56 | |||
48 | config TIME_LOW_RES | 57 | config TIME_LOW_RES |
49 | bool | 58 | bool |
50 | depends on SMP | 59 | depends on SMP |
diff --git a/arch/parisc/Makefile b/arch/parisc/Makefile index 9b7e42490dd1..760567a9ba16 100644 --- a/arch/parisc/Makefile +++ b/arch/parisc/Makefile | |||
@@ -35,12 +35,8 @@ FINAL_LD=$(CROSS_COMPILE)ld --warn-common --warn-section-align | |||
35 | 35 | ||
36 | OBJCOPY_FLAGS =-O binary -R .note -R .comment -S | 36 | OBJCOPY_FLAGS =-O binary -R .note -R .comment -S |
37 | 37 | ||
38 | GCC_VERSION := $(call cc-version) | 38 | ifneq ($(call cc-ifversion, -lt, 0303, "bad"),) |
39 | ifneq ($(shell if [ -z $(GCC_VERSION) ] ; then echo "bad"; fi ;),) | 39 | $(error Sorry, GCC v3.3 or above is required.) |
40 | $(error Sorry, couldn't find ($(cc-version)).) | ||
41 | endif | ||
42 | ifneq ($(shell if [ $(GCC_VERSION) -lt 0303 ] ; then echo "bad"; fi ;),) | ||
43 | $(error Sorry, your compiler is too old ($(GCC_VERSION)). GCC v3.3 or above is required.) | ||
44 | endif | 40 | endif |
45 | 41 | ||
46 | cflags-y := -pipe | 42 | cflags-y := -pipe |
diff --git a/arch/parisc/hpux/entry_hpux.S b/arch/parisc/hpux/entry_hpux.S index 31c8cccfba31..d15a413572f0 100644 --- a/arch/parisc/hpux/entry_hpux.S +++ b/arch/parisc/hpux/entry_hpux.S | |||
@@ -18,17 +18,16 @@ | |||
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
19 | */ | 19 | */ |
20 | 20 | ||
21 | #include <asm/unistd.h> | ||
22 | #include <asm/assembly.h> | ||
21 | #include <linux/sys.h> | 23 | #include <linux/sys.h> |
22 | #include <linux/linkage.h> | 24 | #include <linux/linkage.h> |
23 | #include <asm/unistd.h> | ||
24 | 25 | ||
25 | #define ENTRY_NAME(_name_) .word _name_ | 26 | #define ENTRY_NAME(_name_) ASM_ULONG_INSN _name_ |
26 | 27 | ||
27 | .section .rodata,"a" | 28 | .section .rodata,"a" |
28 | .align 4 | ||
29 | .export hpux_call_table | ||
30 | .import hpux_unimplemented_wrapper | 29 | .import hpux_unimplemented_wrapper |
31 | hpux_call_table: | 30 | ENTRY(hpux_call_table) |
32 | ENTRY_NAME(sys_ni_syscall) /* 0 */ | 31 | ENTRY_NAME(sys_ni_syscall) /* 0 */ |
33 | ENTRY_NAME(sys_exit) | 32 | ENTRY_NAME(sys_exit) |
34 | ENTRY_NAME(hpux_fork_wrapper) | 33 | ENTRY_NAME(hpux_fork_wrapper) |
@@ -542,5 +541,6 @@ hpux_call_table: | |||
542 | ENTRY_NAME(hpux_unimplemented_wrapper) /* 510 */ | 541 | ENTRY_NAME(hpux_unimplemented_wrapper) /* 510 */ |
543 | ENTRY_NAME(hpux_unimplemented_wrapper) | 542 | ENTRY_NAME(hpux_unimplemented_wrapper) |
544 | ENTRY_NAME(hpux_unimplemented_wrapper) | 543 | ENTRY_NAME(hpux_unimplemented_wrapper) |
544 | END(hpux_call_table) | ||
545 | .end | 545 | .end |
546 | 546 | ||
diff --git a/arch/parisc/hpux/fs.c b/arch/parisc/hpux/fs.c index 4204cd1f3cf9..c7a81a2c014c 100644 --- a/arch/parisc/hpux/fs.c +++ b/arch/parisc/hpux/fs.c | |||
@@ -35,13 +35,13 @@ int hpux_execve(struct pt_regs *regs) | |||
35 | int error; | 35 | int error; |
36 | char *filename; | 36 | char *filename; |
37 | 37 | ||
38 | filename = getname((char *) regs->gr[26]); | 38 | filename = getname((char __user *) regs->gr[26]); |
39 | error = PTR_ERR(filename); | 39 | error = PTR_ERR(filename); |
40 | if (IS_ERR(filename)) | 40 | if (IS_ERR(filename)) |
41 | goto out; | 41 | goto out; |
42 | 42 | ||
43 | error = do_execve(filename, (char **) regs->gr[25], | 43 | error = do_execve(filename, (char __user * __user *) regs->gr[25], |
44 | (char **)regs->gr[24], regs); | 44 | (char __user * __user *) regs->gr[24], regs); |
45 | 45 | ||
46 | if (error == 0) { | 46 | if (error == 0) { |
47 | task_lock(current); | 47 | task_lock(current); |
@@ -63,19 +63,19 @@ struct hpux_dirent { | |||
63 | }; | 63 | }; |
64 | 64 | ||
65 | struct getdents_callback { | 65 | struct getdents_callback { |
66 | struct hpux_dirent *current_dir; | 66 | struct hpux_dirent __user *current_dir; |
67 | struct hpux_dirent *previous; | 67 | struct hpux_dirent __user *previous; |
68 | int count; | 68 | int count; |
69 | int error; | 69 | int error; |
70 | }; | 70 | }; |
71 | 71 | ||
72 | #define NAME_OFFSET(de) ((int) ((de)->d_name - (char *) (de))) | 72 | #define NAME_OFFSET(de) ((int) ((de)->d_name - (char __user *) (de))) |
73 | #define ROUND_UP(x) (((x)+sizeof(long)-1) & ~(sizeof(long)-1)) | 73 | #define ROUND_UP(x) (((x)+sizeof(long)-1) & ~(sizeof(long)-1)) |
74 | 74 | ||
75 | static int filldir(void * __buf, const char * name, int namlen, loff_t offset, | 75 | static int filldir(void * __buf, const char * name, int namlen, loff_t offset, |
76 | u64 ino, unsigned d_type) | 76 | u64 ino, unsigned d_type) |
77 | { | 77 | { |
78 | struct hpux_dirent * dirent; | 78 | struct hpux_dirent __user * dirent; |
79 | struct getdents_callback * buf = (struct getdents_callback *) __buf; | 79 | struct getdents_callback * buf = (struct getdents_callback *) __buf; |
80 | ino_t d_ino; | 80 | ino_t d_ino; |
81 | int reclen = ROUND_UP(NAME_OFFSET(dirent) + namlen + 1); | 81 | int reclen = ROUND_UP(NAME_OFFSET(dirent) + namlen + 1); |
@@ -105,10 +105,10 @@ static int filldir(void * __buf, const char * name, int namlen, loff_t offset, | |||
105 | #undef NAME_OFFSET | 105 | #undef NAME_OFFSET |
106 | #undef ROUND_UP | 106 | #undef ROUND_UP |
107 | 107 | ||
108 | int hpux_getdents(unsigned int fd, struct hpux_dirent *dirent, unsigned int count) | 108 | int hpux_getdents(unsigned int fd, struct hpux_dirent __user *dirent, unsigned int count) |
109 | { | 109 | { |
110 | struct file * file; | 110 | struct file * file; |
111 | struct hpux_dirent * lastdirent; | 111 | struct hpux_dirent __user * lastdirent; |
112 | struct getdents_callback buf; | 112 | struct getdents_callback buf; |
113 | int error = -EBADF; | 113 | int error = -EBADF; |
114 | 114 | ||
@@ -143,7 +143,7 @@ int hpux_mount(const char *fs, const char *path, int mflag, | |||
143 | return -ENOSYS; | 143 | return -ENOSYS; |
144 | } | 144 | } |
145 | 145 | ||
146 | static int cp_hpux_stat(struct kstat *stat, struct hpux_stat64 *statbuf) | 146 | static int cp_hpux_stat(struct kstat *stat, struct hpux_stat64 __user *statbuf) |
147 | { | 147 | { |
148 | struct hpux_stat64 tmp; | 148 | struct hpux_stat64 tmp; |
149 | 149 | ||
@@ -169,7 +169,7 @@ static int cp_hpux_stat(struct kstat *stat, struct hpux_stat64 *statbuf) | |||
169 | return copy_to_user(statbuf,&tmp,sizeof(tmp)) ? -EFAULT : 0; | 169 | return copy_to_user(statbuf,&tmp,sizeof(tmp)) ? -EFAULT : 0; |
170 | } | 170 | } |
171 | 171 | ||
172 | long hpux_stat64(char *filename, struct hpux_stat64 *statbuf) | 172 | long hpux_stat64(char __user *filename, struct hpux_stat64 __user *statbuf) |
173 | { | 173 | { |
174 | struct kstat stat; | 174 | struct kstat stat; |
175 | int error = vfs_stat(filename, &stat); | 175 | int error = vfs_stat(filename, &stat); |
@@ -180,7 +180,7 @@ long hpux_stat64(char *filename, struct hpux_stat64 *statbuf) | |||
180 | return error; | 180 | return error; |
181 | } | 181 | } |
182 | 182 | ||
183 | long hpux_fstat64(unsigned int fd, struct hpux_stat64 *statbuf) | 183 | long hpux_fstat64(unsigned int fd, struct hpux_stat64 __user *statbuf) |
184 | { | 184 | { |
185 | struct kstat stat; | 185 | struct kstat stat; |
186 | int error = vfs_fstat(fd, &stat); | 186 | int error = vfs_fstat(fd, &stat); |
@@ -191,7 +191,7 @@ long hpux_fstat64(unsigned int fd, struct hpux_stat64 *statbuf) | |||
191 | return error; | 191 | return error; |
192 | } | 192 | } |
193 | 193 | ||
194 | long hpux_lstat64(char *filename, struct hpux_stat64 *statbuf) | 194 | long hpux_lstat64(char __user *filename, struct hpux_stat64 __user *statbuf) |
195 | { | 195 | { |
196 | struct kstat stat; | 196 | struct kstat stat; |
197 | int error = vfs_lstat(filename, &stat); | 197 | int error = vfs_lstat(filename, &stat); |
diff --git a/arch/parisc/hpux/gate.S b/arch/parisc/hpux/gate.S index aaaf3306c05a..0b9d5b1e4b37 100644 --- a/arch/parisc/hpux/gate.S +++ b/arch/parisc/hpux/gate.S | |||
@@ -12,27 +12,18 @@ | |||
12 | #include <asm/asm-offsets.h> | 12 | #include <asm/asm-offsets.h> |
13 | #include <asm/unistd.h> | 13 | #include <asm/unistd.h> |
14 | #include <asm/errno.h> | 14 | #include <asm/errno.h> |
15 | #include <linux/linkage.h> | ||
15 | 16 | ||
16 | #ifdef __LP64__ | 17 | .level LEVEL |
17 | .level 2.0w | ||
18 | #else | ||
19 | .level 1.1 | ||
20 | #endif | ||
21 | .text | 18 | .text |
22 | 19 | ||
23 | #ifdef __LP64__ | ||
24 | #define FRAME_SIZE 128 | ||
25 | #else | ||
26 | #define FRAME_SIZE 64 | ||
27 | #endif | ||
28 | .import hpux_call_table | 20 | .import hpux_call_table |
29 | .import hpux_syscall_exit,code | 21 | .import hpux_syscall_exit,code |
30 | .export hpux_gateway_page | ||
31 | 22 | ||
32 | .align 4096 | 23 | .align 4096 |
33 | hpux_gateway_page: | 24 | ENTRY(hpux_gateway_page) |
34 | nop | 25 | nop |
35 | #ifdef __LP64__ | 26 | #ifdef CONFIG_64BIT |
36 | #warning NEEDS WORK for 64-bit | 27 | #warning NEEDS WORK for 64-bit |
37 | #endif | 28 | #endif |
38 | ldw -64(%r30), %r29 ;! 8th argument | 29 | ldw -64(%r30), %r29 ;! 8th argument |
@@ -101,7 +92,7 @@ hpux_gateway_page: | |||
101 | ldo R%hpux_call_table(%r21), %r21 | 92 | ldo R%hpux_call_table(%r21), %r21 |
102 | comiclr,>>= __NR_HPUX_syscalls, %r22, %r0 | 93 | comiclr,>>= __NR_HPUX_syscalls, %r22, %r0 |
103 | b,n syscall_nosys | 94 | b,n syscall_nosys |
104 | ldwx,s %r22(%r21), %r21 | 95 | LDREGX %r22(%r21), %r21 |
105 | ldil L%hpux_syscall_exit,%r2 | 96 | ldil L%hpux_syscall_exit,%r2 |
106 | be 0(%sr7,%r21) | 97 | be 0(%sr7,%r21) |
107 | ldo R%hpux_syscall_exit(%r2),%r2 | 98 | ldo R%hpux_syscall_exit(%r2),%r2 |
@@ -110,7 +101,7 @@ syscall_nosys: | |||
110 | ldil L%hpux_syscall_exit,%r1 | 101 | ldil L%hpux_syscall_exit,%r1 |
111 | be R%hpux_syscall_exit(%sr7,%r1) | 102 | be R%hpux_syscall_exit(%sr7,%r1) |
112 | ldo -ENOSYS(%r0),%r28 | 103 | ldo -ENOSYS(%r0),%r28 |
104 | ENDPROC(hpux_gateway_page) | ||
113 | 105 | ||
114 | .align 4096 | 106 | .align 4096 |
115 | .export end_hpux_gateway_page | 107 | ENTRY(end_hpux_gateway_page) |
116 | end_hpux_gateway_page: | ||
diff --git a/arch/parisc/hpux/sys_hpux.c b/arch/parisc/hpux/sys_hpux.c index 04c2ff444396..3e025df2dc86 100644 --- a/arch/parisc/hpux/sys_hpux.c +++ b/arch/parisc/hpux/sys_hpux.c | |||
@@ -61,7 +61,7 @@ int hpux_ptrace(void) | |||
61 | return -ENOSYS; | 61 | return -ENOSYS; |
62 | } | 62 | } |
63 | 63 | ||
64 | int hpux_wait(int *stat_loc) | 64 | int hpux_wait(int __user *stat_loc) |
65 | { | 65 | { |
66 | return sys_waitpid(-1, stat_loc, 0); | 66 | return sys_waitpid(-1, stat_loc, 0); |
67 | } | 67 | } |
@@ -255,7 +255,7 @@ asmlinkage long hpux_fstatfs(unsigned int fd, struct hpux_statfs __user * buf) | |||
255 | /* TODO: Are these put_user calls OK? Should they pass an int? | 255 | /* TODO: Are these put_user calls OK? Should they pass an int? |
256 | * (I copied it from sys_i386.c like this.) | 256 | * (I copied it from sys_i386.c like this.) |
257 | */ | 257 | */ |
258 | static int hpux_uname(struct hpux_utsname *name) | 258 | static int hpux_uname(struct hpux_utsname __user *name) |
259 | { | 259 | { |
260 | int error; | 260 | int error; |
261 | 261 | ||
@@ -300,14 +300,14 @@ static int hpux_uname(struct hpux_utsname *name) | |||
300 | /* Note: HP-UX just uses the old suser() function to check perms | 300 | /* Note: HP-UX just uses the old suser() function to check perms |
301 | * in this system call. We'll use capable(CAP_SYS_ADMIN). | 301 | * in this system call. We'll use capable(CAP_SYS_ADMIN). |
302 | */ | 302 | */ |
303 | int hpux_utssys(char *ubuf, int n, int type) | 303 | int hpux_utssys(char __user *ubuf, int n, int type) |
304 | { | 304 | { |
305 | int len; | 305 | int len; |
306 | int error; | 306 | int error; |
307 | switch( type ) { | 307 | switch( type ) { |
308 | case 0: | 308 | case 0: |
309 | /* uname(): */ | 309 | /* uname(): */ |
310 | return( hpux_uname( (struct hpux_utsname *)ubuf ) ); | 310 | return hpux_uname((struct hpux_utsname __user *)ubuf); |
311 | break ; | 311 | break ; |
312 | case 1: | 312 | case 1: |
313 | /* Obsolete (used to be umask().) */ | 313 | /* Obsolete (used to be umask().) */ |
@@ -315,8 +315,9 @@ int hpux_utssys(char *ubuf, int n, int type) | |||
315 | break ; | 315 | break ; |
316 | case 2: | 316 | case 2: |
317 | /* ustat(): */ | 317 | /* ustat(): */ |
318 | return( hpux_ustat(new_decode_dev(n), (struct hpux_ustat *)ubuf) ); | 318 | return hpux_ustat(new_decode_dev(n), |
319 | break ; | 319 | (struct hpux_ustat __user *)ubuf); |
320 | break; | ||
320 | case 3: | 321 | case 3: |
321 | /* setuname(): | 322 | /* setuname(): |
322 | * | 323 | * |
@@ -332,7 +333,7 @@ int hpux_utssys(char *ubuf, int n, int type) | |||
332 | return -EINVAL ; | 333 | return -EINVAL ; |
333 | /* Unlike Linux, HP-UX truncates it if n is too big: */ | 334 | /* Unlike Linux, HP-UX truncates it if n is too big: */ |
334 | len = (n <= __NEW_UTS_LEN) ? n : __NEW_UTS_LEN ; | 335 | len = (n <= __NEW_UTS_LEN) ? n : __NEW_UTS_LEN ; |
335 | return( sys_sethostname(ubuf, len) ); | 336 | return sys_sethostname(ubuf, len); |
336 | break ; | 337 | break ; |
337 | case 4: | 338 | case 4: |
338 | /* sethostname(): | 339 | /* sethostname(): |
@@ -346,7 +347,7 @@ int hpux_utssys(char *ubuf, int n, int type) | |||
346 | return -EINVAL ; | 347 | return -EINVAL ; |
347 | /* Unlike Linux, HP-UX truncates it if n is too big: */ | 348 | /* Unlike Linux, HP-UX truncates it if n is too big: */ |
348 | len = (n <= __NEW_UTS_LEN) ? n : __NEW_UTS_LEN ; | 349 | len = (n <= __NEW_UTS_LEN) ? n : __NEW_UTS_LEN ; |
349 | return( sys_sethostname(ubuf, len) ); | 350 | return sys_sethostname(ubuf, len); |
350 | break ; | 351 | break ; |
351 | case 5: | 352 | case 5: |
352 | /* gethostname(): | 353 | /* gethostname(): |
@@ -356,7 +357,7 @@ int hpux_utssys(char *ubuf, int n, int type) | |||
356 | /* Unlike Linux, HP-UX returns an error if n==0: */ | 357 | /* Unlike Linux, HP-UX returns an error if n==0: */ |
357 | if ( n <= 0 ) | 358 | if ( n <= 0 ) |
358 | return -EINVAL ; | 359 | return -EINVAL ; |
359 | return( sys_gethostname(ubuf, n) ); | 360 | return sys_gethostname(ubuf, n); |
360 | break ; | 361 | break ; |
361 | case 6: | 362 | case 6: |
362 | /* Supposedly called from setuname() in libc. | 363 | /* Supposedly called from setuname() in libc. |
@@ -420,7 +421,7 @@ int hpux_utssys(char *ubuf, int n, int type) | |||
420 | } | 421 | } |
421 | } | 422 | } |
422 | 423 | ||
423 | int hpux_getdomainname(char *name, int len) | 424 | int hpux_getdomainname(char __user *name, int len) |
424 | { | 425 | { |
425 | int nlen; | 426 | int nlen; |
426 | int err = -EFAULT; | 427 | int err = -EFAULT; |
@@ -471,17 +472,18 @@ int hpux_sysfs(int opcode, unsigned long arg1, unsigned long arg2) | |||
471 | printk(KERN_DEBUG "hpux_sysfs called with arg1='%lx'\n", arg1); | 472 | printk(KERN_DEBUG "hpux_sysfs called with arg1='%lx'\n", arg1); |
472 | 473 | ||
473 | if ( opcode == 1 ) { /* GETFSIND */ | 474 | if ( opcode == 1 ) { /* GETFSIND */ |
474 | len = strlen_user((char *)arg1); | 475 | char __user *user_fsname = (char __user *)arg1; |
476 | len = strlen_user(user_fsname); | ||
475 | printk(KERN_DEBUG "len of arg1 = %d\n", len); | 477 | printk(KERN_DEBUG "len of arg1 = %d\n", len); |
476 | if (len == 0) | 478 | if (len == 0) |
477 | return 0; | 479 | return 0; |
478 | fsname = kmalloc(len, GFP_KERNEL); | 480 | fsname = kmalloc(len, GFP_KERNEL); |
479 | if ( !fsname ) { | 481 | if (!fsname) { |
480 | printk(KERN_DEBUG "failed to kmalloc fsname\n"); | 482 | printk(KERN_DEBUG "failed to kmalloc fsname\n"); |
481 | return 0; | 483 | return 0; |
482 | } | 484 | } |
483 | 485 | ||
484 | if ( copy_from_user(fsname, (char *)arg1, len) ) { | 486 | if (copy_from_user(fsname, user_fsname, len)) { |
485 | printk(KERN_DEBUG "failed to copy_from_user fsname\n"); | 487 | printk(KERN_DEBUG "failed to copy_from_user fsname\n"); |
486 | kfree(fsname); | 488 | kfree(fsname); |
487 | return 0; | 489 | return 0; |
@@ -495,7 +497,7 @@ int hpux_sysfs(int opcode, unsigned long arg1, unsigned long arg2) | |||
495 | fstype = 0; | 497 | fstype = 0; |
496 | } else { | 498 | } else { |
497 | fstype = 0; | 499 | fstype = 0; |
498 | }; | 500 | } |
499 | 501 | ||
500 | kfree(fsname); | 502 | kfree(fsname); |
501 | 503 | ||
@@ -509,7 +511,7 @@ int hpux_sysfs(int opcode, unsigned long arg1, unsigned long arg2) | |||
509 | 511 | ||
510 | 512 | ||
511 | /* Table of syscall names and handle for unimplemented routines */ | 513 | /* Table of syscall names and handle for unimplemented routines */ |
512 | static const char *syscall_names[] = { | 514 | static const char * const syscall_names[] = { |
513 | "nosys", /* 0 */ | 515 | "nosys", /* 0 */ |
514 | "exit", | 516 | "exit", |
515 | "fork", | 517 | "fork", |
diff --git a/arch/parisc/hpux/wrappers.S b/arch/parisc/hpux/wrappers.S index 0b0c3a66b1be..58c53c879c02 100644 --- a/arch/parisc/hpux/wrappers.S +++ b/arch/parisc/hpux/wrappers.S | |||
@@ -20,19 +20,16 @@ | |||
20 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | 20 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
21 | */ | 21 | */ |
22 | 22 | ||
23 | #ifdef __LP64__ | 23 | #ifdef CONFIG_64BIT |
24 | #warning PA64 support needs more work...did first cut | 24 | #warning PA64 support needs more work...did first cut |
25 | #endif | 25 | #endif |
26 | 26 | ||
27 | #include <asm/asm-offsets.h> | 27 | #include <asm/asm-offsets.h> |
28 | #include <asm/assembly.h> | 28 | #include <asm/assembly.h> |
29 | #include <asm/signal.h> | 29 | #include <asm/signal.h> |
30 | #include <linux/linkage.h> | ||
30 | 31 | ||
31 | #ifdef __LP64__ | 32 | .level LEVEL |
32 | .level 2.0w | ||
33 | #else | ||
34 | .level 1.1 | ||
35 | #endif | ||
36 | .text | 33 | .text |
37 | 34 | ||
38 | /* These should probably go in a header file somewhere. | 35 | /* These should probably go in a header file somewhere. |
@@ -41,7 +38,7 @@ | |||
41 | * register save/restore macros. | 38 | * register save/restore macros. |
42 | */ | 39 | */ |
43 | .macro reg_save regs | 40 | .macro reg_save regs |
44 | #ifdef __LP64__ | 41 | #ifdef CONFIG_64BIT |
45 | #warning NEEDS WORK for 64-bit | 42 | #warning NEEDS WORK for 64-bit |
46 | #endif | 43 | #endif |
47 | STREG %r3, PT_GR3(\regs) | 44 | STREG %r3, PT_GR3(\regs) |
@@ -82,11 +79,9 @@ | |||
82 | .endm | 79 | .endm |
83 | 80 | ||
84 | 81 | ||
85 | .export hpux_fork_wrapper | ||
86 | .export hpux_child_return | ||
87 | .import sys_fork | 82 | .import sys_fork |
88 | 83 | ||
89 | hpux_fork_wrapper: | 84 | ENTRY(hpux_fork_wrapper) |
90 | ldo TASK_REGS-TASK_SZ_ALGN-64(%r30),%r1 ;! get pt regs | 85 | ldo TASK_REGS-TASK_SZ_ALGN-64(%r30),%r1 ;! get pt regs |
91 | ;! pointer in task | 86 | ;! pointer in task |
92 | reg_save %r1 | 87 | reg_save %r1 |
@@ -128,27 +123,26 @@ fork_return: | |||
128 | fork_exit: | 123 | fork_exit: |
129 | bv %r0(%r2) | 124 | bv %r0(%r2) |
130 | nop | 125 | nop |
126 | ENDPROC(hpux_fork_wrapper) | ||
131 | 127 | ||
132 | /* Set the return value for the child */ | 128 | /* Set the return value for the child */ |
133 | 129 | ||
134 | hpux_child_return: | 130 | ENTRY(hpux_child_return) |
135 | #if defined(CONFIG_SMP) || defined(CONFIG_PREEMPT) | 131 | #if defined(CONFIG_SMP) || defined(CONFIG_PREEMPT) |
136 | bl schedule_tail, %r2 | 132 | bl,n schedule_tail, %r2 |
137 | nop | ||
138 | #endif | 133 | #endif |
139 | 134 | ||
140 | LDREG TASK_PT_GR19-TASK_SZ_ALGN-128(%r30),%r2 | 135 | LDREG TASK_PT_GR19-TASK_SZ_ALGN-128(%r30),%r2 |
141 | b fork_return | 136 | b fork_return |
142 | copy %r0,%r28 | 137 | copy %r0,%r28 |
138 | ENDPROC(hpux_child_return) | ||
143 | 139 | ||
144 | .export hpux_execve_wrapper | ||
145 | .export hpux_execv_wrapper | ||
146 | .import hpux_execve | 140 | .import hpux_execve |
147 | 141 | ||
148 | hpux_execv_wrapper: | 142 | ENTRY(hpux_execv_wrapper) |
149 | copy %r0,%r24 /* NULL environment */ | 143 | copy %r0,%r24 /* NULL environment */ |
150 | 144 | ||
151 | hpux_execve_wrapper: | 145 | ENTRY(hpux_execve_wrapper) |
152 | 146 | ||
153 | ldo TASK_REGS-TASK_SZ_ALGN-64(%r30),%r1 ;! get pt regs | 147 | ldo TASK_REGS-TASK_SZ_ALGN-64(%r30),%r1 ;! get pt regs |
154 | 148 | ||
@@ -187,13 +181,13 @@ hpux_execve_wrapper: | |||
187 | exec_error: | 181 | exec_error: |
188 | bv %r0(%r19) | 182 | bv %r0(%r19) |
189 | nop | 183 | nop |
184 | ENDPROC(hpux_execv_wrapper) | ||
190 | 185 | ||
191 | .export hpux_pipe_wrapper | ||
192 | .import hpux_pipe | 186 | .import hpux_pipe |
193 | 187 | ||
194 | /* HP-UX expects pipefd's returned in r28 & r29 */ | 188 | /* HP-UX expects pipefd's returned in r28 & r29 */ |
195 | 189 | ||
196 | hpux_pipe_wrapper: | 190 | ENTRY(hpux_pipe_wrapper) |
197 | STREG %r2,-20(%r30) | 191 | STREG %r2,-20(%r30) |
198 | ldo 64(%r30),%r30 | 192 | ldo 64(%r30),%r30 |
199 | bl hpux_pipe,%r2 | 193 | bl hpux_pipe,%r2 |
@@ -212,12 +206,11 @@ hpux_pipe_wrapper: | |||
212 | pipe_exit: | 206 | pipe_exit: |
213 | bv %r0(%r2) | 207 | bv %r0(%r2) |
214 | ldo -64(%r30),%r30 | 208 | ldo -64(%r30),%r30 |
209 | ENDPROC(hpux_pipe_wrapper) | ||
215 | 210 | ||
216 | .export hpux_syscall_exit | ||
217 | .import syscall_exit | 211 | .import syscall_exit |
218 | 212 | ||
219 | hpux_syscall_exit: | 213 | ENTRY(hpux_syscall_exit) |
220 | |||
221 | /* | 214 | /* |
222 | * | 215 | * |
223 | * HP-UX call return conventions: | 216 | * HP-UX call return conventions: |
@@ -246,12 +239,12 @@ hpux_syscall_exit: | |||
246 | ldo 1(%r0),%r22 | 239 | ldo 1(%r0),%r22 |
247 | 240 | ||
248 | no_error: | 241 | no_error: |
249 | b syscall_exit | 242 | b,n syscall_exit |
250 | nop | 243 | ENDPROC(hpux_syscall_exit) |
251 | 244 | ||
252 | .export hpux_unimplemented_wrapper | ||
253 | .import hpux_unimplemented | 245 | .import hpux_unimplemented |
254 | 246 | ||
255 | hpux_unimplemented_wrapper: | 247 | ENTRY(hpux_unimplemented_wrapper) |
256 | b hpux_unimplemented | 248 | b hpux_unimplemented |
257 | STREG %r22,-64(%r30) /* overwrite arg8 with syscall number */ | 249 | STREG %r22,-64(%r30) /* overwrite arg8 with syscall number */ |
250 | ENDPROC(hpux_unimplemented_wrapper) | ||
diff --git a/arch/parisc/kernel/asm-offsets.c b/arch/parisc/kernel/asm-offsets.c index c11a5bc7c067..54fdb959149c 100644 --- a/arch/parisc/kernel/asm-offsets.c +++ b/arch/parisc/kernel/asm-offsets.c | |||
@@ -44,7 +44,7 @@ | |||
44 | 44 | ||
45 | #define BLANK() asm volatile("\n->" : : ) | 45 | #define BLANK() asm volatile("\n->" : : ) |
46 | 46 | ||
47 | #ifdef __LP64__ | 47 | #ifdef CONFIG_64BIT |
48 | #define FRAME_SIZE 128 | 48 | #define FRAME_SIZE 128 |
49 | #else | 49 | #else |
50 | #define FRAME_SIZE 64 | 50 | #define FRAME_SIZE 64 |
diff --git a/arch/parisc/kernel/cache.c b/arch/parisc/kernel/cache.c index 0be51e92a2fc..0dc924ccceb5 100644 --- a/arch/parisc/kernel/cache.c +++ b/arch/parisc/kernel/cache.c | |||
@@ -68,16 +68,6 @@ flush_cache_all_local(void) | |||
68 | } | 68 | } |
69 | EXPORT_SYMBOL(flush_cache_all_local); | 69 | EXPORT_SYMBOL(flush_cache_all_local); |
70 | 70 | ||
71 | /* flushes EVERYTHING (tlb & cache) */ | ||
72 | |||
73 | void | ||
74 | flush_all_caches(void) | ||
75 | { | ||
76 | flush_cache_all(); | ||
77 | flush_tlb_all(); | ||
78 | } | ||
79 | EXPORT_SYMBOL(flush_all_caches); | ||
80 | |||
81 | void | 71 | void |
82 | update_mmu_cache(struct vm_area_struct *vma, unsigned long address, pte_t pte) | 72 | update_mmu_cache(struct vm_area_struct *vma, unsigned long address, pte_t pte) |
83 | { | 73 | { |
@@ -99,7 +89,7 @@ show_cache_info(struct seq_file *m) | |||
99 | 89 | ||
100 | seq_printf(m, "I-cache\t\t: %ld KB\n", | 90 | seq_printf(m, "I-cache\t\t: %ld KB\n", |
101 | cache_info.ic_size/1024 ); | 91 | cache_info.ic_size/1024 ); |
102 | if (cache_info.dc_loop == 1) | 92 | if (cache_info.dc_loop != 1) |
103 | snprintf(buf, 32, "%lu-way associative", cache_info.dc_loop); | 93 | snprintf(buf, 32, "%lu-way associative", cache_info.dc_loop); |
104 | seq_printf(m, "D-cache\t\t: %ld KB (%s%s, %s)\n", | 94 | seq_printf(m, "D-cache\t\t: %ld KB (%s%s, %s)\n", |
105 | cache_info.dc_size/1024, | 95 | cache_info.dc_size/1024, |
@@ -270,6 +260,83 @@ void disable_sr_hashing(void) | |||
270 | panic("SpaceID hashing is still on!\n"); | 260 | panic("SpaceID hashing is still on!\n"); |
271 | } | 261 | } |
272 | 262 | ||
263 | /* Simple function to work out if we have an existing address translation | ||
264 | * for a user space vma. */ | ||
265 | static inline int translation_exists(struct vm_area_struct *vma, | ||
266 | unsigned long addr, unsigned long pfn) | ||
267 | { | ||
268 | pgd_t *pgd = pgd_offset(vma->vm_mm, addr); | ||
269 | pmd_t *pmd; | ||
270 | pte_t pte; | ||
271 | |||
272 | if(pgd_none(*pgd)) | ||
273 | return 0; | ||
274 | |||
275 | pmd = pmd_offset(pgd, addr); | ||
276 | if(pmd_none(*pmd) || pmd_bad(*pmd)) | ||
277 | return 0; | ||
278 | |||
279 | /* We cannot take the pte lock here: flush_cache_page is usually | ||
280 | * called with pte lock already held. Whereas flush_dcache_page | ||
281 | * takes flush_dcache_mmap_lock, which is lower in the hierarchy: | ||
282 | * the vma itself is secure, but the pte might come or go racily. | ||
283 | */ | ||
284 | pte = *pte_offset_map(pmd, addr); | ||
285 | /* But pte_unmap() does nothing on this architecture */ | ||
286 | |||
287 | /* Filter out coincidental file entries and swap entries */ | ||
288 | if (!(pte_val(pte) & (_PAGE_FLUSH|_PAGE_PRESENT))) | ||
289 | return 0; | ||
290 | |||
291 | return pte_pfn(pte) == pfn; | ||
292 | } | ||
293 | |||
294 | /* Private function to flush a page from the cache of a non-current | ||
295 | * process. cr25 contains the Page Directory of the current user | ||
296 | * process; we're going to hijack both it and the user space %sr3 to | ||
297 | * temporarily make the non-current process current. We have to do | ||
298 | * this because cache flushing may cause a non-access tlb miss which | ||
299 | * the handlers have to fill in from the pgd of the non-current | ||
300 | * process. */ | ||
301 | static inline void | ||
302 | flush_user_cache_page_non_current(struct vm_area_struct *vma, | ||
303 | unsigned long vmaddr) | ||
304 | { | ||
305 | /* save the current process space and pgd */ | ||
306 | unsigned long space = mfsp(3), pgd = mfctl(25); | ||
307 | |||
308 | /* we don't mind taking interrups since they may not | ||
309 | * do anything with user space, but we can't | ||
310 | * be preempted here */ | ||
311 | preempt_disable(); | ||
312 | |||
313 | /* make us current */ | ||
314 | mtctl(__pa(vma->vm_mm->pgd), 25); | ||
315 | mtsp(vma->vm_mm->context, 3); | ||
316 | |||
317 | flush_user_dcache_page(vmaddr); | ||
318 | if(vma->vm_flags & VM_EXEC) | ||
319 | flush_user_icache_page(vmaddr); | ||
320 | |||
321 | /* put the old current process back */ | ||
322 | mtsp(space, 3); | ||
323 | mtctl(pgd, 25); | ||
324 | preempt_enable(); | ||
325 | } | ||
326 | |||
327 | |||
328 | static inline void | ||
329 | __flush_cache_page(struct vm_area_struct *vma, unsigned long vmaddr) | ||
330 | { | ||
331 | if (likely(vma->vm_mm->context == mfsp(3))) { | ||
332 | flush_user_dcache_page(vmaddr); | ||
333 | if (vma->vm_flags & VM_EXEC) | ||
334 | flush_user_icache_page(vmaddr); | ||
335 | } else { | ||
336 | flush_user_cache_page_non_current(vma, vmaddr); | ||
337 | } | ||
338 | } | ||
339 | |||
273 | void flush_dcache_page(struct page *page) | 340 | void flush_dcache_page(struct page *page) |
274 | { | 341 | { |
275 | struct address_space *mapping = page_mapping(page); | 342 | struct address_space *mapping = page_mapping(page); |
@@ -342,7 +409,7 @@ void clear_user_page_asm(void *page, unsigned long vaddr) | |||
342 | #define FLUSH_THRESHOLD 0x80000 /* 0.5MB */ | 409 | #define FLUSH_THRESHOLD 0x80000 /* 0.5MB */ |
343 | int parisc_cache_flush_threshold __read_mostly = FLUSH_THRESHOLD; | 410 | int parisc_cache_flush_threshold __read_mostly = FLUSH_THRESHOLD; |
344 | 411 | ||
345 | void parisc_setup_cache_timing(void) | 412 | void __init parisc_setup_cache_timing(void) |
346 | { | 413 | { |
347 | unsigned long rangetime, alltime; | 414 | unsigned long rangetime, alltime; |
348 | unsigned long size; | 415 | unsigned long size; |
@@ -366,6 +433,9 @@ void parisc_setup_cache_timing(void) | |||
366 | if (!parisc_cache_flush_threshold) | 433 | if (!parisc_cache_flush_threshold) |
367 | parisc_cache_flush_threshold = FLUSH_THRESHOLD; | 434 | parisc_cache_flush_threshold = FLUSH_THRESHOLD; |
368 | 435 | ||
436 | if (parisc_cache_flush_threshold > cache_info.dc_size) | ||
437 | parisc_cache_flush_threshold = cache_info.dc_size; | ||
438 | |||
369 | printk(KERN_INFO "Setting cache flush threshold to %x (%d CPUs online)\n", parisc_cache_flush_threshold, num_online_cpus()); | 439 | printk(KERN_INFO "Setting cache flush threshold to %x (%d CPUs online)\n", parisc_cache_flush_threshold, num_online_cpus()); |
370 | } | 440 | } |
371 | 441 | ||
@@ -410,3 +480,97 @@ void kunmap_parisc(void *addr) | |||
410 | } | 480 | } |
411 | EXPORT_SYMBOL(kunmap_parisc); | 481 | EXPORT_SYMBOL(kunmap_parisc); |
412 | #endif | 482 | #endif |
483 | |||
484 | void __flush_tlb_range(unsigned long sid, unsigned long start, | ||
485 | unsigned long end) | ||
486 | { | ||
487 | unsigned long npages; | ||
488 | |||
489 | npages = ((end - (start & PAGE_MASK)) + (PAGE_SIZE - 1)) >> PAGE_SHIFT; | ||
490 | if (npages >= 512) /* 2MB of space: arbitrary, should be tuned */ | ||
491 | flush_tlb_all(); | ||
492 | else { | ||
493 | mtsp(sid, 1); | ||
494 | purge_tlb_start(); | ||
495 | if (split_tlb) { | ||
496 | while (npages--) { | ||
497 | pdtlb(start); | ||
498 | pitlb(start); | ||
499 | start += PAGE_SIZE; | ||
500 | } | ||
501 | } else { | ||
502 | while (npages--) { | ||
503 | pdtlb(start); | ||
504 | start += PAGE_SIZE; | ||
505 | } | ||
506 | } | ||
507 | purge_tlb_end(); | ||
508 | } | ||
509 | } | ||
510 | |||
511 | static void cacheflush_h_tmp_function(void *dummy) | ||
512 | { | ||
513 | flush_cache_all_local(); | ||
514 | } | ||
515 | |||
516 | void flush_cache_all(void) | ||
517 | { | ||
518 | on_each_cpu(cacheflush_h_tmp_function, NULL, 1, 1); | ||
519 | } | ||
520 | |||
521 | void flush_cache_mm(struct mm_struct *mm) | ||
522 | { | ||
523 | #ifdef CONFIG_SMP | ||
524 | flush_cache_all(); | ||
525 | #else | ||
526 | flush_cache_all_local(); | ||
527 | #endif | ||
528 | } | ||
529 | |||
530 | void | ||
531 | flush_user_dcache_range(unsigned long start, unsigned long end) | ||
532 | { | ||
533 | if ((end - start) < parisc_cache_flush_threshold) | ||
534 | flush_user_dcache_range_asm(start,end); | ||
535 | else | ||
536 | flush_data_cache(); | ||
537 | } | ||
538 | |||
539 | void | ||
540 | flush_user_icache_range(unsigned long start, unsigned long end) | ||
541 | { | ||
542 | if ((end - start) < parisc_cache_flush_threshold) | ||
543 | flush_user_icache_range_asm(start,end); | ||
544 | else | ||
545 | flush_instruction_cache(); | ||
546 | } | ||
547 | |||
548 | |||
549 | void flush_cache_range(struct vm_area_struct *vma, | ||
550 | unsigned long start, unsigned long end) | ||
551 | { | ||
552 | int sr3; | ||
553 | |||
554 | if (!vma->vm_mm->context) { | ||
555 | BUG(); | ||
556 | return; | ||
557 | } | ||
558 | |||
559 | sr3 = mfsp(3); | ||
560 | if (vma->vm_mm->context == sr3) { | ||
561 | flush_user_dcache_range(start,end); | ||
562 | flush_user_icache_range(start,end); | ||
563 | } else { | ||
564 | flush_cache_all(); | ||
565 | } | ||
566 | } | ||
567 | |||
568 | void | ||
569 | flush_cache_page(struct vm_area_struct *vma, unsigned long vmaddr, unsigned long pfn) | ||
570 | { | ||
571 | BUG_ON(!vma->vm_mm->context); | ||
572 | |||
573 | if (likely(translation_exists(vma, vmaddr, pfn))) | ||
574 | __flush_cache_page(vma, vmaddr); | ||
575 | |||
576 | } | ||
diff --git a/arch/parisc/kernel/drivers.c b/arch/parisc/kernel/drivers.c index d6c486e9501c..2ca654bd6322 100644 --- a/arch/parisc/kernel/drivers.c +++ b/arch/parisc/kernel/drivers.c | |||
@@ -562,12 +562,23 @@ pa_dev_attr(rev, id.hversion_rev, "0x%x\n"); | |||
562 | pa_dev_attr_id(hversion, "0x%03x\n"); | 562 | pa_dev_attr_id(hversion, "0x%03x\n"); |
563 | pa_dev_attr_id(sversion, "0x%05x\n"); | 563 | pa_dev_attr_id(sversion, "0x%05x\n"); |
564 | 564 | ||
565 | static ssize_t modalias_show(struct device *dev, struct device_attribute *attr, char *buf) | ||
566 | { | ||
567 | struct parisc_device *padev = to_parisc_device(dev); | ||
568 | struct parisc_device_id *id = &padev->id; | ||
569 | |||
570 | return sprintf(buf, "parisc:t%02Xhv%04Xrev%02Xsv%08X\n", | ||
571 | (u8)id->hw_type, (u16)id->hversion, (u8)id->hversion_rev, | ||
572 | (u32)id->sversion); | ||
573 | } | ||
574 | |||
565 | static struct device_attribute parisc_device_attrs[] = { | 575 | static struct device_attribute parisc_device_attrs[] = { |
566 | __ATTR_RO(irq), | 576 | __ATTR_RO(irq), |
567 | __ATTR_RO(hw_type), | 577 | __ATTR_RO(hw_type), |
568 | __ATTR_RO(rev), | 578 | __ATTR_RO(rev), |
569 | __ATTR_RO(hversion), | 579 | __ATTR_RO(hversion), |
570 | __ATTR_RO(sversion), | 580 | __ATTR_RO(sversion), |
581 | __ATTR_RO(modalias), | ||
571 | __ATTR_NULL, | 582 | __ATTR_NULL, |
572 | }; | 583 | }; |
573 | 584 | ||
@@ -689,7 +700,9 @@ parse_tree_node(struct device *parent, int index, struct hardware_path *modpath) | |||
689 | .fn = check_parent, | 700 | .fn = check_parent, |
690 | }; | 701 | }; |
691 | 702 | ||
692 | device_for_each_child(parent, &recurse_data, descend_children); | 703 | if (device_for_each_child(parent, &recurse_data, descend_children)) |
704 | /* nothing */; | ||
705 | |||
693 | return d.dev; | 706 | return d.dev; |
694 | } | 707 | } |
695 | 708 | ||
@@ -835,8 +848,8 @@ static void print_parisc_device(struct parisc_device *dev) | |||
835 | static int count; | 848 | static int count; |
836 | 849 | ||
837 | print_pa_hwpath(dev, hw_path); | 850 | print_pa_hwpath(dev, hw_path); |
838 | printk(KERN_INFO "%d. %s at 0x%lx [%s] { %d, 0x%x, 0x%.3x, 0x%.5x }", | 851 | printk(KERN_INFO "%d. %s at 0x%p [%s] { %d, 0x%x, 0x%.3x, 0x%.5x }", |
839 | ++count, dev->name, dev->hpa.start, hw_path, dev->id.hw_type, | 852 | ++count, dev->name, (void*) dev->hpa.start, hw_path, dev->id.hw_type, |
840 | dev->id.hversion_rev, dev->id.hversion, dev->id.sversion); | 853 | dev->id.hversion_rev, dev->id.hversion, dev->id.sversion); |
841 | 854 | ||
842 | if (dev->num_addrs) { | 855 | if (dev->num_addrs) { |
diff --git a/arch/parisc/kernel/entry.S b/arch/parisc/kernel/entry.S index 340b5e8d67ba..8474f9e5ca10 100644 --- a/arch/parisc/kernel/entry.S +++ b/arch/parisc/kernel/entry.S | |||
@@ -37,6 +37,8 @@ | |||
37 | #include <asm/unistd.h> | 37 | #include <asm/unistd.h> |
38 | #include <asm/thread_info.h> | 38 | #include <asm/thread_info.h> |
39 | 39 | ||
40 | #include <linux/linkage.h> | ||
41 | |||
40 | #ifdef CONFIG_64BIT | 42 | #ifdef CONFIG_64BIT |
41 | #define CMPIB cmpib,* | 43 | #define CMPIB cmpib,* |
42 | #define CMPB cmpb,* | 44 | #define CMPB cmpb,* |
@@ -648,13 +650,11 @@ | |||
648 | * the static part of the kernel address space. | 650 | * the static part of the kernel address space. |
649 | */ | 651 | */ |
650 | 652 | ||
651 | .export fault_vector_20 | ||
652 | |||
653 | .text | 653 | .text |
654 | 654 | ||
655 | .align 4096 | 655 | .align 4096 |
656 | 656 | ||
657 | fault_vector_20: | 657 | ENTRY(fault_vector_20) |
658 | /* First vector is invalid (0) */ | 658 | /* First vector is invalid (0) */ |
659 | .ascii "cows can fly" | 659 | .ascii "cows can fly" |
660 | .byte 0 | 660 | .byte 0 |
@@ -695,14 +695,13 @@ fault_vector_20: | |||
695 | def 29 | 695 | def 29 |
696 | def 30 | 696 | def 30 |
697 | def 31 | 697 | def 31 |
698 | END(fault_vector_20) | ||
698 | 699 | ||
699 | #ifndef CONFIG_64BIT | 700 | #ifndef CONFIG_64BIT |
700 | 701 | ||
701 | .export fault_vector_11 | ||
702 | |||
703 | .align 2048 | 702 | .align 2048 |
704 | 703 | ||
705 | fault_vector_11: | 704 | ENTRY(fault_vector_11) |
706 | /* First vector is invalid (0) */ | 705 | /* First vector is invalid (0) */ |
707 | .ascii "cows can fly" | 706 | .ascii "cows can fly" |
708 | .byte 0 | 707 | .byte 0 |
@@ -743,6 +742,7 @@ fault_vector_11: | |||
743 | def 29 | 742 | def 29 |
744 | def 30 | 743 | def 30 |
745 | def 31 | 744 | def 31 |
745 | END(fault_vector_11) | ||
746 | 746 | ||
747 | #endif | 747 | #endif |
748 | 748 | ||
@@ -762,9 +762,8 @@ fault_vector_11: | |||
762 | #define CLONE_VM 0x100 /* Must agree with <linux/sched.h> */ | 762 | #define CLONE_VM 0x100 /* Must agree with <linux/sched.h> */ |
763 | #define CLONE_UNTRACED 0x00800000 | 763 | #define CLONE_UNTRACED 0x00800000 |
764 | 764 | ||
765 | .export __kernel_thread, code | ||
766 | .import do_fork | 765 | .import do_fork |
767 | __kernel_thread: | 766 | ENTRY(__kernel_thread) |
768 | STREG %r2, -RP_OFFSET(%r30) | 767 | STREG %r2, -RP_OFFSET(%r30) |
769 | 768 | ||
770 | copy %r30, %r1 | 769 | copy %r30, %r1 |
@@ -797,6 +796,7 @@ __kernel_thread: | |||
797 | ldo -PT_SZ_ALGN(%r30), %r30 | 796 | ldo -PT_SZ_ALGN(%r30), %r30 |
798 | bv %r0(%r2) | 797 | bv %r0(%r2) |
799 | nop | 798 | nop |
799 | ENDPROC(__kernel_thread) | ||
800 | 800 | ||
801 | /* | 801 | /* |
802 | * Child Returns here | 802 | * Child Returns here |
@@ -805,8 +805,7 @@ __kernel_thread: | |||
805 | * into task save area. | 805 | * into task save area. |
806 | */ | 806 | */ |
807 | 807 | ||
808 | .export ret_from_kernel_thread | 808 | ENTRY(ret_from_kernel_thread) |
809 | ret_from_kernel_thread: | ||
810 | 809 | ||
811 | /* Call schedule_tail first though */ | 810 | /* Call schedule_tail first though */ |
812 | BL schedule_tail, %r2 | 811 | BL schedule_tail, %r2 |
@@ -833,10 +832,10 @@ ret_from_kernel_thread: | |||
833 | bv %r0(%r1) | 832 | bv %r0(%r1) |
834 | #endif | 833 | #endif |
835 | ldi 0, %r26 | 834 | ldi 0, %r26 |
835 | ENDPROC(ret_from_kernel_thread) | ||
836 | 836 | ||
837 | .import sys_execve, code | 837 | .import sys_execve, code |
838 | .export __execve, code | 838 | ENTRY(__execve) |
839 | __execve: | ||
840 | copy %r2, %r15 | 839 | copy %r2, %r15 |
841 | copy %r30, %r16 | 840 | copy %r30, %r16 |
842 | ldo PT_SZ_ALGN(%r30), %r30 | 841 | ldo PT_SZ_ALGN(%r30), %r30 |
@@ -856,16 +855,15 @@ __execve: | |||
856 | copy %r16, %r30 | 855 | copy %r16, %r30 |
857 | bv %r0(%r2) | 856 | bv %r0(%r2) |
858 | nop | 857 | nop |
858 | ENDPROC(__execve) | ||
859 | 859 | ||
860 | .align 4 | ||
861 | 860 | ||
862 | /* | 861 | /* |
863 | * struct task_struct *_switch_to(struct task_struct *prev, | 862 | * struct task_struct *_switch_to(struct task_struct *prev, |
864 | * struct task_struct *next) | 863 | * struct task_struct *next) |
865 | * | 864 | * |
866 | * switch kernel stacks and return prev */ | 865 | * switch kernel stacks and return prev */ |
867 | .export _switch_to, code | 866 | ENTRY(_switch_to) |
868 | _switch_to: | ||
869 | STREG %r2, -RP_OFFSET(%r30) | 867 | STREG %r2, -RP_OFFSET(%r30) |
870 | 868 | ||
871 | callee_save_float | 869 | callee_save_float |
@@ -890,6 +888,7 @@ _switch_to_ret: | |||
890 | LDREG -RP_OFFSET(%r30), %r2 | 888 | LDREG -RP_OFFSET(%r30), %r2 |
891 | bv %r0(%r2) | 889 | bv %r0(%r2) |
892 | copy %r26, %r28 | 890 | copy %r26, %r28 |
891 | ENDPROC(_switch_to) | ||
893 | 892 | ||
894 | /* | 893 | /* |
895 | * Common rfi return path for interruptions, kernel execve, and | 894 | * Common rfi return path for interruptions, kernel execve, and |
@@ -907,8 +906,7 @@ _switch_to_ret: | |||
907 | 906 | ||
908 | .align 4096 | 907 | .align 4096 |
909 | 908 | ||
910 | .export syscall_exit_rfi | 909 | ENTRY(syscall_exit_rfi) |
911 | syscall_exit_rfi: | ||
912 | mfctl %cr30,%r16 | 910 | mfctl %cr30,%r16 |
913 | LDREG TI_TASK(%r16), %r16 /* thread_info -> task_struct */ | 911 | LDREG TI_TASK(%r16), %r16 /* thread_info -> task_struct */ |
914 | ldo TASK_REGS(%r16),%r16 | 912 | ldo TASK_REGS(%r16),%r16 |
@@ -978,11 +976,36 @@ intr_check_resched: | |||
978 | LDREG TI_FLAGS(%r1),%r19 /* sched.h: TIF_NEED_RESCHED */ | 976 | LDREG TI_FLAGS(%r1),%r19 /* sched.h: TIF_NEED_RESCHED */ |
979 | bb,<,n %r19,31-TIF_NEED_RESCHED,intr_do_resched /* forward */ | 977 | bb,<,n %r19,31-TIF_NEED_RESCHED,intr_do_resched /* forward */ |
980 | 978 | ||
979 | .import do_notify_resume,code | ||
981 | intr_check_sig: | 980 | intr_check_sig: |
982 | /* As above */ | 981 | /* As above */ |
983 | mfctl %cr30,%r1 | 982 | mfctl %cr30,%r1 |
984 | LDREG TI_FLAGS(%r1),%r19 /* sched.h: TIF_SIGPENDING */ | 983 | LDREG TI_FLAGS(%r1),%r19 |
985 | bb,<,n %r19, 31-TIF_SIGPENDING, intr_do_signal /* forward */ | 984 | ldi (_TIF_SIGPENDING|_TIF_RESTORE_SIGMASK), %r20 |
985 | and,COND(<>) %r19, %r20, %r0 | ||
986 | b,n intr_restore /* skip past if we've nothing to do */ | ||
987 | |||
988 | /* This check is critical to having LWS | ||
989 | * working. The IASQ is zero on the gateway | ||
990 | * page and we cannot deliver any signals until | ||
991 | * we get off the gateway page. | ||
992 | * | ||
993 | * Only do signals if we are returning to user space | ||
994 | */ | ||
995 | LDREG PT_IASQ0(%r16), %r20 | ||
996 | CMPIB=,n 0,%r20,intr_restore /* backward */ | ||
997 | LDREG PT_IASQ1(%r16), %r20 | ||
998 | CMPIB=,n 0,%r20,intr_restore /* backward */ | ||
999 | |||
1000 | copy %r0, %r25 /* long in_syscall = 0 */ | ||
1001 | #ifdef CONFIG_64BIT | ||
1002 | ldo -16(%r30),%r29 /* Reference param save area */ | ||
1003 | #endif | ||
1004 | |||
1005 | BL do_notify_resume,%r2 | ||
1006 | copy %r16, %r26 /* struct pt_regs *regs */ | ||
1007 | |||
1008 | b,n intr_check_sig | ||
986 | 1009 | ||
987 | intr_restore: | 1010 | intr_restore: |
988 | copy %r16,%r29 | 1011 | copy %r16,%r29 |
@@ -1072,35 +1095,6 @@ intr_do_preempt: | |||
1072 | b,n intr_restore /* ssm PSW_SM_I done by intr_restore */ | 1095 | b,n intr_restore /* ssm PSW_SM_I done by intr_restore */ |
1073 | #endif /* CONFIG_PREEMPT */ | 1096 | #endif /* CONFIG_PREEMPT */ |
1074 | 1097 | ||
1075 | .import do_signal,code | ||
1076 | intr_do_signal: | ||
1077 | /* | ||
1078 | This check is critical to having LWS | ||
1079 | working. The IASQ is zero on the gateway | ||
1080 | page and we cannot deliver any signals until | ||
1081 | we get off the gateway page. | ||
1082 | |||
1083 | Only do signals if we are returning to user space | ||
1084 | */ | ||
1085 | LDREG PT_IASQ0(%r16), %r20 | ||
1086 | CMPIB= 0,%r20,intr_restore /* backward */ | ||
1087 | nop | ||
1088 | LDREG PT_IASQ1(%r16), %r20 | ||
1089 | CMPIB= 0,%r20,intr_restore /* backward */ | ||
1090 | nop | ||
1091 | |||
1092 | copy %r0, %r24 /* unsigned long in_syscall */ | ||
1093 | copy %r16, %r25 /* struct pt_regs *regs */ | ||
1094 | #ifdef CONFIG_64BIT | ||
1095 | ldo -16(%r30),%r29 /* Reference param save area */ | ||
1096 | #endif | ||
1097 | |||
1098 | BL do_signal,%r2 | ||
1099 | copy %r0, %r26 /* sigset_t *oldset = NULL */ | ||
1100 | |||
1101 | b intr_check_sig | ||
1102 | nop | ||
1103 | |||
1104 | /* | 1098 | /* |
1105 | * External interrupts. | 1099 | * External interrupts. |
1106 | */ | 1100 | */ |
@@ -1115,11 +1109,7 @@ intr_extint: | |||
1115 | mfctl %cr31,%r1 | 1109 | mfctl %cr31,%r1 |
1116 | copy %r30,%r17 | 1110 | copy %r30,%r17 |
1117 | /* FIXME! depi below has hardcoded idea of interrupt stack size (32k)*/ | 1111 | /* FIXME! depi below has hardcoded idea of interrupt stack size (32k)*/ |
1118 | #ifdef CONFIG_64BIT | 1112 | DEPI 0,31,15,%r17 |
1119 | depdi 0,63,15,%r17 | ||
1120 | #else | ||
1121 | depi 0,31,15,%r17 | ||
1122 | #endif | ||
1123 | CMPB=,n %r1,%r17,2f | 1113 | CMPB=,n %r1,%r17,2f |
1124 | get_stack_use_cr31 | 1114 | get_stack_use_cr31 |
1125 | b,n 3f | 1115 | b,n 3f |
@@ -1148,13 +1138,12 @@ intr_extint: | |||
1148 | 1138 | ||
1149 | b do_cpu_irq_mask | 1139 | b do_cpu_irq_mask |
1150 | ldo R%intr_return(%r2), %r2 /* return to intr_return, not here */ | 1140 | ldo R%intr_return(%r2), %r2 /* return to intr_return, not here */ |
1141 | ENDPROC(syscall_exit_rfi) | ||
1151 | 1142 | ||
1152 | 1143 | ||
1153 | /* Generic interruptions (illegal insn, unaligned, page fault, etc) */ | 1144 | /* Generic interruptions (illegal insn, unaligned, page fault, etc) */ |
1154 | 1145 | ||
1155 | .export intr_save, code /* for os_hpmc */ | 1146 | ENTRY(intr_save) /* for os_hpmc */ |
1156 | |||
1157 | intr_save: | ||
1158 | mfsp %sr7,%r16 | 1147 | mfsp %sr7,%r16 |
1159 | CMPIB=,n 0,%r16,1f | 1148 | CMPIB=,n 0,%r16,1f |
1160 | get_stack_use_cr30 | 1149 | get_stack_use_cr30 |
@@ -1229,6 +1218,7 @@ skip_save_ior: | |||
1229 | 1218 | ||
1230 | b handle_interruption | 1219 | b handle_interruption |
1231 | ldo R%intr_check_sig(%r2), %r2 | 1220 | ldo R%intr_check_sig(%r2), %r2 |
1221 | ENDPROC(intr_save) | ||
1232 | 1222 | ||
1233 | 1223 | ||
1234 | /* | 1224 | /* |
@@ -1814,9 +1804,7 @@ dtlb_fault: | |||
1814 | LDREG PT_GR18(\regs),%r18 | 1804 | LDREG PT_GR18(\regs),%r18 |
1815 | .endm | 1805 | .endm |
1816 | 1806 | ||
1817 | .export sys_fork_wrapper | 1807 | ENTRY(sys_fork_wrapper) |
1818 | .export child_return | ||
1819 | sys_fork_wrapper: | ||
1820 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30), %r1 | 1808 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30), %r1 |
1821 | ldo TASK_REGS(%r1),%r1 | 1809 | ldo TASK_REGS(%r1),%r1 |
1822 | reg_save %r1 | 1810 | reg_save %r1 |
@@ -1853,9 +1841,10 @@ wrapper_exit: | |||
1853 | ldi __NR_fork,%r20 | 1841 | ldi __NR_fork,%r20 |
1854 | bv %r0(%r2) | 1842 | bv %r0(%r2) |
1855 | STREG %r20,PT_GR20(%r1) | 1843 | STREG %r20,PT_GR20(%r1) |
1844 | ENDPROC(sys_fork_wrapper) | ||
1856 | 1845 | ||
1857 | /* Set the return value for the child */ | 1846 | /* Set the return value for the child */ |
1858 | child_return: | 1847 | ENTRY(child_return) |
1859 | BL schedule_tail, %r2 | 1848 | BL schedule_tail, %r2 |
1860 | nop | 1849 | nop |
1861 | 1850 | ||
@@ -1863,10 +1852,10 @@ child_return: | |||
1863 | LDREG TASK_PT_GR19(%r1),%r2 | 1852 | LDREG TASK_PT_GR19(%r1),%r2 |
1864 | b wrapper_exit | 1853 | b wrapper_exit |
1865 | copy %r0,%r28 | 1854 | copy %r0,%r28 |
1855 | ENDPROC(child_return) | ||
1866 | 1856 | ||
1867 | 1857 | ||
1868 | .export sys_clone_wrapper | 1858 | ENTRY(sys_clone_wrapper) |
1869 | sys_clone_wrapper: | ||
1870 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 | 1859 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 |
1871 | ldo TASK_REGS(%r1),%r1 /* get pt regs */ | 1860 | ldo TASK_REGS(%r1),%r1 /* get pt regs */ |
1872 | reg_save %r1 | 1861 | reg_save %r1 |
@@ -1887,9 +1876,10 @@ sys_clone_wrapper: | |||
1887 | 1876 | ||
1888 | b wrapper_exit | 1877 | b wrapper_exit |
1889 | LDREG -RP_OFFSET-FRAME_SIZE(%r30),%r2 | 1878 | LDREG -RP_OFFSET-FRAME_SIZE(%r30),%r2 |
1879 | ENDPROC(sys_clone_wrapper) | ||
1880 | |||
1890 | 1881 | ||
1891 | .export sys_vfork_wrapper | 1882 | ENTRY(sys_vfork_wrapper) |
1892 | sys_vfork_wrapper: | ||
1893 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 | 1883 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 |
1894 | ldo TASK_REGS(%r1),%r1 /* get pt regs */ | 1884 | ldo TASK_REGS(%r1),%r1 /* get pt regs */ |
1895 | reg_save %r1 | 1885 | reg_save %r1 |
@@ -1910,6 +1900,7 @@ sys_vfork_wrapper: | |||
1910 | 1900 | ||
1911 | b wrapper_exit | 1901 | b wrapper_exit |
1912 | LDREG -RP_OFFSET-FRAME_SIZE(%r30),%r2 | 1902 | LDREG -RP_OFFSET-FRAME_SIZE(%r30),%r2 |
1903 | ENDPROC(sys_vfork_wrapper) | ||
1913 | 1904 | ||
1914 | 1905 | ||
1915 | .macro execve_wrapper execve | 1906 | .macro execve_wrapper execve |
@@ -1946,22 +1937,19 @@ error_\execve: | |||
1946 | nop | 1937 | nop |
1947 | .endm | 1938 | .endm |
1948 | 1939 | ||
1949 | .export sys_execve_wrapper | ||
1950 | .import sys_execve | 1940 | .import sys_execve |
1951 | 1941 | ENTRY(sys_execve_wrapper) | |
1952 | sys_execve_wrapper: | ||
1953 | execve_wrapper sys_execve | 1942 | execve_wrapper sys_execve |
1943 | ENDPROC(sys_execve_wrapper) | ||
1954 | 1944 | ||
1955 | #ifdef CONFIG_64BIT | 1945 | #ifdef CONFIG_64BIT |
1956 | .export sys32_execve_wrapper | ||
1957 | .import sys32_execve | 1946 | .import sys32_execve |
1958 | 1947 | ENTRY(sys32_execve_wrapper) | |
1959 | sys32_execve_wrapper: | ||
1960 | execve_wrapper sys32_execve | 1948 | execve_wrapper sys32_execve |
1949 | ENDPROC(sys32_execve_wrapper) | ||
1961 | #endif | 1950 | #endif |
1962 | 1951 | ||
1963 | .export sys_rt_sigreturn_wrapper | 1952 | ENTRY(sys_rt_sigreturn_wrapper) |
1964 | sys_rt_sigreturn_wrapper: | ||
1965 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r26 | 1953 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r26 |
1966 | ldo TASK_REGS(%r26),%r26 /* get pt regs */ | 1954 | ldo TASK_REGS(%r26),%r26 /* get pt regs */ |
1967 | /* Don't save regs, we are going to restore them from sigcontext. */ | 1955 | /* Don't save regs, we are going to restore them from sigcontext. */ |
@@ -1989,9 +1977,9 @@ sys_rt_sigreturn_wrapper: | |||
1989 | */ | 1977 | */ |
1990 | bv %r0(%r2) | 1978 | bv %r0(%r2) |
1991 | LDREG PT_GR28(%r1),%r28 /* reload original r28 for syscall_exit */ | 1979 | LDREG PT_GR28(%r1),%r28 /* reload original r28 for syscall_exit */ |
1980 | ENDPROC(sys_rt_sigreturn_wrapper) | ||
1992 | 1981 | ||
1993 | .export sys_sigaltstack_wrapper | 1982 | ENTRY(sys_sigaltstack_wrapper) |
1994 | sys_sigaltstack_wrapper: | ||
1995 | /* Get the user stack pointer */ | 1983 | /* Get the user stack pointer */ |
1996 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 | 1984 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 |
1997 | ldo TASK_REGS(%r1),%r24 /* get pt regs */ | 1985 | ldo TASK_REGS(%r1),%r24 /* get pt regs */ |
@@ -1999,10 +1987,10 @@ sys_sigaltstack_wrapper: | |||
1999 | STREG %r2, -RP_OFFSET(%r30) | 1987 | STREG %r2, -RP_OFFSET(%r30) |
2000 | #ifdef CONFIG_64BIT | 1988 | #ifdef CONFIG_64BIT |
2001 | ldo FRAME_SIZE(%r30), %r30 | 1989 | ldo FRAME_SIZE(%r30), %r30 |
2002 | b,l do_sigaltstack,%r2 | 1990 | BL do_sigaltstack,%r2 |
2003 | ldo -16(%r30),%r29 /* Reference param save area */ | 1991 | ldo -16(%r30),%r29 /* Reference param save area */ |
2004 | #else | 1992 | #else |
2005 | bl do_sigaltstack,%r2 | 1993 | BL do_sigaltstack,%r2 |
2006 | ldo FRAME_SIZE(%r30), %r30 | 1994 | ldo FRAME_SIZE(%r30), %r30 |
2007 | #endif | 1995 | #endif |
2008 | 1996 | ||
@@ -2010,53 +1998,26 @@ sys_sigaltstack_wrapper: | |||
2010 | LDREG -RP_OFFSET(%r30), %r2 | 1998 | LDREG -RP_OFFSET(%r30), %r2 |
2011 | bv %r0(%r2) | 1999 | bv %r0(%r2) |
2012 | nop | 2000 | nop |
2001 | ENDPROC(sys_sigaltstack_wrapper) | ||
2013 | 2002 | ||
2014 | #ifdef CONFIG_64BIT | 2003 | #ifdef CONFIG_64BIT |
2015 | .export sys32_sigaltstack_wrapper | 2004 | ENTRY(sys32_sigaltstack_wrapper) |
2016 | sys32_sigaltstack_wrapper: | ||
2017 | /* Get the user stack pointer */ | 2005 | /* Get the user stack pointer */ |
2018 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r24 | 2006 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r24 |
2019 | LDREG TASK_PT_GR30(%r24),%r24 | 2007 | LDREG TASK_PT_GR30(%r24),%r24 |
2020 | STREG %r2, -RP_OFFSET(%r30) | 2008 | STREG %r2, -RP_OFFSET(%r30) |
2021 | ldo FRAME_SIZE(%r30), %r30 | 2009 | ldo FRAME_SIZE(%r30), %r30 |
2022 | b,l do_sigaltstack32,%r2 | 2010 | BL do_sigaltstack32,%r2 |
2023 | ldo -16(%r30),%r29 /* Reference param save area */ | 2011 | ldo -16(%r30),%r29 /* Reference param save area */ |
2024 | 2012 | ||
2025 | ldo -FRAME_SIZE(%r30), %r30 | 2013 | ldo -FRAME_SIZE(%r30), %r30 |
2026 | LDREG -RP_OFFSET(%r30), %r2 | 2014 | LDREG -RP_OFFSET(%r30), %r2 |
2027 | bv %r0(%r2) | 2015 | bv %r0(%r2) |
2028 | nop | 2016 | nop |
2017 | ENDPROC(sys32_sigaltstack_wrapper) | ||
2029 | #endif | 2018 | #endif |
2030 | 2019 | ||
2031 | .export sys_rt_sigsuspend_wrapper | 2020 | ENTRY(syscall_exit) |
2032 | sys_rt_sigsuspend_wrapper: | ||
2033 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30), %r1 | ||
2034 | ldo TASK_REGS(%r1),%r24 | ||
2035 | reg_save %r24 | ||
2036 | |||
2037 | STREG %r2, -RP_OFFSET(%r30) | ||
2038 | #ifdef CONFIG_64BIT | ||
2039 | ldo FRAME_SIZE(%r30), %r30 | ||
2040 | b,l sys_rt_sigsuspend,%r2 | ||
2041 | ldo -16(%r30),%r29 /* Reference param save area */ | ||
2042 | #else | ||
2043 | bl sys_rt_sigsuspend,%r2 | ||
2044 | ldo FRAME_SIZE(%r30), %r30 | ||
2045 | #endif | ||
2046 | |||
2047 | ldo -FRAME_SIZE(%r30), %r30 | ||
2048 | LDREG -RP_OFFSET(%r30), %r2 | ||
2049 | |||
2050 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30), %r1 | ||
2051 | ldo TASK_REGS(%r1),%r1 | ||
2052 | reg_restore %r1 | ||
2053 | |||
2054 | bv %r0(%r2) | ||
2055 | nop | ||
2056 | |||
2057 | .export syscall_exit | ||
2058 | syscall_exit: | ||
2059 | |||
2060 | /* NOTE: HP-UX syscalls also come through here | 2021 | /* NOTE: HP-UX syscalls also come through here |
2061 | * after hpux_syscall_exit fixes up return | 2022 | * after hpux_syscall_exit fixes up return |
2062 | * values. */ | 2023 | * values. */ |
@@ -2119,9 +2080,35 @@ syscall_check_resched: | |||
2119 | LDREG TI_FLAGS-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r19 /* long */ | 2080 | LDREG TI_FLAGS-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r19 /* long */ |
2120 | bb,<,n %r19, 31-TIF_NEED_RESCHED, syscall_do_resched /* forward */ | 2081 | bb,<,n %r19, 31-TIF_NEED_RESCHED, syscall_do_resched /* forward */ |
2121 | 2082 | ||
2083 | .import do_signal,code | ||
2122 | syscall_check_sig: | 2084 | syscall_check_sig: |
2123 | LDREG TI_FLAGS-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r19 /* get ti flags */ | 2085 | LDREG TI_FLAGS-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r19 |
2124 | bb,<,n %r19, 31-TIF_SIGPENDING, syscall_do_signal /* forward */ | 2086 | ldi (_TIF_SIGPENDING|_TIF_RESTORE_SIGMASK), %r26 |
2087 | and,COND(<>) %r19, %r26, %r0 | ||
2088 | b,n syscall_restore /* skip past if we've nothing to do */ | ||
2089 | |||
2090 | syscall_do_signal: | ||
2091 | /* Save callee-save registers (for sigcontext). | ||
2092 | * FIXME: After this point the process structure should be | ||
2093 | * consistent with all the relevant state of the process | ||
2094 | * before the syscall. We need to verify this. | ||
2095 | */ | ||
2096 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 | ||
2097 | ldo TASK_REGS(%r1), %r26 /* struct pt_regs *regs */ | ||
2098 | reg_save %r26 | ||
2099 | |||
2100 | #ifdef CONFIG_64BIT | ||
2101 | ldo -16(%r30),%r29 /* Reference param save area */ | ||
2102 | #endif | ||
2103 | |||
2104 | BL do_notify_resume,%r2 | ||
2105 | ldi 1, %r25 /* long in_syscall = 1 */ | ||
2106 | |||
2107 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 | ||
2108 | ldo TASK_REGS(%r1), %r20 /* reload pt_regs */ | ||
2109 | reg_restore %r20 | ||
2110 | |||
2111 | b,n syscall_check_sig | ||
2125 | 2112 | ||
2126 | syscall_restore: | 2113 | syscall_restore: |
2127 | /* Are we being ptraced? */ | 2114 | /* Are we being ptraced? */ |
@@ -2259,31 +2246,10 @@ syscall_do_resched: | |||
2259 | #endif | 2246 | #endif |
2260 | b syscall_check_bh /* if resched, we start over again */ | 2247 | b syscall_check_bh /* if resched, we start over again */ |
2261 | nop | 2248 | nop |
2249 | ENDPROC(syscall_exit) | ||
2262 | 2250 | ||
2263 | .import do_signal,code | ||
2264 | syscall_do_signal: | ||
2265 | /* Save callee-save registers (for sigcontext). | ||
2266 | FIXME: After this point the process structure should be | ||
2267 | consistent with all the relevant state of the process | ||
2268 | before the syscall. We need to verify this. */ | ||
2269 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 | ||
2270 | ldo TASK_REGS(%r1), %r25 /* struct pt_regs *regs */ | ||
2271 | reg_save %r25 | ||
2272 | |||
2273 | ldi 1, %r24 /* unsigned long in_syscall */ | ||
2274 | |||
2275 | #ifdef CONFIG_64BIT | ||
2276 | ldo -16(%r30),%r29 /* Reference param save area */ | ||
2277 | #endif | ||
2278 | BL do_signal,%r2 | ||
2279 | copy %r0, %r26 /* sigset_t *oldset = NULL */ | ||
2280 | |||
2281 | LDREG TI_TASK-THREAD_SZ_ALGN-FRAME_SIZE(%r30),%r1 | ||
2282 | ldo TASK_REGS(%r1), %r20 /* reload pt_regs */ | ||
2283 | reg_restore %r20 | ||
2284 | |||
2285 | b,n syscall_check_sig | ||
2286 | 2251 | ||
2252 | get_register: | ||
2287 | /* | 2253 | /* |
2288 | * get_register is used by the non access tlb miss handlers to | 2254 | * get_register is used by the non access tlb miss handlers to |
2289 | * copy the value of the general register specified in r8 into | 2255 | * copy the value of the general register specified in r8 into |
@@ -2294,8 +2260,6 @@ syscall_do_signal: | |||
2294 | * a -1 in it, but that is OK, it just means that we will have | 2260 | * a -1 in it, but that is OK, it just means that we will have |
2295 | * to use the slow path instead). | 2261 | * to use the slow path instead). |
2296 | */ | 2262 | */ |
2297 | |||
2298 | get_register: | ||
2299 | blr %r8,%r0 | 2263 | blr %r8,%r0 |
2300 | nop | 2264 | nop |
2301 | bv %r0(%r25) /* r0 */ | 2265 | bv %r0(%r25) /* r0 */ |
@@ -2363,13 +2327,13 @@ get_register: | |||
2363 | bv %r0(%r25) /* r31 */ | 2327 | bv %r0(%r25) /* r31 */ |
2364 | copy %r31,%r1 | 2328 | copy %r31,%r1 |
2365 | 2329 | ||
2330 | |||
2331 | set_register: | ||
2366 | /* | 2332 | /* |
2367 | * set_register is used by the non access tlb miss handlers to | 2333 | * set_register is used by the non access tlb miss handlers to |
2368 | * copy the value of r1 into the general register specified in | 2334 | * copy the value of r1 into the general register specified in |
2369 | * r8. | 2335 | * r8. |
2370 | */ | 2336 | */ |
2371 | |||
2372 | set_register: | ||
2373 | blr %r8,%r0 | 2337 | blr %r8,%r0 |
2374 | nop | 2338 | nop |
2375 | bv %r0(%r25) /* r0 (silly, but it is a place holder) */ | 2339 | bv %r0(%r25) /* r0 (silly, but it is a place holder) */ |
@@ -2436,3 +2400,4 @@ set_register: | |||
2436 | copy %r1,%r30 | 2400 | copy %r1,%r30 |
2437 | bv %r0(%r25) /* r31 */ | 2401 | bv %r0(%r25) /* r31 */ |
2438 | copy %r1,%r31 | 2402 | copy %r1,%r31 |
2403 | |||
diff --git a/arch/parisc/kernel/firmware.c b/arch/parisc/kernel/firmware.c index 9158b707c0dd..39dc835bf89e 100644 --- a/arch/parisc/kernel/firmware.c +++ b/arch/parisc/kernel/firmware.c | |||
@@ -74,7 +74,7 @@ static DEFINE_SPINLOCK(pdc_lock); | |||
74 | static unsigned long pdc_result[32] __attribute__ ((aligned (8))); | 74 | static unsigned long pdc_result[32] __attribute__ ((aligned (8))); |
75 | static unsigned long pdc_result2[32] __attribute__ ((aligned (8))); | 75 | static unsigned long pdc_result2[32] __attribute__ ((aligned (8))); |
76 | 76 | ||
77 | #ifdef __LP64__ | 77 | #ifdef CONFIG_64BIT |
78 | #define WIDE_FIRMWARE 0x1 | 78 | #define WIDE_FIRMWARE 0x1 |
79 | #define NARROW_FIRMWARE 0x2 | 79 | #define NARROW_FIRMWARE 0x2 |
80 | 80 | ||
@@ -94,12 +94,12 @@ int parisc_narrow_firmware __read_mostly = 1; | |||
94 | * when running a 64-bit kernel on such boxes (e.g. C200 or C360). | 94 | * when running a 64-bit kernel on such boxes (e.g. C200 or C360). |
95 | */ | 95 | */ |
96 | 96 | ||
97 | #ifdef __LP64__ | 97 | #ifdef CONFIG_64BIT |
98 | long real64_call(unsigned long function, ...); | 98 | long real64_call(unsigned long function, ...); |
99 | #endif | 99 | #endif |
100 | long real32_call(unsigned long function, ...); | 100 | long real32_call(unsigned long function, ...); |
101 | 101 | ||
102 | #ifdef __LP64__ | 102 | #ifdef CONFIG_64BIT |
103 | # define MEM_PDC (unsigned long)(PAGE0->mem_pdc_hi) << 32 | PAGE0->mem_pdc | 103 | # define MEM_PDC (unsigned long)(PAGE0->mem_pdc_hi) << 32 | PAGE0->mem_pdc |
104 | # define mem_pdc_call(args...) unlikely(parisc_narrow_firmware) ? real32_call(MEM_PDC, args) : real64_call(MEM_PDC, args) | 104 | # define mem_pdc_call(args...) unlikely(parisc_narrow_firmware) ? real32_call(MEM_PDC, args) : real64_call(MEM_PDC, args) |
105 | #else | 105 | #else |
@@ -117,7 +117,7 @@ long real32_call(unsigned long function, ...); | |||
117 | */ | 117 | */ |
118 | static unsigned long f_extend(unsigned long address) | 118 | static unsigned long f_extend(unsigned long address) |
119 | { | 119 | { |
120 | #ifdef __LP64__ | 120 | #ifdef CONFIG_64BIT |
121 | if(unlikely(parisc_narrow_firmware)) { | 121 | if(unlikely(parisc_narrow_firmware)) { |
122 | if((address & 0xff000000) == 0xf0000000) | 122 | if((address & 0xff000000) == 0xf0000000) |
123 | return 0xf0f0f0f000000000UL | (u32)address; | 123 | return 0xf0f0f0f000000000UL | (u32)address; |
@@ -139,7 +139,7 @@ static unsigned long f_extend(unsigned long address) | |||
139 | */ | 139 | */ |
140 | static void convert_to_wide(unsigned long *addr) | 140 | static void convert_to_wide(unsigned long *addr) |
141 | { | 141 | { |
142 | #ifdef __LP64__ | 142 | #ifdef CONFIG_64BIT |
143 | int i; | 143 | int i; |
144 | unsigned int *p = (unsigned int *)addr; | 144 | unsigned int *p = (unsigned int *)addr; |
145 | 145 | ||
@@ -158,7 +158,7 @@ static void convert_to_wide(unsigned long *addr) | |||
158 | */ | 158 | */ |
159 | void __init set_firmware_width(void) | 159 | void __init set_firmware_width(void) |
160 | { | 160 | { |
161 | #ifdef __LP64__ | 161 | #ifdef CONFIG_64BIT |
162 | int retval; | 162 | int retval; |
163 | unsigned long flags; | 163 | unsigned long flags; |
164 | 164 | ||
@@ -238,7 +238,7 @@ int __init pdc_chassis_info(struct pdc_chassis_info *chassis_info, void *led_inf | |||
238 | * | 238 | * |
239 | * Must be correctly formatted or expect system crash | 239 | * Must be correctly formatted or expect system crash |
240 | */ | 240 | */ |
241 | #ifdef __LP64__ | 241 | #ifdef CONFIG_64BIT |
242 | int pdc_pat_chassis_send_log(unsigned long state, unsigned long data) | 242 | int pdc_pat_chassis_send_log(unsigned long state, unsigned long data) |
243 | { | 243 | { |
244 | int retval = 0; | 244 | int retval = 0; |
@@ -949,7 +949,7 @@ int pdc_tod_set(unsigned long sec, unsigned long usec) | |||
949 | } | 949 | } |
950 | EXPORT_SYMBOL(pdc_tod_set); | 950 | EXPORT_SYMBOL(pdc_tod_set); |
951 | 951 | ||
952 | #ifdef __LP64__ | 952 | #ifdef CONFIG_64BIT |
953 | int pdc_mem_mem_table(struct pdc_memory_table_raddr *r_addr, | 953 | int pdc_mem_mem_table(struct pdc_memory_table_raddr *r_addr, |
954 | struct pdc_memory_table *tbl, unsigned long entries) | 954 | struct pdc_memory_table *tbl, unsigned long entries) |
955 | { | 955 | { |
@@ -965,7 +965,7 @@ int pdc_mem_mem_table(struct pdc_memory_table_raddr *r_addr, | |||
965 | 965 | ||
966 | return retval; | 966 | return retval; |
967 | } | 967 | } |
968 | #endif /* __LP64__ */ | 968 | #endif /* CONFIG_64BIT */ |
969 | 969 | ||
970 | /* FIXME: Is this pdc used? I could not find type reference to ftc_bitmap | 970 | /* FIXME: Is this pdc used? I could not find type reference to ftc_bitmap |
971 | * so I guessed at unsigned long. Someone who knows what this does, can fix | 971 | * so I guessed at unsigned long. Someone who knows what this does, can fix |
@@ -1204,7 +1204,7 @@ int pdc_sti_call(unsigned long func, unsigned long flags, | |||
1204 | } | 1204 | } |
1205 | EXPORT_SYMBOL(pdc_sti_call); | 1205 | EXPORT_SYMBOL(pdc_sti_call); |
1206 | 1206 | ||
1207 | #ifdef __LP64__ | 1207 | #ifdef CONFIG_64BIT |
1208 | /** | 1208 | /** |
1209 | * pdc_pat_cell_get_number - Returns the cell number. | 1209 | * pdc_pat_cell_get_number - Returns the cell number. |
1210 | * @cell_info: The return buffer. | 1210 | * @cell_info: The return buffer. |
@@ -1387,7 +1387,7 @@ int pdc_pat_io_pci_cfg_write(unsigned long pci_addr, int pci_size, u32 val) | |||
1387 | 1387 | ||
1388 | return retval; | 1388 | return retval; |
1389 | } | 1389 | } |
1390 | #endif /* __LP64__ */ | 1390 | #endif /* CONFIG_64BIT */ |
1391 | 1391 | ||
1392 | 1392 | ||
1393 | /***************** 32-bit real-mode calls ***********/ | 1393 | /***************** 32-bit real-mode calls ***********/ |
@@ -1445,7 +1445,7 @@ long real32_call(unsigned long fn, ...) | |||
1445 | return real32_call_asm(&real_stack.sp, &real_stack.arg0, fn); | 1445 | return real32_call_asm(&real_stack.sp, &real_stack.arg0, fn); |
1446 | } | 1446 | } |
1447 | 1447 | ||
1448 | #ifdef __LP64__ | 1448 | #ifdef CONFIG_64BIT |
1449 | /***************** 64-bit real-mode calls ***********/ | 1449 | /***************** 64-bit real-mode calls ***********/ |
1450 | 1450 | ||
1451 | struct wide_stack { | 1451 | struct wide_stack { |
@@ -1496,5 +1496,5 @@ long real64_call(unsigned long fn, ...) | |||
1496 | return real64_call_asm(&real64_stack.sp, &real64_stack.arg0, fn); | 1496 | return real64_call_asm(&real64_stack.sp, &real64_stack.arg0, fn); |
1497 | } | 1497 | } |
1498 | 1498 | ||
1499 | #endif /* __LP64__ */ | 1499 | #endif /* CONFIG_64BIT */ |
1500 | 1500 | ||
diff --git a/arch/parisc/kernel/head.S b/arch/parisc/kernel/head.S index eaad2328fea1..9676c486bb63 100644 --- a/arch/parisc/kernel/head.S +++ b/arch/parisc/kernel/head.S | |||
@@ -2,7 +2,7 @@ | |||
2 | * License. See the file "COPYING" in the main directory of this archive | 2 | * License. See the file "COPYING" in the main directory of this archive |
3 | * for more details. | 3 | * for more details. |
4 | * | 4 | * |
5 | * Copyright (C) 1999 by Helge Deller | 5 | * Copyright (C) 1999-2007 by Helge Deller <deller@gmx.de> |
6 | * Copyright 1999 SuSE GmbH (Philipp Rumpf) | 6 | * Copyright 1999 SuSE GmbH (Philipp Rumpf) |
7 | * Copyright 1999 Philipp Rumpf (prumpf@tux.org) | 7 | * Copyright 1999 Philipp Rumpf (prumpf@tux.org) |
8 | * Copyright 2000 Hewlett Packard (Paul Bame, bame@puffin.external.hp.com) | 8 | * Copyright 2000 Hewlett Packard (Paul Bame, bame@puffin.external.hp.com) |
@@ -19,16 +19,17 @@ | |||
19 | #include <asm/assembly.h> | 19 | #include <asm/assembly.h> |
20 | #include <asm/pgtable.h> | 20 | #include <asm/pgtable.h> |
21 | 21 | ||
22 | #include <linux/linkage.h> | ||
23 | |||
22 | .level LEVEL | 24 | .level LEVEL |
23 | 25 | ||
24 | .data | 26 | .data |
25 | 27 | ENTRY(boot_args) | |
26 | .export boot_args | ||
27 | boot_args: | ||
28 | .word 0 /* arg0 */ | 28 | .word 0 /* arg0 */ |
29 | .word 0 /* arg1 */ | 29 | .word 0 /* arg1 */ |
30 | .word 0 /* arg2 */ | 30 | .word 0 /* arg2 */ |
31 | .word 0 /* arg3 */ | 31 | .word 0 /* arg3 */ |
32 | END(boot_args) | ||
32 | 33 | ||
33 | .text | 34 | .text |
34 | .align 4 | 35 | .align 4 |
@@ -38,10 +39,9 @@ boot_args: | |||
38 | .import fault_vector_11,code /* IVA parisc 1.1 32 bit */ | 39 | .import fault_vector_11,code /* IVA parisc 1.1 32 bit */ |
39 | .import $global$ /* forward declaration */ | 40 | .import $global$ /* forward declaration */ |
40 | #endif /*!CONFIG_64BIT*/ | 41 | #endif /*!CONFIG_64BIT*/ |
41 | .export stext | ||
42 | .export _stext,data /* Kernel want it this way! */ | 42 | .export _stext,data /* Kernel want it this way! */ |
43 | _stext: | 43 | _stext: |
44 | stext: | 44 | ENTRY(stext) |
45 | .proc | 45 | .proc |
46 | .callinfo | 46 | .callinfo |
47 | 47 | ||
@@ -343,6 +343,9 @@ smp_slave_stext: | |||
343 | 343 | ||
344 | .procend | 344 | .procend |
345 | #endif /* CONFIG_SMP */ | 345 | #endif /* CONFIG_SMP */ |
346 | |||
347 | ENDPROC(stext) | ||
348 | |||
346 | #ifndef CONFIG_64BIT | 349 | #ifndef CONFIG_64BIT |
347 | .data | 350 | .data |
348 | 351 | ||
diff --git a/arch/parisc/kernel/hpmc.S b/arch/parisc/kernel/hpmc.S index c412c0adc4a9..d8baa158d8a0 100644 --- a/arch/parisc/kernel/hpmc.S +++ b/arch/parisc/kernel/hpmc.S | |||
@@ -46,6 +46,8 @@ | |||
46 | #include <asm/assembly.h> | 46 | #include <asm/assembly.h> |
47 | #include <asm/pdc.h> | 47 | #include <asm/pdc.h> |
48 | 48 | ||
49 | #include <linux/linkage.h> | ||
50 | |||
49 | /* | 51 | /* |
50 | * stack for os_hpmc, the HPMC handler. | 52 | * stack for os_hpmc, the HPMC handler. |
51 | * buffer for IODC procedures (for the HPMC handler). | 53 | * buffer for IODC procedures (for the HPMC handler). |
@@ -69,17 +71,15 @@ hpmc_raddr: | |||
69 | 71 | ||
70 | #define HPMC_PIM_DATA_SIZE 896 /* Enough to hold all architected 2.0 state */ | 72 | #define HPMC_PIM_DATA_SIZE 896 /* Enough to hold all architected 2.0 state */ |
71 | 73 | ||
72 | .export hpmc_pim_data, data | ||
73 | .align 8 | 74 | .align 8 |
74 | hpmc_pim_data: | 75 | ENTRY(hpmc_pim_data) |
75 | .block HPMC_PIM_DATA_SIZE | 76 | .block HPMC_PIM_DATA_SIZE |
77 | END(hpmc_pim_data) | ||
76 | 78 | ||
77 | .text | 79 | .text |
78 | 80 | ||
79 | .export os_hpmc, code | ||
80 | .import intr_save, code | 81 | .import intr_save, code |
81 | 82 | ENTRY(os_hpmc) | |
82 | os_hpmc: | ||
83 | 83 | ||
84 | /* | 84 | /* |
85 | * registers modified: | 85 | * registers modified: |
@@ -294,11 +294,9 @@ os_hpmc_6: | |||
294 | 294 | ||
295 | b . | 295 | b . |
296 | nop | 296 | nop |
297 | ENDPROC(os_hpmc) | ||
297 | 298 | ||
298 | /* this label used to compute os_hpmc checksum */ | 299 | /* this label used to compute os_hpmc checksum */ |
299 | 300 | ENTRY(os_hpmc_end) | |
300 | .export os_hpmc_end, code | ||
301 | |||
302 | os_hpmc_end: | ||
303 | 301 | ||
304 | nop | 302 | nop |
diff --git a/arch/parisc/kernel/inventory.c b/arch/parisc/kernel/inventory.c index 4e847ba53180..4845a6444633 100644 --- a/arch/parisc/kernel/inventory.c +++ b/arch/parisc/kernel/inventory.c | |||
@@ -47,7 +47,7 @@ void __init setup_pdc(void) | |||
47 | struct pdc_system_map_mod_info module_result; | 47 | struct pdc_system_map_mod_info module_result; |
48 | struct pdc_module_path module_path; | 48 | struct pdc_module_path module_path; |
49 | struct pdc_model model; | 49 | struct pdc_model model; |
50 | #ifdef __LP64__ | 50 | #ifdef CONFIG_64BIT |
51 | struct pdc_pat_cell_num cell_info; | 51 | struct pdc_pat_cell_num cell_info; |
52 | #endif | 52 | #endif |
53 | 53 | ||
@@ -73,7 +73,7 @@ void __init setup_pdc(void) | |||
73 | * clearer message. | 73 | * clearer message. |
74 | */ | 74 | */ |
75 | 75 | ||
76 | #ifdef __LP64__ | 76 | #ifdef CONFIG_64BIT |
77 | status = pdc_pat_cell_get_number(&cell_info); | 77 | status = pdc_pat_cell_get_number(&cell_info); |
78 | if (status == PDC_OK) { | 78 | if (status == PDC_OK) { |
79 | pdc_type = PDC_TYPE_PAT; | 79 | pdc_type = PDC_TYPE_PAT; |
@@ -152,7 +152,7 @@ static void __init pagezero_memconfig(void) | |||
152 | npmem_ranges = 1; | 152 | npmem_ranges = 1; |
153 | } | 153 | } |
154 | 154 | ||
155 | #ifdef __LP64__ | 155 | #ifdef CONFIG_64BIT |
156 | 156 | ||
157 | /* All of the PDC PAT specific code is 64-bit only */ | 157 | /* All of the PDC PAT specific code is 64-bit only */ |
158 | 158 | ||
@@ -408,13 +408,13 @@ static void __init sprockets_memconfig(void) | |||
408 | } | 408 | } |
409 | } | 409 | } |
410 | 410 | ||
411 | #else /* !__LP64__ */ | 411 | #else /* !CONFIG_64BIT */ |
412 | 412 | ||
413 | #define pat_inventory() do { } while (0) | 413 | #define pat_inventory() do { } while (0) |
414 | #define pat_memconfig() do { } while (0) | 414 | #define pat_memconfig() do { } while (0) |
415 | #define sprockets_memconfig() pagezero_memconfig() | 415 | #define sprockets_memconfig() pagezero_memconfig() |
416 | 416 | ||
417 | #endif /* !__LP64__ */ | 417 | #endif /* !CONFIG_64BIT */ |
418 | 418 | ||
419 | 419 | ||
420 | #ifndef CONFIG_PA20 | 420 | #ifndef CONFIG_PA20 |
diff --git a/arch/parisc/kernel/irq.c b/arch/parisc/kernel/irq.c index b39c5b9aff46..e9d09b020e86 100644 --- a/arch/parisc/kernel/irq.c +++ b/arch/parisc/kernel/irq.c | |||
@@ -336,11 +336,7 @@ unsigned int txn_alloc_data(unsigned int virt_irq) | |||
336 | 336 | ||
337 | static inline int eirr_to_irq(unsigned long eirr) | 337 | static inline int eirr_to_irq(unsigned long eirr) |
338 | { | 338 | { |
339 | #ifdef CONFIG_64BIT | 339 | int bit = fls_long(eirr); |
340 | int bit = fls64(eirr); | ||
341 | #else | ||
342 | int bit = fls(eirr); | ||
343 | #endif | ||
344 | return (BITS_PER_LONG - bit) + TIMER_IRQ; | 340 | return (BITS_PER_LONG - bit) + TIMER_IRQ; |
345 | } | 341 | } |
346 | 342 | ||
diff --git a/arch/parisc/kernel/module.c b/arch/parisc/kernel/module.c index f50b982b0834..fdacdd4341c9 100644 --- a/arch/parisc/kernel/module.c +++ b/arch/parisc/kernel/module.c | |||
@@ -46,6 +46,7 @@ | |||
46 | #include <linux/fs.h> | 46 | #include <linux/fs.h> |
47 | #include <linux/string.h> | 47 | #include <linux/string.h> |
48 | #include <linux/kernel.h> | 48 | #include <linux/kernel.h> |
49 | #include <linux/bug.h> | ||
49 | 50 | ||
50 | #include <asm/unwind.h> | 51 | #include <asm/unwind.h> |
51 | 52 | ||
@@ -96,7 +97,7 @@ static inline int in_local_section(struct module *me, void *loc, void *dot) | |||
96 | } | 97 | } |
97 | 98 | ||
98 | 99 | ||
99 | #ifndef __LP64__ | 100 | #ifndef CONFIG_64BIT |
100 | struct got_entry { | 101 | struct got_entry { |
101 | Elf32_Addr addr; | 102 | Elf32_Addr addr; |
102 | }; | 103 | }; |
@@ -176,7 +177,7 @@ void *module_alloc(unsigned long size) | |||
176 | return vmalloc(size); | 177 | return vmalloc(size); |
177 | } | 178 | } |
178 | 179 | ||
179 | #ifndef __LP64__ | 180 | #ifndef CONFIG_64BIT |
180 | static inline unsigned long count_gots(const Elf_Rela *rela, unsigned long n) | 181 | static inline unsigned long count_gots(const Elf_Rela *rela, unsigned long n) |
181 | { | 182 | { |
182 | return 0; | 183 | return 0; |
@@ -319,7 +320,7 @@ int module_frob_arch_sections(CONST Elf_Ehdr *hdr, | |||
319 | return 0; | 320 | return 0; |
320 | } | 321 | } |
321 | 322 | ||
322 | #ifdef __LP64__ | 323 | #ifdef CONFIG_64BIT |
323 | static Elf64_Word get_got(struct module *me, unsigned long value, long addend) | 324 | static Elf64_Word get_got(struct module *me, unsigned long value, long addend) |
324 | { | 325 | { |
325 | unsigned int i; | 326 | unsigned int i; |
@@ -342,9 +343,9 @@ static Elf64_Word get_got(struct module *me, unsigned long value, long addend) | |||
342 | value); | 343 | value); |
343 | return i * sizeof(struct got_entry); | 344 | return i * sizeof(struct got_entry); |
344 | } | 345 | } |
345 | #endif /* __LP64__ */ | 346 | #endif /* CONFIG_64BIT */ |
346 | 347 | ||
347 | #ifdef __LP64__ | 348 | #ifdef CONFIG_64BIT |
348 | static Elf_Addr get_fdesc(struct module *me, unsigned long value) | 349 | static Elf_Addr get_fdesc(struct module *me, unsigned long value) |
349 | { | 350 | { |
350 | Elf_Fdesc *fdesc = me->module_core + me->arch.fdesc_offset; | 351 | Elf_Fdesc *fdesc = me->module_core + me->arch.fdesc_offset; |
@@ -368,7 +369,7 @@ static Elf_Addr get_fdesc(struct module *me, unsigned long value) | |||
368 | fdesc->gp = (Elf_Addr)me->module_core + me->arch.got_offset; | 369 | fdesc->gp = (Elf_Addr)me->module_core + me->arch.got_offset; |
369 | return (Elf_Addr)fdesc; | 370 | return (Elf_Addr)fdesc; |
370 | } | 371 | } |
371 | #endif /* __LP64__ */ | 372 | #endif /* CONFIG_64BIT */ |
372 | 373 | ||
373 | enum elf_stub_type { | 374 | enum elf_stub_type { |
374 | ELF_STUB_GOT, | 375 | ELF_STUB_GOT, |
@@ -394,7 +395,7 @@ static Elf_Addr get_stub(struct module *me, unsigned long value, long addend, | |||
394 | i * sizeof(struct stub_entry); | 395 | i * sizeof(struct stub_entry); |
395 | } | 396 | } |
396 | 397 | ||
397 | #ifndef __LP64__ | 398 | #ifndef CONFIG_64BIT |
398 | /* for 32-bit the stub looks like this: | 399 | /* for 32-bit the stub looks like this: |
399 | * ldil L'XXX,%r1 | 400 | * ldil L'XXX,%r1 |
400 | * be,n R'XXX(%sr4,%r1) | 401 | * be,n R'XXX(%sr4,%r1) |
@@ -472,7 +473,7 @@ int apply_relocate(Elf_Shdr *sechdrs, | |||
472 | return -ENOEXEC; | 473 | return -ENOEXEC; |
473 | } | 474 | } |
474 | 475 | ||
475 | #ifndef __LP64__ | 476 | #ifndef CONFIG_64BIT |
476 | int apply_relocate_add(Elf_Shdr *sechdrs, | 477 | int apply_relocate_add(Elf_Shdr *sechdrs, |
477 | const char *strtab, | 478 | const char *strtab, |
478 | unsigned int symindex, | 479 | unsigned int symindex, |
@@ -822,7 +823,8 @@ int module_finalize(const Elf_Ehdr *hdr, | |||
822 | me->name, strtab, symhdr); | 823 | me->name, strtab, symhdr); |
823 | 824 | ||
824 | if(me->arch.got_count > MAX_GOTS) { | 825 | if(me->arch.got_count > MAX_GOTS) { |
825 | printk(KERN_ERR "%s: Global Offset Table overflow (used %ld, allowed %d\n", me->name, me->arch.got_count, MAX_GOTS); | 826 | printk(KERN_ERR "%s: Global Offset Table overflow (used %ld, allowed %d)\n", |
827 | me->name, me->arch.got_count, MAX_GOTS); | ||
826 | return -EINVAL; | 828 | return -EINVAL; |
827 | } | 829 | } |
828 | 830 | ||
@@ -850,10 +852,11 @@ int module_finalize(const Elf_Ehdr *hdr, | |||
850 | nsyms = newptr - (Elf_Sym *)symhdr->sh_addr; | 852 | nsyms = newptr - (Elf_Sym *)symhdr->sh_addr; |
851 | DEBUGP("NEW num_symtab %lu\n", nsyms); | 853 | DEBUGP("NEW num_symtab %lu\n", nsyms); |
852 | symhdr->sh_size = nsyms * sizeof(Elf_Sym); | 854 | symhdr->sh_size = nsyms * sizeof(Elf_Sym); |
853 | return 0; | 855 | return module_bug_finalize(hdr, sechdrs, me); |
854 | } | 856 | } |
855 | 857 | ||
856 | void module_arch_cleanup(struct module *mod) | 858 | void module_arch_cleanup(struct module *mod) |
857 | { | 859 | { |
858 | deregister_unwind_table(mod); | 860 | deregister_unwind_table(mod); |
861 | module_bug_cleanup(mod); | ||
859 | } | 862 | } |
diff --git a/arch/parisc/kernel/pacache.S b/arch/parisc/kernel/pacache.S index e81c9937d10a..90b240878520 100644 --- a/arch/parisc/kernel/pacache.S +++ b/arch/parisc/kernel/pacache.S | |||
@@ -27,31 +27,21 @@ | |||
27 | */ | 27 | */ |
28 | 28 | ||
29 | #ifdef CONFIG_64BIT | 29 | #ifdef CONFIG_64BIT |
30 | #define ADDIB addib,* | ||
31 | #define CMPB cmpb,* | ||
32 | #define ANDCM andcm,* | ||
33 | |||
34 | .level 2.0w | 30 | .level 2.0w |
35 | #else | 31 | #else |
36 | #define ADDIB addib, | ||
37 | #define CMPB cmpb, | ||
38 | #define ANDCM andcm | ||
39 | |||
40 | .level 2.0 | 32 | .level 2.0 |
41 | #endif | 33 | #endif |
42 | 34 | ||
43 | |||
44 | #include <asm/psw.h> | 35 | #include <asm/psw.h> |
45 | #include <asm/assembly.h> | 36 | #include <asm/assembly.h> |
46 | #include <asm/pgtable.h> | 37 | #include <asm/pgtable.h> |
47 | #include <asm/cache.h> | 38 | #include <asm/cache.h> |
39 | #include <linux/linkage.h> | ||
48 | 40 | ||
49 | .text | 41 | .text |
50 | .align 128 | 42 | .align 128 |
51 | 43 | ||
52 | .export flush_tlb_all_local,code | 44 | ENTRY(flush_tlb_all_local) |
53 | |||
54 | flush_tlb_all_local: | ||
55 | .proc | 45 | .proc |
56 | .callinfo NO_CALLS | 46 | .callinfo NO_CALLS |
57 | .entry | 47 | .entry |
@@ -200,11 +190,11 @@ fdtdone: | |||
200 | 190 | ||
201 | .exit | 191 | .exit |
202 | .procend | 192 | .procend |
193 | ENDPROC(flush_tlb_all_local) | ||
203 | 194 | ||
204 | .export flush_instruction_cache_local,code | ||
205 | .import cache_info,data | 195 | .import cache_info,data |
206 | 196 | ||
207 | flush_instruction_cache_local: | 197 | ENTRY(flush_instruction_cache_local) |
208 | .proc | 198 | .proc |
209 | .callinfo NO_CALLS | 199 | .callinfo NO_CALLS |
210 | .entry | 200 | .entry |
@@ -241,11 +231,11 @@ fisync: | |||
241 | .exit | 231 | .exit |
242 | 232 | ||
243 | .procend | 233 | .procend |
234 | ENDPROC(flush_instruction_cache_local) | ||
244 | 235 | ||
245 | .export flush_data_cache_local, code | ||
246 | .import cache_info, data | ||
247 | 236 | ||
248 | flush_data_cache_local: | 237 | .import cache_info, data |
238 | ENTRY(flush_data_cache_local) | ||
249 | .proc | 239 | .proc |
250 | .callinfo NO_CALLS | 240 | .callinfo NO_CALLS |
251 | .entry | 241 | .entry |
@@ -283,11 +273,11 @@ fdsync: | |||
283 | .exit | 273 | .exit |
284 | 274 | ||
285 | .procend | 275 | .procend |
276 | ENDPROC(flush_data_cache_local) | ||
286 | 277 | ||
287 | .export copy_user_page_asm,code | ||
288 | .align 16 | 278 | .align 16 |
289 | 279 | ||
290 | copy_user_page_asm: | 280 | ENTRY(copy_user_page_asm) |
291 | .proc | 281 | .proc |
292 | .callinfo NO_CALLS | 282 | .callinfo NO_CALLS |
293 | .entry | 283 | .entry |
@@ -409,6 +399,7 @@ copy_user_page_asm: | |||
409 | .exit | 399 | .exit |
410 | 400 | ||
411 | .procend | 401 | .procend |
402 | ENDPROC(copy_user_page_asm) | ||
412 | 403 | ||
413 | /* | 404 | /* |
414 | * NOTE: Code in clear_user_page has a hard coded dependency on the | 405 | * NOTE: Code in clear_user_page has a hard coded dependency on the |
@@ -446,9 +437,7 @@ copy_user_page_asm: | |||
446 | * lobby for such a change. | 437 | * lobby for such a change. |
447 | */ | 438 | */ |
448 | 439 | ||
449 | .export copy_user_page_asm,code | 440 | ENTRY(copy_user_page_asm) |
450 | |||
451 | copy_user_page_asm: | ||
452 | .proc | 441 | .proc |
453 | .callinfo NO_CALLS | 442 | .callinfo NO_CALLS |
454 | .entry | 443 | .entry |
@@ -534,11 +523,10 @@ copy_user_page_asm: | |||
534 | .exit | 523 | .exit |
535 | 524 | ||
536 | .procend | 525 | .procend |
526 | ENDPROC(copy_user_page_asm) | ||
537 | #endif | 527 | #endif |
538 | 528 | ||
539 | .export __clear_user_page_asm,code | 529 | ENTRY(__clear_user_page_asm) |
540 | |||
541 | __clear_user_page_asm: | ||
542 | .proc | 530 | .proc |
543 | .callinfo NO_CALLS | 531 | .callinfo NO_CALLS |
544 | .entry | 532 | .entry |
@@ -618,10 +606,9 @@ __clear_user_page_asm: | |||
618 | .exit | 606 | .exit |
619 | 607 | ||
620 | .procend | 608 | .procend |
609 | ENDPROC(__clear_user_page_asm) | ||
621 | 610 | ||
622 | .export flush_kernel_dcache_page_asm | 611 | ENTRY(flush_kernel_dcache_page_asm) |
623 | |||
624 | flush_kernel_dcache_page_asm: | ||
625 | .proc | 612 | .proc |
626 | .callinfo NO_CALLS | 613 | .callinfo NO_CALLS |
627 | .entry | 614 | .entry |
@@ -662,10 +649,9 @@ flush_kernel_dcache_page_asm: | |||
662 | .exit | 649 | .exit |
663 | 650 | ||
664 | .procend | 651 | .procend |
652 | ENDPROC(flush_kernel_dcache_page_asm) | ||
665 | 653 | ||
666 | .export flush_user_dcache_page | 654 | ENTRY(flush_user_dcache_page) |
667 | |||
668 | flush_user_dcache_page: | ||
669 | .proc | 655 | .proc |
670 | .callinfo NO_CALLS | 656 | .callinfo NO_CALLS |
671 | .entry | 657 | .entry |
@@ -706,10 +692,9 @@ flush_user_dcache_page: | |||
706 | .exit | 692 | .exit |
707 | 693 | ||
708 | .procend | 694 | .procend |
695 | ENDPROC(flush_user_dcache_page) | ||
709 | 696 | ||
710 | .export flush_user_icache_page | 697 | ENTRY(flush_user_icache_page) |
711 | |||
712 | flush_user_icache_page: | ||
713 | .proc | 698 | .proc |
714 | .callinfo NO_CALLS | 699 | .callinfo NO_CALLS |
715 | .entry | 700 | .entry |
@@ -750,11 +735,10 @@ flush_user_icache_page: | |||
750 | .exit | 735 | .exit |
751 | 736 | ||
752 | .procend | 737 | .procend |
738 | ENDPROC(flush_user_icache_page) | ||
753 | 739 | ||
754 | 740 | ||
755 | .export purge_kernel_dcache_page | 741 | ENTRY(purge_kernel_dcache_page) |
756 | |||
757 | purge_kernel_dcache_page: | ||
758 | .proc | 742 | .proc |
759 | .callinfo NO_CALLS | 743 | .callinfo NO_CALLS |
760 | .entry | 744 | .entry |
@@ -794,15 +778,14 @@ purge_kernel_dcache_page: | |||
794 | .exit | 778 | .exit |
795 | 779 | ||
796 | .procend | 780 | .procend |
781 | ENDPROC(purge_kernel_dcache_page) | ||
797 | 782 | ||
798 | #if 0 | 783 | #if 0 |
799 | /* Currently not used, but it still is a possible alternate | 784 | /* Currently not used, but it still is a possible alternate |
800 | * solution. | 785 | * solution. |
801 | */ | 786 | */ |
802 | 787 | ||
803 | .export flush_alias_page | 788 | ENTRY(flush_alias_page) |
804 | |||
805 | flush_alias_page: | ||
806 | .proc | 789 | .proc |
807 | .callinfo NO_CALLS | 790 | .callinfo NO_CALLS |
808 | .entry | 791 | .entry |
@@ -882,10 +865,9 @@ flush_user_dcache_range_asm: | |||
882 | .exit | 865 | .exit |
883 | 866 | ||
884 | .procend | 867 | .procend |
868 | ENDPROC(flush_alias_page) | ||
885 | 869 | ||
886 | .export flush_kernel_dcache_range_asm | 870 | ENTRY(flush_kernel_dcache_range_asm) |
887 | |||
888 | flush_kernel_dcache_range_asm: | ||
889 | .proc | 871 | .proc |
890 | .callinfo NO_CALLS | 872 | .callinfo NO_CALLS |
891 | .entry | 873 | .entry |
@@ -905,10 +887,9 @@ flush_kernel_dcache_range_asm: | |||
905 | .exit | 887 | .exit |
906 | 888 | ||
907 | .procend | 889 | .procend |
890 | ENDPROC(flush_kernel_dcache_range_asm) | ||
908 | 891 | ||
909 | .export flush_user_icache_range_asm | 892 | ENTRY(flush_user_icache_range_asm) |
910 | |||
911 | flush_user_icache_range_asm: | ||
912 | .proc | 893 | .proc |
913 | .callinfo NO_CALLS | 894 | .callinfo NO_CALLS |
914 | .entry | 895 | .entry |
@@ -927,10 +908,9 @@ flush_user_icache_range_asm: | |||
927 | .exit | 908 | .exit |
928 | 909 | ||
929 | .procend | 910 | .procend |
911 | ENDPROC(flush_user_icache_range_asm) | ||
930 | 912 | ||
931 | .export flush_kernel_icache_page | 913 | ENTRY(flush_kernel_icache_page) |
932 | |||
933 | flush_kernel_icache_page: | ||
934 | .proc | 914 | .proc |
935 | .callinfo NO_CALLS | 915 | .callinfo NO_CALLS |
936 | .entry | 916 | .entry |
@@ -971,10 +951,9 @@ flush_kernel_icache_page: | |||
971 | .exit | 951 | .exit |
972 | 952 | ||
973 | .procend | 953 | .procend |
954 | ENDPROC(flush_kernel_icache_page) | ||
974 | 955 | ||
975 | .export flush_kernel_icache_range_asm | 956 | ENTRY(flush_kernel_icache_range_asm) |
976 | |||
977 | flush_kernel_icache_range_asm: | ||
978 | .proc | 957 | .proc |
979 | .callinfo NO_CALLS | 958 | .callinfo NO_CALLS |
980 | .entry | 959 | .entry |
@@ -992,14 +971,13 @@ flush_kernel_icache_range_asm: | |||
992 | nop | 971 | nop |
993 | .exit | 972 | .exit |
994 | .procend | 973 | .procend |
974 | ENDPROC(flush_kernel_icache_range_asm) | ||
995 | 975 | ||
996 | /* align should cover use of rfi in disable_sr_hashing_asm and | 976 | /* align should cover use of rfi in disable_sr_hashing_asm and |
997 | * srdis_done. | 977 | * srdis_done. |
998 | */ | 978 | */ |
999 | .align 256 | 979 | .align 256 |
1000 | .export disable_sr_hashing_asm,code | 980 | ENTRY(disable_sr_hashing_asm) |
1001 | |||
1002 | disable_sr_hashing_asm: | ||
1003 | .proc | 981 | .proc |
1004 | .callinfo NO_CALLS | 982 | .callinfo NO_CALLS |
1005 | .entry | 983 | .entry |
@@ -1088,5 +1066,6 @@ srdis_done: | |||
1088 | .exit | 1066 | .exit |
1089 | 1067 | ||
1090 | .procend | 1068 | .procend |
1069 | ENDPROC(disable_sr_hashing_asm) | ||
1091 | 1070 | ||
1092 | .end | 1071 | .end |
diff --git a/arch/parisc/kernel/parisc_ksyms.c b/arch/parisc/kernel/parisc_ksyms.c index 8f6a0b312f7a..7aca704e96f0 100644 --- a/arch/parisc/kernel/parisc_ksyms.c +++ b/arch/parisc/kernel/parisc_ksyms.c | |||
@@ -7,7 +7,7 @@ | |||
7 | * Copyright (C) 2001-2003 Grant Grundler <grundler with parisc-linux.org> | 7 | * Copyright (C) 2001-2003 Grant Grundler <grundler with parisc-linux.org> |
8 | * Copyright (C) 2002-2003 Matthew Wilcox <willy at parisc-linux.org> | 8 | * Copyright (C) 2002-2003 Matthew Wilcox <willy at parisc-linux.org> |
9 | * Copyright (C) 2002 Randolph Chung <tausq at parisc-linux.org> | 9 | * Copyright (C) 2002 Randolph Chung <tausq at parisc-linux.org> |
10 | * Copyright (C) 2002-2003 Helge Deller <deller with parisc-linux.org> | 10 | * Copyright (C) 2002-2007 Helge Deller <deller with parisc-linux.org> |
11 | * | 11 | * |
12 | * This program is free software; you can redistribute it and/or modify | 12 | * This program is free software; you can redistribute it and/or modify |
13 | * it under the terms of the GNU General Public License as published by | 13 | * it under the terms of the GNU General Public License as published by |
@@ -38,7 +38,7 @@ EXPORT_SYMBOL(__cmpxchg_u32); | |||
38 | #ifdef CONFIG_SMP | 38 | #ifdef CONFIG_SMP |
39 | EXPORT_SYMBOL(__atomic_hash); | 39 | EXPORT_SYMBOL(__atomic_hash); |
40 | #endif | 40 | #endif |
41 | #ifdef __LP64__ | 41 | #ifdef CONFIG_64BIT |
42 | EXPORT_SYMBOL(__xchg64); | 42 | EXPORT_SYMBOL(__xchg64); |
43 | EXPORT_SYMBOL(__cmpxchg_u64); | 43 | EXPORT_SYMBOL(__cmpxchg_u64); |
44 | #endif | 44 | #endif |
@@ -58,7 +58,7 @@ EXPORT_SYMBOL(fixup_get_user_skip_2); | |||
58 | EXPORT_SYMBOL(fixup_put_user_skip_1); | 58 | EXPORT_SYMBOL(fixup_put_user_skip_1); |
59 | EXPORT_SYMBOL(fixup_put_user_skip_2); | 59 | EXPORT_SYMBOL(fixup_put_user_skip_2); |
60 | 60 | ||
61 | #ifndef __LP64__ | 61 | #ifndef CONFIG_64BIT |
62 | /* Needed so insmod can set dp value */ | 62 | /* Needed so insmod can set dp value */ |
63 | extern int $global$; | 63 | extern int $global$; |
64 | EXPORT_SYMBOL($global$); | 64 | EXPORT_SYMBOL($global$); |
@@ -135,7 +135,7 @@ EXPORT_SYMBOL(__muldi3); | |||
135 | asmlinkage void * __canonicalize_funcptr_for_compare(void *); | 135 | asmlinkage void * __canonicalize_funcptr_for_compare(void *); |
136 | EXPORT_SYMBOL(__canonicalize_funcptr_for_compare); | 136 | EXPORT_SYMBOL(__canonicalize_funcptr_for_compare); |
137 | 137 | ||
138 | #ifdef __LP64__ | 138 | #ifdef CONFIG_64BIT |
139 | extern void __divdi3(void); | 139 | extern void __divdi3(void); |
140 | extern void __udivdi3(void); | 140 | extern void __udivdi3(void); |
141 | extern void __umoddi3(void); | 141 | extern void __umoddi3(void); |
@@ -147,7 +147,7 @@ EXPORT_SYMBOL(__umoddi3); | |||
147 | EXPORT_SYMBOL(__moddi3); | 147 | EXPORT_SYMBOL(__moddi3); |
148 | #endif | 148 | #endif |
149 | 149 | ||
150 | #ifndef __LP64__ | 150 | #ifndef CONFIG_64BIT |
151 | extern void $$dyncall(void); | 151 | extern void $$dyncall(void); |
152 | EXPORT_SYMBOL($$dyncall); | 152 | EXPORT_SYMBOL($$dyncall); |
153 | #endif | 153 | #endif |
diff --git a/arch/parisc/kernel/pci-dma.c b/arch/parisc/kernel/pci-dma.c index a6caf1073085..0c3aecb85a5c 100644 --- a/arch/parisc/kernel/pci-dma.c +++ b/arch/parisc/kernel/pci-dma.c | |||
@@ -342,7 +342,7 @@ pcxl_dma_init(void) | |||
342 | pcxl_res_map = (char *)__get_free_pages(GFP_KERNEL, | 342 | pcxl_res_map = (char *)__get_free_pages(GFP_KERNEL, |
343 | get_order(pcxl_res_size)); | 343 | get_order(pcxl_res_size)); |
344 | memset(pcxl_res_map, 0, pcxl_res_size); | 344 | memset(pcxl_res_map, 0, pcxl_res_size); |
345 | proc_gsc_root = proc_mkdir("gsc", 0); | 345 | proc_gsc_root = proc_mkdir("gsc", NULL); |
346 | if (!proc_gsc_root) | 346 | if (!proc_gsc_root) |
347 | printk(KERN_WARNING | 347 | printk(KERN_WARNING |
348 | "pcxl_dma_init: Unable to create gsc /proc dir entry\n"); | 348 | "pcxl_dma_init: Unable to create gsc /proc dir entry\n"); |
diff --git a/arch/parisc/kernel/pci.c b/arch/parisc/kernel/pci.c index 199887a61c76..563df0072dee 100644 --- a/arch/parisc/kernel/pci.c +++ b/arch/parisc/kernel/pci.c | |||
@@ -200,8 +200,8 @@ static void | |||
200 | pcibios_link_hba_resources( struct resource *hba_res, struct resource *r) | 200 | pcibios_link_hba_resources( struct resource *hba_res, struct resource *r) |
201 | { | 201 | { |
202 | if (!r->parent) { | 202 | if (!r->parent) { |
203 | printk(KERN_EMERG "PCI: resource not parented! [%lx-%lx]\n", | 203 | printk(KERN_EMERG "PCI: resource not parented! [%p-%p]\n", |
204 | r->start, r->end); | 204 | (void*) r->start, (void*) r->end); |
205 | r->parent = hba_res; | 205 | r->parent = hba_res; |
206 | 206 | ||
207 | /* reverse link is harder *sigh* */ | 207 | /* reverse link is harder *sigh* */ |
diff --git a/arch/parisc/kernel/perf_asm.S b/arch/parisc/kernel/perf_asm.S index 5e7bb90e7e08..43874ca3ed67 100644 --- a/arch/parisc/kernel/perf_asm.S +++ b/arch/parisc/kernel/perf_asm.S | |||
@@ -20,6 +20,7 @@ | |||
20 | */ | 20 | */ |
21 | 21 | ||
22 | #include <asm/assembly.h> | 22 | #include <asm/assembly.h> |
23 | #include <linux/linkage.h> | ||
23 | 24 | ||
24 | #ifdef CONFIG_64BIT | 25 | #ifdef CONFIG_64BIT |
25 | .level 2.0w | 26 | .level 2.0w |
@@ -41,10 +42,8 @@ | |||
41 | ; starting/stopping the coprocessor with the pmenb/pmdis. | 42 | ; starting/stopping the coprocessor with the pmenb/pmdis. |
42 | ; | 43 | ; |
43 | .text | 44 | .text |
44 | .align 32 | ||
45 | 45 | ||
46 | .export perf_intrigue_enable_perf_counters,code | 46 | ENTRY(perf_intrigue_enable_perf_counters) |
47 | perf_intrigue_enable_perf_counters: | ||
48 | .proc | 47 | .proc |
49 | .callinfo frame=0,NO_CALLS | 48 | .callinfo frame=0,NO_CALLS |
50 | .entry | 49 | .entry |
@@ -69,9 +68,9 @@ perf_intrigue_enable_perf_counters: | |||
69 | nop | 68 | nop |
70 | .exit | 69 | .exit |
71 | .procend | 70 | .procend |
71 | ENDPROC(perf_intrigue_enable_perf_counters) | ||
72 | 72 | ||
73 | .export perf_intrigue_disable_perf_counters,code | 73 | ENTRY(perf_intrigue_disable_perf_counters) |
74 | perf_intrigue_disable_perf_counters: | ||
75 | .proc | 74 | .proc |
76 | .callinfo frame=0,NO_CALLS | 75 | .callinfo frame=0,NO_CALLS |
77 | .entry | 76 | .entry |
@@ -86,6 +85,7 @@ perf_intrigue_disable_perf_counters: | |||
86 | mtctl %r26,ccr ; turn off performance coprocessor | 85 | mtctl %r26,ccr ; turn off performance coprocessor |
87 | .exit | 86 | .exit |
88 | .procend | 87 | .procend |
88 | ENDPROC(perf_intrigue_disable_perf_counters) | ||
89 | 89 | ||
90 | ;*********************************************************************** | 90 | ;*********************************************************************** |
91 | ;* | 91 | ;* |
@@ -117,8 +117,7 @@ perf_intrigue_disable_perf_counters: | |||
117 | ;* | 117 | ;* |
118 | ;*********************************************************************** | 118 | ;*********************************************************************** |
119 | 119 | ||
120 | .export perf_rdr_shift_in_W,code | 120 | ENTRY(perf_rdr_shift_in_W) |
121 | perf_rdr_shift_in_W: | ||
122 | .proc | 121 | .proc |
123 | .callinfo frame=0,NO_CALLS | 122 | .callinfo frame=0,NO_CALLS |
124 | .entry | 123 | .entry |
@@ -550,6 +549,7 @@ perf_rdr_shift_in_W_leave: | |||
550 | .exit | 549 | .exit |
551 | MTDIAG_2 (24) ; restore DR2 | 550 | MTDIAG_2 (24) ; restore DR2 |
552 | .procend | 551 | .procend |
552 | ENDPROC(perf_rdr_shift_in_W) | ||
553 | 553 | ||
554 | 554 | ||
555 | ;*********************************************************************** | 555 | ;*********************************************************************** |
@@ -575,8 +575,7 @@ perf_rdr_shift_in_W_leave: | |||
575 | ;* | 575 | ;* |
576 | ;*********************************************************************** | 576 | ;*********************************************************************** |
577 | 577 | ||
578 | .export perf_rdr_shift_out_W,code | 578 | ENTRY(perf_rdr_shift_out_W) |
579 | perf_rdr_shift_out_W: | ||
580 | .proc | 579 | .proc |
581 | .callinfo frame=0,NO_CALLS | 580 | .callinfo frame=0,NO_CALLS |
582 | .entry | 581 | .entry |
@@ -983,6 +982,7 @@ perf_rdr_shift_out_W_leave: | |||
983 | .exit | 982 | .exit |
984 | MTDIAG_2 (23) ; restore DR2 | 983 | MTDIAG_2 (23) ; restore DR2 |
985 | .procend | 984 | .procend |
985 | ENDPROC(perf_rdr_shift_out_W) | ||
986 | 986 | ||
987 | 987 | ||
988 | ;*********************************************************************** | 988 | ;*********************************************************************** |
@@ -1012,8 +1012,7 @@ perf_rdr_shift_out_W_leave: | |||
1012 | ;* | 1012 | ;* |
1013 | ;*********************************************************************** | 1013 | ;*********************************************************************** |
1014 | 1014 | ||
1015 | .export perf_rdr_shift_in_U,code | 1015 | ENTRY(perf_rdr_shift_in_U) |
1016 | perf_rdr_shift_in_U: | ||
1017 | .proc | 1016 | .proc |
1018 | .callinfo frame=0,NO_CALLS | 1017 | .callinfo frame=0,NO_CALLS |
1019 | .entry | 1018 | .entry |
@@ -1343,6 +1342,7 @@ perf_rdr_shift_in_U_leave: | |||
1343 | .exit | 1342 | .exit |
1344 | MTDIAG_2 (24) ; restore DR2 | 1343 | MTDIAG_2 (24) ; restore DR2 |
1345 | .procend | 1344 | .procend |
1345 | ENDPROC(perf_rdr_shift_in_U) | ||
1346 | 1346 | ||
1347 | ;*********************************************************************** | 1347 | ;*********************************************************************** |
1348 | ;* | 1348 | ;* |
@@ -1369,8 +1369,7 @@ perf_rdr_shift_in_U_leave: | |||
1369 | ;* | 1369 | ;* |
1370 | ;*********************************************************************** | 1370 | ;*********************************************************************** |
1371 | 1371 | ||
1372 | .export perf_rdr_shift_out_U,code | 1372 | ENTRY(perf_rdr_shift_out_U) |
1373 | perf_rdr_shift_out_U: | ||
1374 | .proc | 1373 | .proc |
1375 | .callinfo frame=0,NO_CALLS | 1374 | .callinfo frame=0,NO_CALLS |
1376 | .entry | 1375 | .entry |
@@ -1687,4 +1686,5 @@ perf_rdr_shift_out_U_leave: | |||
1687 | .exit | 1686 | .exit |
1688 | MTDIAG_2 (23) ; restore DR2 | 1687 | MTDIAG_2 (23) ; restore DR2 |
1689 | .procend | 1688 | .procend |
1689 | ENDPROC(perf_rdr_shift_out_U) | ||
1690 | 1690 | ||
diff --git a/arch/parisc/kernel/process.c b/arch/parisc/kernel/process.c index 2f9f9dfa66f7..0dd3847f494c 100644 --- a/arch/parisc/kernel/process.c +++ b/arch/parisc/kernel/process.c | |||
@@ -13,7 +13,7 @@ | |||
13 | * Copyright (C) 2000 Grant Grundler <grundler with parisc-linux.org> | 13 | * Copyright (C) 2000 Grant Grundler <grundler with parisc-linux.org> |
14 | * Copyright (C) 2001 Alan Modra <amodra at parisc-linux.org> | 14 | * Copyright (C) 2001 Alan Modra <amodra at parisc-linux.org> |
15 | * Copyright (C) 2001-2002 Ryan Bradetich <rbrad at parisc-linux.org> | 15 | * Copyright (C) 2001-2002 Ryan Bradetich <rbrad at parisc-linux.org> |
16 | * Copyright (C) 2001-2002 Helge Deller <deller at parisc-linux.org> | 16 | * Copyright (C) 2001-2007 Helge Deller <deller at parisc-linux.org> |
17 | * Copyright (C) 2002 Randolph Chung <tausq with parisc-linux.org> | 17 | * Copyright (C) 2002 Randolph Chung <tausq with parisc-linux.org> |
18 | * | 18 | * |
19 | * | 19 | * |
@@ -303,7 +303,7 @@ copy_thread(int nr, unsigned long clone_flags, unsigned long usp, | |||
303 | * Copy function and argument to be called from | 303 | * Copy function and argument to be called from |
304 | * ret_from_kernel_thread. | 304 | * ret_from_kernel_thread. |
305 | */ | 305 | */ |
306 | #ifdef __LP64__ | 306 | #ifdef CONFIG_64BIT |
307 | cregs->gr[27] = pregs->gr[27]; | 307 | cregs->gr[27] = pregs->gr[27]; |
308 | #endif | 308 | #endif |
309 | cregs->gr[26] = pregs->gr[26]; | 309 | cregs->gr[26] = pregs->gr[26]; |
@@ -355,8 +355,8 @@ asmlinkage int sys_execve(struct pt_regs *regs) | |||
355 | error = PTR_ERR(filename); | 355 | error = PTR_ERR(filename); |
356 | if (IS_ERR(filename)) | 356 | if (IS_ERR(filename)) |
357 | goto out; | 357 | goto out; |
358 | error = do_execve(filename, (char __user **) regs->gr[25], | 358 | error = do_execve(filename, (char __user * __user *) regs->gr[25], |
359 | (char __user **) regs->gr[24], regs); | 359 | (char __user * __user *) regs->gr[24], regs); |
360 | if (error == 0) { | 360 | if (error == 0) { |
361 | task_lock(current); | 361 | task_lock(current); |
362 | current->ptrace &= ~PT_DTRACE; | 362 | current->ptrace &= ~PT_DTRACE; |
diff --git a/arch/parisc/kernel/processor.c b/arch/parisc/kernel/processor.c index fb81e5687e7c..7c056dcebf55 100644 --- a/arch/parisc/kernel/processor.c +++ b/arch/parisc/kernel/processor.c | |||
@@ -93,7 +93,7 @@ static int __init processor_probe(struct parisc_device *dev) | |||
93 | cpuid = boot_cpu_data.cpu_count; | 93 | cpuid = boot_cpu_data.cpu_count; |
94 | txn_addr = dev->hpa.start; /* for legacy PDC */ | 94 | txn_addr = dev->hpa.start; /* for legacy PDC */ |
95 | 95 | ||
96 | #ifdef __LP64__ | 96 | #ifdef CONFIG_64BIT |
97 | if (is_pdc_pat()) { | 97 | if (is_pdc_pat()) { |
98 | ulong status; | 98 | ulong status; |
99 | unsigned long bytecnt; | 99 | unsigned long bytecnt; |
@@ -153,8 +153,6 @@ static int __init processor_probe(struct parisc_device *dev) | |||
153 | p->cpuid = cpuid; /* save CPU id */ | 153 | p->cpuid = cpuid; /* save CPU id */ |
154 | p->txn_addr = txn_addr; /* save CPU IRQ address */ | 154 | p->txn_addr = txn_addr; /* save CPU IRQ address */ |
155 | #ifdef CONFIG_SMP | 155 | #ifdef CONFIG_SMP |
156 | spin_lock_init(&p->lock); | ||
157 | |||
158 | /* | 156 | /* |
159 | ** FIXME: review if any other initialization is clobbered | 157 | ** FIXME: review if any other initialization is clobbered |
160 | ** for boot_cpu by the above memset(). | 158 | ** for boot_cpu by the above memset(). |
@@ -311,11 +309,11 @@ int __init init_per_cpu(int cpunum) | |||
311 | } else { | 309 | } else { |
312 | printk(KERN_WARNING "WARNING: No FP CoProcessor?!" | 310 | printk(KERN_WARNING "WARNING: No FP CoProcessor?!" |
313 | " (coproc_cfg.ccr_functional == 0x%lx, expected 0xc0)\n" | 311 | " (coproc_cfg.ccr_functional == 0x%lx, expected 0xc0)\n" |
314 | #ifdef __LP64__ | 312 | #ifdef CONFIG_64BIT |
315 | "Halting Machine - FP required\n" | 313 | "Halting Machine - FP required\n" |
316 | #endif | 314 | #endif |
317 | , coproc_cfg.ccr_functional); | 315 | , coproc_cfg.ccr_functional); |
318 | #ifdef __LP64__ | 316 | #ifdef CONFIG_64BIT |
319 | mdelay(100); /* previous chars get pushed to console */ | 317 | mdelay(100); /* previous chars get pushed to console */ |
320 | panic("FP CoProc not reported"); | 318 | panic("FP CoProc not reported"); |
321 | #endif | 319 | #endif |
@@ -339,9 +337,6 @@ show_cpuinfo (struct seq_file *m, void *v) | |||
339 | #ifdef CONFIG_SMP | 337 | #ifdef CONFIG_SMP |
340 | if (0 == cpu_data[n].hpa) | 338 | if (0 == cpu_data[n].hpa) |
341 | continue; | 339 | continue; |
342 | #ifdef ENTRY_SYS_CPUS | ||
343 | #error iCOD support wants to show CPU state here | ||
344 | #endif | ||
345 | #endif | 340 | #endif |
346 | seq_printf(m, "processor\t: %d\n" | 341 | seq_printf(m, "processor\t: %d\n" |
347 | "cpu family\t: PA-RISC %s\n", | 342 | "cpu family\t: PA-RISC %s\n", |
diff --git a/arch/parisc/kernel/ptrace.c b/arch/parisc/kernel/ptrace.c index 3f28de974556..0d0d617b6f21 100644 --- a/arch/parisc/kernel/ptrace.c +++ b/arch/parisc/kernel/ptrace.c | |||
@@ -36,7 +36,7 @@ | |||
36 | #define DBG(x...) | 36 | #define DBG(x...) |
37 | #endif | 37 | #endif |
38 | 38 | ||
39 | #ifdef __LP64__ | 39 | #ifdef CONFIG_64BIT |
40 | 40 | ||
41 | /* This function is needed to translate 32 bit pt_regs offsets in to | 41 | /* This function is needed to translate 32 bit pt_regs offsets in to |
42 | * 64 bit pt_regs offsets. For example, a 32 bit gdb under a 64 bit kernel | 42 | * 64 bit pt_regs offsets. For example, a 32 bit gdb under a 64 bit kernel |
@@ -90,7 +90,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
90 | case PTRACE_PEEKDATA: { | 90 | case PTRACE_PEEKDATA: { |
91 | int copied; | 91 | int copied; |
92 | 92 | ||
93 | #ifdef __LP64__ | 93 | #ifdef CONFIG_64BIT |
94 | if (__is_compat_task(child)) { | 94 | if (__is_compat_task(child)) { |
95 | unsigned int tmp; | 95 | unsigned int tmp; |
96 | 96 | ||
@@ -122,7 +122,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
122 | case PTRACE_POKETEXT: /* write the word at location addr. */ | 122 | case PTRACE_POKETEXT: /* write the word at location addr. */ |
123 | case PTRACE_POKEDATA: | 123 | case PTRACE_POKEDATA: |
124 | ret = 0; | 124 | ret = 0; |
125 | #ifdef __LP64__ | 125 | #ifdef CONFIG_64BIT |
126 | if (__is_compat_task(child)) { | 126 | if (__is_compat_task(child)) { |
127 | unsigned int tmp = (unsigned int)data; | 127 | unsigned int tmp = (unsigned int)data; |
128 | DBG("sys_ptrace(POKE%s, %d, %lx, %lx)\n", | 128 | DBG("sys_ptrace(POKE%s, %d, %lx, %lx)\n", |
@@ -145,7 +145,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
145 | processes, the kernel saves all regs on a syscall. */ | 145 | processes, the kernel saves all regs on a syscall. */ |
146 | case PTRACE_PEEKUSR: { | 146 | case PTRACE_PEEKUSR: { |
147 | ret = -EIO; | 147 | ret = -EIO; |
148 | #ifdef __LP64__ | 148 | #ifdef CONFIG_64BIT |
149 | if (__is_compat_task(child)) { | 149 | if (__is_compat_task(child)) { |
150 | unsigned int tmp; | 150 | unsigned int tmp; |
151 | 151 | ||
@@ -204,7 +204,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
204 | ret = 0; | 204 | ret = 0; |
205 | goto out_tsk; | 205 | goto out_tsk; |
206 | } | 206 | } |
207 | #ifdef __LP64__ | 207 | #ifdef CONFIG_64BIT |
208 | if (__is_compat_task(child)) { | 208 | if (__is_compat_task(child)) { |
209 | if (addr & (sizeof(int)-1)) | 209 | if (addr & (sizeof(int)-1)) |
210 | goto out_tsk; | 210 | goto out_tsk; |
diff --git a/arch/parisc/kernel/real2.S b/arch/parisc/kernel/real2.S index 789061f6ceb4..7a92695d95a6 100644 --- a/arch/parisc/kernel/real2.S +++ b/arch/parisc/kernel/real2.S | |||
@@ -11,6 +11,8 @@ | |||
11 | #include <asm/psw.h> | 11 | #include <asm/psw.h> |
12 | #include <asm/assembly.h> | 12 | #include <asm/assembly.h> |
13 | 13 | ||
14 | #include <linux/linkage.h> | ||
15 | |||
14 | .section .bss | 16 | .section .bss |
15 | .export real_stack | 17 | .export real_stack |
16 | .export real32_stack | 18 | .export real32_stack |
@@ -39,8 +41,6 @@ save_cr_end: | |||
39 | 41 | ||
40 | .text | 42 | .text |
41 | 43 | ||
42 | .export real32_call_asm | ||
43 | |||
44 | /* unsigned long real32_call_asm(unsigned int *sp, | 44 | /* unsigned long real32_call_asm(unsigned int *sp, |
45 | * unsigned int *arg0p, | 45 | * unsigned int *arg0p, |
46 | * unsigned int iodc_fn) | 46 | * unsigned int iodc_fn) |
@@ -49,7 +49,7 @@ save_cr_end: | |||
49 | * iodc_fn is the IODC function to call | 49 | * iodc_fn is the IODC function to call |
50 | */ | 50 | */ |
51 | 51 | ||
52 | real32_call_asm: | 52 | ENTRY(real32_call_asm) |
53 | STREG %rp, -RP_OFFSET(%sp) /* save RP */ | 53 | STREG %rp, -RP_OFFSET(%sp) /* save RP */ |
54 | #ifdef CONFIG_64BIT | 54 | #ifdef CONFIG_64BIT |
55 | callee_save | 55 | callee_save |
@@ -107,6 +107,7 @@ ric_ret: | |||
107 | LDREG -RP_OFFSET(%sp), %rp /* restore RP */ | 107 | LDREG -RP_OFFSET(%sp), %rp /* restore RP */ |
108 | bv 0(%rp) | 108 | bv 0(%rp) |
109 | nop | 109 | nop |
110 | ENDPROC(real32_call_asm) | ||
110 | 111 | ||
111 | 112 | ||
112 | # define PUSH_CR(r, where) mfctl r, %r1 ! STREG,ma %r1, REG_SZ(where) | 113 | # define PUSH_CR(r, where) mfctl r, %r1 ! STREG,ma %r1, REG_SZ(where) |
@@ -218,7 +219,6 @@ rfi_r2v_1: | |||
218 | /************************ 64-bit real-mode calls ***********************/ | 219 | /************************ 64-bit real-mode calls ***********************/ |
219 | /* This is only usable in wide kernels right now and will probably stay so */ | 220 | /* This is only usable in wide kernels right now and will probably stay so */ |
220 | .text | 221 | .text |
221 | .export real64_call_asm | ||
222 | /* unsigned long real64_call_asm(unsigned long *sp, | 222 | /* unsigned long real64_call_asm(unsigned long *sp, |
223 | * unsigned long *arg0p, | 223 | * unsigned long *arg0p, |
224 | * unsigned long fn) | 224 | * unsigned long fn) |
@@ -226,7 +226,7 @@ rfi_r2v_1: | |||
226 | * arg0p points to where saved arg values may be found | 226 | * arg0p points to where saved arg values may be found |
227 | * iodc_fn is the IODC function to call | 227 | * iodc_fn is the IODC function to call |
228 | */ | 228 | */ |
229 | real64_call_asm: | 229 | ENTRY(real64_call_asm) |
230 | std %rp, -0x10(%sp) /* save RP */ | 230 | std %rp, -0x10(%sp) /* save RP */ |
231 | std %sp, -8(%arg0) /* save SP on real-mode stack */ | 231 | std %sp, -8(%arg0) /* save SP on real-mode stack */ |
232 | copy %arg0, %sp /* adopt the real-mode SP */ | 232 | copy %arg0, %sp /* adopt the real-mode SP */ |
@@ -272,19 +272,21 @@ r64_ret: | |||
272 | ldd -0x10(%sp), %rp /* restore RP */ | 272 | ldd -0x10(%sp), %rp /* restore RP */ |
273 | bv 0(%rp) | 273 | bv 0(%rp) |
274 | nop | 274 | nop |
275 | ENDPROC(real64_call_asm) | ||
275 | 276 | ||
276 | #endif | 277 | #endif |
277 | 278 | ||
278 | .export __canonicalize_funcptr_for_compare | ||
279 | .text | 279 | .text |
280 | /* http://lists.parisc-linux.org/hypermail/parisc-linux/10916.html | 280 | /* http://lists.parisc-linux.org/hypermail/parisc-linux/10916.html |
281 | ** GCC 3.3 and later has a new function in libgcc.a for | 281 | ** GCC 3.3 and later has a new function in libgcc.a for |
282 | ** comparing function pointers. | 282 | ** comparing function pointers. |
283 | */ | 283 | */ |
284 | __canonicalize_funcptr_for_compare: | 284 | ENTRY(__canonicalize_funcptr_for_compare) |
285 | #ifdef CONFIG_64BIT | 285 | #ifdef CONFIG_64BIT |
286 | bve (%r2) | 286 | bve (%r2) |
287 | #else | 287 | #else |
288 | bv %r0(%r2) | 288 | bv %r0(%r2) |
289 | #endif | 289 | #endif |
290 | copy %r26,%r28 | 290 | copy %r26,%r28 |
291 | ENDPROC(__canonicalize_funcptr_for_compare) | ||
292 | |||
diff --git a/arch/parisc/kernel/setup.c b/arch/parisc/kernel/setup.c index 74b3686dd1e0..bd2116e03f34 100644 --- a/arch/parisc/kernel/setup.c +++ b/arch/parisc/kernel/setup.c | |||
@@ -120,13 +120,13 @@ extern void collect_boot_cpu_data(void); | |||
120 | 120 | ||
121 | void __init setup_arch(char **cmdline_p) | 121 | void __init setup_arch(char **cmdline_p) |
122 | { | 122 | { |
123 | #ifdef __LP64__ | 123 | #ifdef CONFIG_64BIT |
124 | extern int parisc_narrow_firmware; | 124 | extern int parisc_narrow_firmware; |
125 | #endif | 125 | #endif |
126 | 126 | ||
127 | init_per_cpu(smp_processor_id()); /* Set Modes & Enable FP */ | 127 | init_per_cpu(smp_processor_id()); /* Set Modes & Enable FP */ |
128 | 128 | ||
129 | #ifdef __LP64__ | 129 | #ifdef CONFIG_64BIT |
130 | printk(KERN_INFO "The 64-bit Kernel has started...\n"); | 130 | printk(KERN_INFO "The 64-bit Kernel has started...\n"); |
131 | #else | 131 | #else |
132 | printk(KERN_INFO "The 32-bit Kernel has started...\n"); | 132 | printk(KERN_INFO "The 32-bit Kernel has started...\n"); |
@@ -134,7 +134,7 @@ void __init setup_arch(char **cmdline_p) | |||
134 | 134 | ||
135 | pdc_console_init(); | 135 | pdc_console_init(); |
136 | 136 | ||
137 | #ifdef __LP64__ | 137 | #ifdef CONFIG_64BIT |
138 | if(parisc_narrow_firmware) { | 138 | if(parisc_narrow_firmware) { |
139 | printk(KERN_INFO "Kernel is using PDC in 32-bit mode.\n"); | 139 | printk(KERN_INFO "Kernel is using PDC in 32-bit mode.\n"); |
140 | } | 140 | } |
diff --git a/arch/parisc/kernel/signal.c b/arch/parisc/kernel/signal.c index ee6653edeb7a..9784e405f849 100644 --- a/arch/parisc/kernel/signal.c +++ b/arch/parisc/kernel/signal.c | |||
@@ -59,58 +59,13 @@ | |||
59 | * this. */ | 59 | * this. */ |
60 | #define A(__x) ((unsigned long)(__x)) | 60 | #define A(__x) ((unsigned long)(__x)) |
61 | 61 | ||
62 | int do_signal(sigset_t *oldset, struct pt_regs *regs, int in_syscall); | ||
63 | |||
64 | /* | 62 | /* |
65 | * Atomically swap in the new signal mask, and wait for a signal. | 63 | * Atomically swap in the new signal mask, and wait for a signal. |
66 | */ | 64 | */ |
67 | #ifdef __LP64__ | 65 | #ifdef CONFIG_64BIT |
68 | #include "sys32.h" | 66 | #include "sys32.h" |
69 | #endif | 67 | #endif |
70 | 68 | ||
71 | asmlinkage int | ||
72 | sys_rt_sigsuspend(sigset_t __user *unewset, size_t sigsetsize, struct pt_regs *regs) | ||
73 | { | ||
74 | sigset_t saveset, newset; | ||
75 | #ifdef __LP64__ | ||
76 | compat_sigset_t newset32; | ||
77 | |||
78 | if (is_compat_task()) { | ||
79 | /* XXX: Don't preclude handling different sized sigset_t's. */ | ||
80 | if (sigsetsize != sizeof(compat_sigset_t)) | ||
81 | return -EINVAL; | ||
82 | if (copy_from_user(&newset32, (compat_sigset_t __user *)unewset, sizeof(newset32))) | ||
83 | return -EFAULT; | ||
84 | sigset_32to64(&newset,&newset32); | ||
85 | |||
86 | } else | ||
87 | #endif | ||
88 | { | ||
89 | /* XXX: Don't preclude handling different sized sigset_t's. */ | ||
90 | if (sigsetsize != sizeof(sigset_t)) | ||
91 | return -EINVAL; | ||
92 | |||
93 | if (copy_from_user(&newset, unewset, sizeof(newset))) | ||
94 | return -EFAULT; | ||
95 | } | ||
96 | |||
97 | sigdelsetmask(&newset, ~_BLOCKABLE); | ||
98 | |||
99 | spin_lock_irq(¤t->sighand->siglock); | ||
100 | saveset = current->blocked; | ||
101 | current->blocked = newset; | ||
102 | recalc_sigpending(); | ||
103 | spin_unlock_irq(¤t->sighand->siglock); | ||
104 | |||
105 | regs->gr[28] = -EINTR; | ||
106 | while (1) { | ||
107 | current->state = TASK_INTERRUPTIBLE; | ||
108 | schedule(); | ||
109 | if (do_signal(&saveset, regs, 1)) | ||
110 | return -EINTR; | ||
111 | } | ||
112 | } | ||
113 | |||
114 | /* | 69 | /* |
115 | * Do a signal return - restore sigcontext. | 70 | * Do a signal return - restore sigcontext. |
116 | */ | 71 | */ |
@@ -148,7 +103,7 @@ sys_rt_sigreturn(struct pt_regs *regs, int in_syscall) | |||
148 | sigset_t set; | 103 | sigset_t set; |
149 | unsigned long usp = (regs->gr[30] & ~(0x01UL)); | 104 | unsigned long usp = (regs->gr[30] & ~(0x01UL)); |
150 | unsigned long sigframe_size = PARISC_RT_SIGFRAME_SIZE; | 105 | unsigned long sigframe_size = PARISC_RT_SIGFRAME_SIZE; |
151 | #ifdef __LP64__ | 106 | #ifdef CONFIG_64BIT |
152 | compat_sigset_t compat_set; | 107 | compat_sigset_t compat_set; |
153 | struct compat_rt_sigframe __user * compat_frame; | 108 | struct compat_rt_sigframe __user * compat_frame; |
154 | 109 | ||
@@ -162,7 +117,7 @@ sys_rt_sigreturn(struct pt_regs *regs, int in_syscall) | |||
162 | (usp - sigframe_size); | 117 | (usp - sigframe_size); |
163 | DBG(2,"sys_rt_sigreturn: frame is %p\n", frame); | 118 | DBG(2,"sys_rt_sigreturn: frame is %p\n", frame); |
164 | 119 | ||
165 | #ifdef __LP64__ | 120 | #ifdef CONFIG_64BIT |
166 | compat_frame = (struct compat_rt_sigframe __user *)frame; | 121 | compat_frame = (struct compat_rt_sigframe __user *)frame; |
167 | 122 | ||
168 | if (is_compat_task()) { | 123 | if (is_compat_task()) { |
@@ -184,7 +139,7 @@ sys_rt_sigreturn(struct pt_regs *regs, int in_syscall) | |||
184 | spin_unlock_irq(¤t->sighand->siglock); | 139 | spin_unlock_irq(¤t->sighand->siglock); |
185 | 140 | ||
186 | /* Good thing we saved the old gr[30], eh? */ | 141 | /* Good thing we saved the old gr[30], eh? */ |
187 | #ifdef __LP64__ | 142 | #ifdef CONFIG_64BIT |
188 | if (is_compat_task()) { | 143 | if (is_compat_task()) { |
189 | DBG(1,"sys_rt_sigreturn: compat_frame->uc.uc_mcontext 0x%p\n", | 144 | DBG(1,"sys_rt_sigreturn: compat_frame->uc.uc_mcontext 0x%p\n", |
190 | &compat_frame->uc.uc_mcontext); | 145 | &compat_frame->uc.uc_mcontext); |
@@ -296,7 +251,7 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, | |||
296 | unsigned long rp, usp; | 251 | unsigned long rp, usp; |
297 | unsigned long haddr, sigframe_size; | 252 | unsigned long haddr, sigframe_size; |
298 | int err = 0; | 253 | int err = 0; |
299 | #ifdef __LP64__ | 254 | #ifdef CONFIG_64BIT |
300 | compat_int_t compat_val; | 255 | compat_int_t compat_val; |
301 | struct compat_rt_sigframe __user * compat_frame; | 256 | struct compat_rt_sigframe __user * compat_frame; |
302 | compat_sigset_t compat_set; | 257 | compat_sigset_t compat_set; |
@@ -310,7 +265,7 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, | |||
310 | DBG(1,"setup_rt_frame: frame %p info %p\n", frame, info); | 265 | DBG(1,"setup_rt_frame: frame %p info %p\n", frame, info); |
311 | 266 | ||
312 | 267 | ||
313 | #ifdef __LP64__ | 268 | #ifdef CONFIG_64BIT |
314 | 269 | ||
315 | compat_frame = (struct compat_rt_sigframe __user *)frame; | 270 | compat_frame = (struct compat_rt_sigframe __user *)frame; |
316 | 271 | ||
@@ -390,7 +345,7 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, | |||
390 | 345 | ||
391 | haddr = A(ka->sa.sa_handler); | 346 | haddr = A(ka->sa.sa_handler); |
392 | /* The sa_handler may be a pointer to a function descriptor */ | 347 | /* The sa_handler may be a pointer to a function descriptor */ |
393 | #ifdef __LP64__ | 348 | #ifdef CONFIG_64BIT |
394 | if (is_compat_task()) { | 349 | if (is_compat_task()) { |
395 | #endif | 350 | #endif |
396 | if (haddr & PA_PLABEL_FDESC) { | 351 | if (haddr & PA_PLABEL_FDESC) { |
@@ -405,7 +360,7 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, | |||
405 | haddr = fdesc.addr; | 360 | haddr = fdesc.addr; |
406 | regs->gr[19] = fdesc.gp; | 361 | regs->gr[19] = fdesc.gp; |
407 | } | 362 | } |
408 | #ifdef __LP64__ | 363 | #ifdef CONFIG_64BIT |
409 | } else { | 364 | } else { |
410 | Elf64_Fdesc fdesc; | 365 | Elf64_Fdesc fdesc; |
411 | Elf64_Fdesc __user *ufdesc = (Elf64_Fdesc __user *)A(haddr & ~3); | 366 | Elf64_Fdesc __user *ufdesc = (Elf64_Fdesc __user *)A(haddr & ~3); |
@@ -425,19 +380,19 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, | |||
425 | /* The syscall return path will create IAOQ values from r31. | 380 | /* The syscall return path will create IAOQ values from r31. |
426 | */ | 381 | */ |
427 | sigframe_size = PARISC_RT_SIGFRAME_SIZE; | 382 | sigframe_size = PARISC_RT_SIGFRAME_SIZE; |
428 | #ifdef __LP64__ | 383 | #ifdef CONFIG_64BIT |
429 | if (is_compat_task()) | 384 | if (is_compat_task()) |
430 | sigframe_size = PARISC_RT_SIGFRAME_SIZE32; | 385 | sigframe_size = PARISC_RT_SIGFRAME_SIZE32; |
431 | #endif | 386 | #endif |
432 | if (in_syscall) { | 387 | if (in_syscall) { |
433 | regs->gr[31] = haddr; | 388 | regs->gr[31] = haddr; |
434 | #ifdef __LP64__ | 389 | #ifdef CONFIG_64BIT |
435 | if (!test_thread_flag(TIF_32BIT)) | 390 | if (!test_thread_flag(TIF_32BIT)) |
436 | sigframe_size |= 1; | 391 | sigframe_size |= 1; |
437 | #endif | 392 | #endif |
438 | } else { | 393 | } else { |
439 | unsigned long psw = USER_PSW; | 394 | unsigned long psw = USER_PSW; |
440 | #ifdef __LP64__ | 395 | #ifdef CONFIG_64BIT |
441 | if (!test_thread_flag(TIF_32BIT)) | 396 | if (!test_thread_flag(TIF_32BIT)) |
442 | psw |= PSW_W; | 397 | psw |= PSW_W; |
443 | #endif | 398 | #endif |
@@ -462,7 +417,7 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, | |||
462 | regs->gr[2] = rp; /* userland return pointer */ | 417 | regs->gr[2] = rp; /* userland return pointer */ |
463 | regs->gr[26] = sig; /* signal number */ | 418 | regs->gr[26] = sig; /* signal number */ |
464 | 419 | ||
465 | #ifdef __LP64__ | 420 | #ifdef CONFIG_64BIT |
466 | if (is_compat_task()) { | 421 | if (is_compat_task()) { |
467 | regs->gr[25] = A(&compat_frame->info); /* siginfo pointer */ | 422 | regs->gr[25] = A(&compat_frame->info); /* siginfo pointer */ |
468 | regs->gr[24] = A(&compat_frame->uc); /* ucontext pointer */ | 423 | regs->gr[24] = A(&compat_frame->uc); /* ucontext pointer */ |
@@ -516,6 +471,97 @@ handle_signal(unsigned long sig, siginfo_t *info, struct k_sigaction *ka, | |||
516 | return 1; | 471 | return 1; |
517 | } | 472 | } |
518 | 473 | ||
474 | static inline void | ||
475 | syscall_restart(struct pt_regs *regs, struct k_sigaction *ka) | ||
476 | { | ||
477 | /* Check the return code */ | ||
478 | switch (regs->gr[28]) { | ||
479 | case -ERESTART_RESTARTBLOCK: | ||
480 | current_thread_info()->restart_block.fn = | ||
481 | do_no_restart_syscall; | ||
482 | case -ERESTARTNOHAND: | ||
483 | DBG(1,"ERESTARTNOHAND: returning -EINTR\n"); | ||
484 | regs->gr[28] = -EINTR; | ||
485 | break; | ||
486 | |||
487 | case -ERESTARTSYS: | ||
488 | if (!(ka->sa.sa_flags & SA_RESTART)) { | ||
489 | DBG(1,"ERESTARTSYS: putting -EINTR\n"); | ||
490 | regs->gr[28] = -EINTR; | ||
491 | break; | ||
492 | } | ||
493 | /* fallthrough */ | ||
494 | case -ERESTARTNOINTR: | ||
495 | /* A syscall is just a branch, so all | ||
496 | * we have to do is fiddle the return pointer. | ||
497 | */ | ||
498 | regs->gr[31] -= 8; /* delayed branching */ | ||
499 | /* Preserve original r28. */ | ||
500 | regs->gr[28] = regs->orig_r28; | ||
501 | break; | ||
502 | } | ||
503 | } | ||
504 | |||
505 | static inline void | ||
506 | insert_restart_trampoline(struct pt_regs *regs) | ||
507 | { | ||
508 | switch(regs->gr[28]) { | ||
509 | case -ERESTART_RESTARTBLOCK: { | ||
510 | /* Restart the system call - no handlers present */ | ||
511 | unsigned int *usp = (unsigned int *)regs->gr[30]; | ||
512 | |||
513 | /* Setup a trampoline to restart the syscall | ||
514 | * with __NR_restart_syscall | ||
515 | * | ||
516 | * 0: <return address (orig r31)> | ||
517 | * 4: <2nd half for 64-bit> | ||
518 | * 8: ldw 0(%sp), %r31 | ||
519 | * 12: be 0x100(%sr2, %r0) | ||
520 | * 16: ldi __NR_restart_syscall, %r20 | ||
521 | */ | ||
522 | #ifdef CONFIG_64BIT | ||
523 | put_user(regs->gr[31] >> 32, &usp[0]); | ||
524 | put_user(regs->gr[31] & 0xffffffff, &usp[1]); | ||
525 | put_user(0x0fc010df, &usp[2]); | ||
526 | #else | ||
527 | put_user(regs->gr[31], &usp[0]); | ||
528 | put_user(0x0fc0109f, &usp[2]); | ||
529 | #endif | ||
530 | put_user(0xe0008200, &usp[3]); | ||
531 | put_user(0x34140000, &usp[4]); | ||
532 | |||
533 | /* Stack is 64-byte aligned, and we only need | ||
534 | * to flush 1 cache line. | ||
535 | * Flushing one cacheline is cheap. | ||
536 | * "sync" on bigger (> 4 way) boxes is not. | ||
537 | */ | ||
538 | flush_icache_range(regs->gr[30], regs->gr[30] + 4); | ||
539 | |||
540 | regs->gr[31] = regs->gr[30] + 8; | ||
541 | /* Preserve original r28. */ | ||
542 | regs->gr[28] = regs->orig_r28; | ||
543 | |||
544 | return; | ||
545 | } | ||
546 | case -ERESTARTNOHAND: | ||
547 | case -ERESTARTSYS: | ||
548 | case -ERESTARTNOINTR: { | ||
549 | /* Hooray for delayed branching. We don't | ||
550 | * have to restore %r20 (the system call | ||
551 | * number) because it gets loaded in the delay | ||
552 | * slot of the branch external instruction. | ||
553 | */ | ||
554 | regs->gr[31] -= 8; | ||
555 | /* Preserve original r28. */ | ||
556 | regs->gr[28] = regs->orig_r28; | ||
557 | |||
558 | return; | ||
559 | } | ||
560 | default: | ||
561 | break; | ||
562 | } | ||
563 | } | ||
564 | |||
519 | /* | 565 | /* |
520 | * Note that 'init' is a special process: it doesn't get signals it doesn't | 566 | * Note that 'init' is a special process: it doesn't get signals it doesn't |
521 | * want to handle. Thus you cannot kill init even with a SIGKILL even by | 567 | * want to handle. Thus you cannot kill init even with a SIGKILL even by |
@@ -527,13 +573,13 @@ handle_signal(unsigned long sig, siginfo_t *info, struct k_sigaction *ka, | |||
527 | * registers). As noted below, the syscall number gets restored for | 573 | * registers). As noted below, the syscall number gets restored for |
528 | * us due to the magic of delayed branching. | 574 | * us due to the magic of delayed branching. |
529 | */ | 575 | */ |
530 | 576 | asmlinkage void | |
531 | asmlinkage int | 577 | do_signal(struct pt_regs *regs, long in_syscall) |
532 | do_signal(sigset_t *oldset, struct pt_regs *regs, int in_syscall) | ||
533 | { | 578 | { |
534 | siginfo_t info; | 579 | siginfo_t info; |
535 | struct k_sigaction ka; | 580 | struct k_sigaction ka; |
536 | int signr; | 581 | int signr; |
582 | sigset_t *oldset; | ||
537 | 583 | ||
538 | DBG(1,"\ndo_signal: oldset=0x%p, regs=0x%p, sr7 %#lx, in_syscall=%d\n", | 584 | DBG(1,"\ndo_signal: oldset=0x%p, regs=0x%p, sr7 %#lx, in_syscall=%d\n", |
539 | oldset, regs, regs->sr[7], in_syscall); | 585 | oldset, regs, regs->sr[7], in_syscall); |
@@ -543,7 +589,9 @@ do_signal(sigset_t *oldset, struct pt_regs *regs, int in_syscall) | |||
543 | we would be called in that case, but for some reason we | 589 | we would be called in that case, but for some reason we |
544 | are. */ | 590 | are. */ |
545 | 591 | ||
546 | if (!oldset) | 592 | if (test_thread_flag(TIF_RESTORE_SIGMASK)) |
593 | oldset = ¤t->saved_sigmask; | ||
594 | else | ||
547 | oldset = ¤t->blocked; | 595 | oldset = ¤t->blocked; |
548 | 596 | ||
549 | DBG(1,"do_signal: oldset %08lx / %08lx\n", | 597 | DBG(1,"do_signal: oldset %08lx / %08lx\n", |
@@ -560,98 +608,41 @@ do_signal(sigset_t *oldset, struct pt_regs *regs, int in_syscall) | |||
560 | break; | 608 | break; |
561 | 609 | ||
562 | /* Restart a system call if necessary. */ | 610 | /* Restart a system call if necessary. */ |
563 | if (in_syscall) { | 611 | if (in_syscall) |
564 | /* Check the return code */ | 612 | syscall_restart(regs, &ka); |
565 | switch (regs->gr[28]) { | 613 | |
566 | case -ERESTART_RESTARTBLOCK: | ||
567 | current_thread_info()->restart_block.fn = do_no_restart_syscall; | ||
568 | case -ERESTARTNOHAND: | ||
569 | DBG(1,"ERESTARTNOHAND: returning -EINTR\n"); | ||
570 | regs->gr[28] = -EINTR; | ||
571 | break; | ||
572 | |||
573 | case -ERESTARTSYS: | ||
574 | if (!(ka.sa.sa_flags & SA_RESTART)) { | ||
575 | DBG(1,"ERESTARTSYS: putting -EINTR\n"); | ||
576 | regs->gr[28] = -EINTR; | ||
577 | break; | ||
578 | } | ||
579 | /* fallthrough */ | ||
580 | case -ERESTARTNOINTR: | ||
581 | /* A syscall is just a branch, so all | ||
582 | we have to do is fiddle the return pointer. */ | ||
583 | regs->gr[31] -= 8; /* delayed branching */ | ||
584 | /* Preserve original r28. */ | ||
585 | regs->gr[28] = regs->orig_r28; | ||
586 | break; | ||
587 | } | ||
588 | } | ||
589 | /* Whee! Actually deliver the signal. If the | 614 | /* Whee! Actually deliver the signal. If the |
590 | delivery failed, we need to continue to iterate in | 615 | delivery failed, we need to continue to iterate in |
591 | this loop so we can deliver the SIGSEGV... */ | 616 | this loop so we can deliver the SIGSEGV... */ |
592 | if (handle_signal(signr, &info, &ka, oldset, regs, in_syscall)) { | 617 | if (handle_signal(signr, &info, &ka, oldset, |
618 | regs, in_syscall)) { | ||
593 | DBG(1,KERN_DEBUG "do_signal: Exit (success), regs->gr[28] = %ld\n", | 619 | DBG(1,KERN_DEBUG "do_signal: Exit (success), regs->gr[28] = %ld\n", |
594 | regs->gr[28]); | 620 | regs->gr[28]); |
595 | return 1; | 621 | if (test_thread_flag(TIF_RESTORE_SIGMASK)) |
622 | clear_thread_flag(TIF_RESTORE_SIGMASK); | ||
623 | return; | ||
596 | } | 624 | } |
597 | } | 625 | } |
598 | /* end of while(1) looping forever if we can't force a signal */ | 626 | /* end of while(1) looping forever if we can't force a signal */ |
599 | 627 | ||
600 | /* Did we come from a system call? */ | 628 | /* Did we come from a system call? */ |
601 | if (in_syscall) { | 629 | if (in_syscall) |
602 | /* Restart the system call - no handlers present */ | 630 | insert_restart_trampoline(regs); |
603 | if (regs->gr[28] == -ERESTART_RESTARTBLOCK) { | ||
604 | unsigned int *usp = (unsigned int *)regs->gr[30]; | ||
605 | |||
606 | /* Setup a trampoline to restart the syscall | ||
607 | * with __NR_restart_syscall | ||
608 | * | ||
609 | * 0: <return address (orig r31)> | ||
610 | * 4: <2nd half for 64-bit> | ||
611 | * 8: ldw 0(%sp), %r31 | ||
612 | * 12: be 0x100(%sr2, %r0) | ||
613 | * 16: ldi __NR_restart_syscall, %r20 | ||
614 | */ | ||
615 | #ifndef __LP64__ | ||
616 | put_user(regs->gr[31], &usp[0]); | ||
617 | put_user(0x0fc0109f, &usp[2]); | ||
618 | #else | ||
619 | put_user(regs->gr[31] >> 32, &usp[0]); | ||
620 | put_user(regs->gr[31] & 0xffffffff, &usp[1]); | ||
621 | put_user(0x0fc010df, &usp[2]); | ||
622 | #endif | ||
623 | put_user(0xe0008200, &usp[3]); | ||
624 | put_user(0x34140000, &usp[4]); | ||
625 | |||
626 | /* Stack is 64-byte aligned, and we only need | ||
627 | * to flush 1 cache line. | ||
628 | * Flushing one cacheline is cheap. | ||
629 | * "sync" on bigger (> 4 way) boxes is not. | ||
630 | */ | ||
631 | asm("fdc %%r0(%%sr3, %0)\n" | ||
632 | "sync\n" | ||
633 | "fic %%r0(%%sr3, %0)\n" | ||
634 | "sync\n" | ||
635 | : : "r"(regs->gr[30])); | ||
636 | |||
637 | regs->gr[31] = regs->gr[30] + 8; | ||
638 | /* Preserve original r28. */ | ||
639 | regs->gr[28] = regs->orig_r28; | ||
640 | } else if (regs->gr[28] == -ERESTARTNOHAND || | ||
641 | regs->gr[28] == -ERESTARTSYS || | ||
642 | regs->gr[28] == -ERESTARTNOINTR) { | ||
643 | /* Hooray for delayed branching. We don't | ||
644 | have to restore %r20 (the system call | ||
645 | number) because it gets loaded in the delay | ||
646 | slot of the branch external instruction. */ | ||
647 | regs->gr[31] -= 8; | ||
648 | /* Preserve original r28. */ | ||
649 | regs->gr[28] = regs->orig_r28; | ||
650 | } | ||
651 | } | ||
652 | 631 | ||
653 | DBG(1,"do_signal: Exit (not delivered), regs->gr[28] = %ld\n", | 632 | DBG(1,"do_signal: Exit (not delivered), regs->gr[28] = %ld\n", |
654 | regs->gr[28]); | 633 | regs->gr[28]); |
655 | 634 | ||
656 | return 0; | 635 | if (test_thread_flag(TIF_RESTORE_SIGMASK)) { |
636 | clear_thread_flag(TIF_RESTORE_SIGMASK); | ||
637 | sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); | ||
638 | } | ||
639 | |||
640 | return; | ||
641 | } | ||
642 | |||
643 | void do_notify_resume(struct pt_regs *regs, long in_syscall) | ||
644 | { | ||
645 | if (test_thread_flag(TIF_SIGPENDING) || | ||
646 | test_thread_flag(TIF_RESTORE_SIGMASK)) | ||
647 | do_signal(regs, in_syscall); | ||
657 | } | 648 | } |
diff --git a/arch/parisc/kernel/signal32.c b/arch/parisc/kernel/signal32.c index a6b4231cafa1..1c1a37f73053 100644 --- a/arch/parisc/kernel/signal32.c +++ b/arch/parisc/kernel/signal32.c | |||
@@ -1,6 +1,8 @@ | |||
1 | /* Signal support for 32-bit kernel builds | 1 | /* Signal support for 32-bit kernel builds |
2 | * | 2 | * |
3 | * Copyright (C) 2001 Matthew Wilcox <willy at parisc-linux.org> | 3 | * Copyright (C) 2001 Matthew Wilcox <willy at parisc-linux.org> |
4 | * Copyright (C) 2006 Kyle McMartin <kyle at parisc-linux.org> | ||
5 | * | ||
4 | * Code was mostly borrowed from kernel/signal.c. | 6 | * Code was mostly borrowed from kernel/signal.c. |
5 | * See kernel/signal.c for additional Copyrights. | 7 | * See kernel/signal.c for additional Copyrights. |
6 | * | 8 | * |
@@ -401,7 +403,7 @@ setup_sigcontext32(struct compat_sigcontext __user *sc, struct compat_regfile __ | |||
401 | int | 403 | int |
402 | copy_siginfo_from_user32 (siginfo_t *to, compat_siginfo_t __user *from) | 404 | copy_siginfo_from_user32 (siginfo_t *to, compat_siginfo_t __user *from) |
403 | { | 405 | { |
404 | unsigned long tmp; | 406 | compat_uptr_t addr; |
405 | int err; | 407 | int err; |
406 | 408 | ||
407 | if (!access_ok(VERIFY_READ, from, sizeof(compat_siginfo_t))) | 409 | if (!access_ok(VERIFY_READ, from, sizeof(compat_siginfo_t))) |
@@ -424,8 +426,8 @@ copy_siginfo_from_user32 (siginfo_t *to, compat_siginfo_t __user *from) | |||
424 | err |= __get_user(to->si_uid, &from->si_uid); | 426 | err |= __get_user(to->si_uid, &from->si_uid); |
425 | break; | 427 | break; |
426 | case __SI_FAULT >> 16: | 428 | case __SI_FAULT >> 16: |
427 | err |= __get_user(tmp, &from->si_addr); | 429 | err |= __get_user(addr, &from->si_addr); |
428 | to->si_addr = (void __user *) tmp; | 430 | to->si_addr = compat_ptr(addr); |
429 | break; | 431 | break; |
430 | case __SI_POLL >> 16: | 432 | case __SI_POLL >> 16: |
431 | err |= __get_user(to->si_band, &from->si_band); | 433 | err |= __get_user(to->si_band, &from->si_band); |
@@ -445,7 +447,8 @@ copy_siginfo_from_user32 (siginfo_t *to, compat_siginfo_t __user *from) | |||
445 | int | 447 | int |
446 | copy_siginfo_to_user32 (compat_siginfo_t __user *to, siginfo_t *from) | 448 | copy_siginfo_to_user32 (compat_siginfo_t __user *to, siginfo_t *from) |
447 | { | 449 | { |
448 | unsigned int addr; | 450 | compat_uptr_t addr; |
451 | compat_int_t val; | ||
449 | int err; | 452 | int err; |
450 | 453 | ||
451 | if (!access_ok(VERIFY_WRITE, to, sizeof(compat_siginfo_t))) | 454 | if (!access_ok(VERIFY_WRITE, to, sizeof(compat_siginfo_t))) |
@@ -474,8 +477,8 @@ copy_siginfo_to_user32 (compat_siginfo_t __user *to, siginfo_t *from) | |||
474 | err |= __put_user(from->si_uid, &to->si_uid); | 477 | err |= __put_user(from->si_uid, &to->si_uid); |
475 | break; | 478 | break; |
476 | case __SI_FAULT >> 16: | 479 | case __SI_FAULT >> 16: |
477 | /* avoid type-checking warnings by copying _pad[0] in lieu of si_addr... */ | 480 | addr = ptr_to_compat(from->si_addr); |
478 | err |= __put_user(from->_sifields._pad[0], &to->si_addr); | 481 | err |= __put_user(addr, &to->si_addr); |
479 | break; | 482 | break; |
480 | case __SI_POLL >> 16: | 483 | case __SI_POLL >> 16: |
481 | err |= __put_user(from->si_band, &to->si_band); | 484 | err |= __put_user(from->si_band, &to->si_band); |
@@ -484,17 +487,36 @@ copy_siginfo_to_user32 (compat_siginfo_t __user *to, siginfo_t *from) | |||
484 | case __SI_TIMER >> 16: | 487 | case __SI_TIMER >> 16: |
485 | err |= __put_user(from->si_tid, &to->si_tid); | 488 | err |= __put_user(from->si_tid, &to->si_tid); |
486 | err |= __put_user(from->si_overrun, &to->si_overrun); | 489 | err |= __put_user(from->si_overrun, &to->si_overrun); |
487 | addr = (unsigned long) from->si_ptr; | 490 | val = (compat_int_t)from->si_int; |
488 | err |= __put_user(addr, &to->si_ptr); | 491 | err |= __put_user(val, &to->si_int); |
489 | break; | 492 | break; |
490 | case __SI_RT >> 16: /* Not generated by the kernel as of now. */ | 493 | case __SI_RT >> 16: /* Not generated by the kernel as of now. */ |
491 | case __SI_MESGQ >> 16: | 494 | case __SI_MESGQ >> 16: |
492 | err |= __put_user(from->si_uid, &to->si_uid); | 495 | err |= __put_user(from->si_uid, &to->si_uid); |
493 | err |= __put_user(from->si_pid, &to->si_pid); | 496 | err |= __put_user(from->si_pid, &to->si_pid); |
494 | addr = (unsigned long) from->si_ptr; | 497 | val = (compat_int_t)from->si_int; |
495 | err |= __put_user(addr, &to->si_ptr); | 498 | err |= __put_user(val, &to->si_int); |
496 | break; | 499 | break; |
497 | } | 500 | } |
498 | } | 501 | } |
499 | return err; | 502 | return err; |
500 | } | 503 | } |
504 | |||
505 | asmlinkage long compat_sys_rt_sigqueueinfo(int pid, int sig, | ||
506 | struct compat_siginfo __user *uinfo) | ||
507 | { | ||
508 | siginfo_t info; | ||
509 | |||
510 | if (copy_siginfo_from_user32(&info, uinfo)) | ||
511 | return -EFAULT; | ||
512 | |||
513 | /* Not even root can pretend to send signals from the kernel. | ||
514 | Nor can they impersonate a kill(), which adds source info. */ | ||
515 | if (info.si_code >= 0) | ||
516 | return -EPERM; | ||
517 | info.si_signo = sig; | ||
518 | |||
519 | /* POSIX.1b doesn't mention process groups. */ | ||
520 | return kill_proc_info(sig, &info, pid); | ||
521 | } | ||
522 | |||
diff --git a/arch/parisc/kernel/smp.c b/arch/parisc/kernel/smp.c index 12cc019307ad..6ba9257fdb7f 100644 --- a/arch/parisc/kernel/smp.c +++ b/arch/parisc/kernel/smp.c | |||
@@ -16,9 +16,6 @@ | |||
16 | ** the Free Software Foundation; either version 2 of the License, or | 16 | ** the Free Software Foundation; either version 2 of the License, or |
17 | ** (at your option) any later version. | 17 | ** (at your option) any later version. |
18 | */ | 18 | */ |
19 | #undef ENTRY_SYS_CPUS /* syscall support for iCOD-like functionality */ | ||
20 | |||
21 | |||
22 | #include <linux/types.h> | 19 | #include <linux/types.h> |
23 | #include <linux/spinlock.h> | 20 | #include <linux/spinlock.h> |
24 | #include <linux/slab.h> | 21 | #include <linux/slab.h> |
@@ -51,7 +48,15 @@ | |||
51 | #include <asm/unistd.h> | 48 | #include <asm/unistd.h> |
52 | #include <asm/cacheflush.h> | 49 | #include <asm/cacheflush.h> |
53 | 50 | ||
54 | #define kDEBUG 0 | 51 | #undef DEBUG_SMP |
52 | #ifdef DEBUG_SMP | ||
53 | static int smp_debug_lvl = 0; | ||
54 | #define smp_debug(lvl, printargs...) \ | ||
55 | if (lvl >= smp_debug_lvl) \ | ||
56 | printk(printargs); | ||
57 | #else | ||
58 | #define smp_debug(lvl, ...) | ||
59 | #endif /* DEBUG_SMP */ | ||
55 | 60 | ||
56 | DEFINE_SPINLOCK(smp_lock); | 61 | DEFINE_SPINLOCK(smp_lock); |
57 | 62 | ||
@@ -76,6 +81,7 @@ cpumask_t cpu_possible_map __read_mostly = CPU_MASK_ALL; /* Bitmap of Present CP | |||
76 | EXPORT_SYMBOL(cpu_online_map); | 81 | EXPORT_SYMBOL(cpu_online_map); |
77 | EXPORT_SYMBOL(cpu_possible_map); | 82 | EXPORT_SYMBOL(cpu_possible_map); |
78 | 83 | ||
84 | DEFINE_PER_CPU(spinlock_t, ipi_lock) = SPIN_LOCK_UNLOCKED; | ||
79 | 85 | ||
80 | struct smp_call_struct { | 86 | struct smp_call_struct { |
81 | void (*func) (void *info); | 87 | void (*func) (void *info); |
@@ -107,13 +113,6 @@ enum ipi_message_type { | |||
107 | static void | 113 | static void |
108 | ipi_init(int cpuid) | 114 | ipi_init(int cpuid) |
109 | { | 115 | { |
110 | |||
111 | /* If CPU is present ... */ | ||
112 | #ifdef ENTRY_SYS_CPUS | ||
113 | /* *and* running (not stopped) ... */ | ||
114 | #error iCOD support wants state checked here. | ||
115 | #endif | ||
116 | |||
117 | #error verify IRQ_OFFSET(IPI_IRQ) is ipi_interrupt() in new IRQ region | 116 | #error verify IRQ_OFFSET(IPI_IRQ) is ipi_interrupt() in new IRQ region |
118 | 117 | ||
119 | if(cpu_online(cpuid) ) | 118 | if(cpu_online(cpuid) ) |
@@ -133,23 +132,12 @@ ipi_init(int cpuid) | |||
133 | static void | 132 | static void |
134 | halt_processor(void) | 133 | halt_processor(void) |
135 | { | 134 | { |
136 | #ifdef ENTRY_SYS_CPUS | ||
137 | #error halt_processor() needs rework | ||
138 | /* | ||
139 | ** o migrate I/O interrupts off this CPU. | ||
140 | ** o leave IPI enabled - __cli() will disable IPI. | ||
141 | ** o leave CPU in online map - just change the state | ||
142 | */ | ||
143 | cpu_data[this_cpu].state = STATE_STOPPED; | ||
144 | mark_bh(IPI_BH); | ||
145 | #else | ||
146 | /* REVISIT : redirect I/O Interrupts to another CPU? */ | 135 | /* REVISIT : redirect I/O Interrupts to another CPU? */ |
147 | /* REVISIT : does PM *know* this CPU isn't available? */ | 136 | /* REVISIT : does PM *know* this CPU isn't available? */ |
148 | cpu_clear(smp_processor_id(), cpu_online_map); | 137 | cpu_clear(smp_processor_id(), cpu_online_map); |
149 | local_irq_disable(); | 138 | local_irq_disable(); |
150 | for (;;) | 139 | for (;;) |
151 | ; | 140 | ; |
152 | #endif | ||
153 | } | 141 | } |
154 | 142 | ||
155 | 143 | ||
@@ -167,10 +155,11 @@ ipi_interrupt(int irq, void *dev_id) | |||
167 | mb(); /* Order interrupt and bit testing. */ | 155 | mb(); /* Order interrupt and bit testing. */ |
168 | 156 | ||
169 | for (;;) { | 157 | for (;;) { |
170 | spin_lock_irqsave(&(p->lock),flags); | 158 | spinlock_t *lock = &per_cpu(ipi_lock, this_cpu); |
159 | spin_lock_irqsave(lock, flags); | ||
171 | ops = p->pending_ipi; | 160 | ops = p->pending_ipi; |
172 | p->pending_ipi = 0; | 161 | p->pending_ipi = 0; |
173 | spin_unlock_irqrestore(&(p->lock),flags); | 162 | spin_unlock_irqrestore(lock, flags); |
174 | 163 | ||
175 | mb(); /* Order bit clearing and data access. */ | 164 | mb(); /* Order bit clearing and data access. */ |
176 | 165 | ||
@@ -184,15 +173,11 @@ ipi_interrupt(int irq, void *dev_id) | |||
184 | 173 | ||
185 | switch (which) { | 174 | switch (which) { |
186 | case IPI_NOP: | 175 | case IPI_NOP: |
187 | #if (kDEBUG>=100) | 176 | smp_debug(100, KERN_DEBUG "CPU%d IPI_NOP\n", this_cpu); |
188 | printk(KERN_DEBUG "CPU%d IPI_NOP\n",this_cpu); | ||
189 | #endif /* kDEBUG */ | ||
190 | break; | 177 | break; |
191 | 178 | ||
192 | case IPI_RESCHEDULE: | 179 | case IPI_RESCHEDULE: |
193 | #if (kDEBUG>=100) | 180 | smp_debug(100, KERN_DEBUG "CPU%d IPI_RESCHEDULE\n", this_cpu); |
194 | printk(KERN_DEBUG "CPU%d IPI_RESCHEDULE\n",this_cpu); | ||
195 | #endif /* kDEBUG */ | ||
196 | /* | 181 | /* |
197 | * Reschedule callback. Everything to be | 182 | * Reschedule callback. Everything to be |
198 | * done is done by the interrupt return path. | 183 | * done is done by the interrupt return path. |
@@ -200,9 +185,7 @@ ipi_interrupt(int irq, void *dev_id) | |||
200 | break; | 185 | break; |
201 | 186 | ||
202 | case IPI_CALL_FUNC: | 187 | case IPI_CALL_FUNC: |
203 | #if (kDEBUG>=100) | 188 | smp_debug(100, KERN_DEBUG "CPU%d IPI_CALL_FUNC\n", this_cpu); |
204 | printk(KERN_DEBUG "CPU%d IPI_CALL_FUNC\n",this_cpu); | ||
205 | #endif /* kDEBUG */ | ||
206 | { | 189 | { |
207 | volatile struct smp_call_struct *data; | 190 | volatile struct smp_call_struct *data; |
208 | void (*func)(void *info); | 191 | void (*func)(void *info); |
@@ -233,28 +216,16 @@ ipi_interrupt(int irq, void *dev_id) | |||
233 | break; | 216 | break; |
234 | 217 | ||
235 | case IPI_CPU_START: | 218 | case IPI_CPU_START: |
236 | #if (kDEBUG>=100) | 219 | smp_debug(100, KERN_DEBUG "CPU%d IPI_CPU_START\n", this_cpu); |
237 | printk(KERN_DEBUG "CPU%d IPI_CPU_START\n",this_cpu); | ||
238 | #endif /* kDEBUG */ | ||
239 | #ifdef ENTRY_SYS_CPUS | ||
240 | p->state = STATE_RUNNING; | ||
241 | #endif | ||
242 | break; | 220 | break; |
243 | 221 | ||
244 | case IPI_CPU_STOP: | 222 | case IPI_CPU_STOP: |
245 | #if (kDEBUG>=100) | 223 | smp_debug(100, KERN_DEBUG "CPU%d IPI_CPU_STOP\n", this_cpu); |
246 | printk(KERN_DEBUG "CPU%d IPI_CPU_STOP\n",this_cpu); | ||
247 | #endif /* kDEBUG */ | ||
248 | #ifdef ENTRY_SYS_CPUS | ||
249 | #else | ||
250 | halt_processor(); | 224 | halt_processor(); |
251 | #endif | ||
252 | break; | 225 | break; |
253 | 226 | ||
254 | case IPI_CPU_TEST: | 227 | case IPI_CPU_TEST: |
255 | #if (kDEBUG>=100) | 228 | smp_debug(100, KERN_DEBUG "CPU%d is alive!\n", this_cpu); |
256 | printk(KERN_DEBUG "CPU%d is alive!\n",this_cpu); | ||
257 | #endif /* kDEBUG */ | ||
258 | break; | 229 | break; |
259 | 230 | ||
260 | default: | 231 | default: |
@@ -275,12 +246,13 @@ static inline void | |||
275 | ipi_send(int cpu, enum ipi_message_type op) | 246 | ipi_send(int cpu, enum ipi_message_type op) |
276 | { | 247 | { |
277 | struct cpuinfo_parisc *p = &cpu_data[cpu]; | 248 | struct cpuinfo_parisc *p = &cpu_data[cpu]; |
249 | spinlock_t *lock = &per_cpu(ipi_lock, cpu); | ||
278 | unsigned long flags; | 250 | unsigned long flags; |
279 | 251 | ||
280 | spin_lock_irqsave(&(p->lock),flags); | 252 | spin_lock_irqsave(lock, flags); |
281 | p->pending_ipi |= 1 << op; | 253 | p->pending_ipi |= 1 << op; |
282 | gsc_writel(IPI_IRQ - CPU_IRQ_BASE, cpu_data[cpu].hpa); | 254 | gsc_writel(IPI_IRQ - CPU_IRQ_BASE, cpu_data[cpu].hpa); |
283 | spin_unlock_irqrestore(&(p->lock),flags); | 255 | spin_unlock_irqrestore(lock, flags); |
284 | } | 256 | } |
285 | 257 | ||
286 | 258 | ||
@@ -560,13 +532,8 @@ int __init smp_boot_one_cpu(int cpuid) | |||
560 | 532 | ||
561 | alive: | 533 | alive: |
562 | /* Remember the Slave data */ | 534 | /* Remember the Slave data */ |
563 | #if (kDEBUG>=100) | 535 | smp_debug(100, KERN_DEBUG "SMP: CPU:%d came alive after %ld _us\n", |
564 | printk(KERN_DEBUG "SMP: CPU:%d came alive after %ld _us\n", | ||
565 | cpuid, timeout * 100); | 536 | cpuid, timeout * 100); |
566 | #endif /* kDEBUG */ | ||
567 | #ifdef ENTRY_SYS_CPUS | ||
568 | cpu_data[cpuid].state = STATE_RUNNING; | ||
569 | #endif | ||
570 | return 0; | 537 | return 0; |
571 | } | 538 | } |
572 | 539 | ||
@@ -574,10 +541,6 @@ void __devinit smp_prepare_boot_cpu(void) | |||
574 | { | 541 | { |
575 | int bootstrap_processor=cpu_data[0].cpuid; /* CPU ID of BSP */ | 542 | int bootstrap_processor=cpu_data[0].cpuid; /* CPU ID of BSP */ |
576 | 543 | ||
577 | #ifdef ENTRY_SYS_CPUS | ||
578 | cpu_data[0].state = STATE_RUNNING; | ||
579 | #endif | ||
580 | |||
581 | /* Setup BSP mappings */ | 544 | /* Setup BSP mappings */ |
582 | printk("SMP: bootstrap CPU ID is %d\n",bootstrap_processor); | 545 | printk("SMP: bootstrap CPU ID is %d\n",bootstrap_processor); |
583 | 546 | ||
@@ -616,101 +579,6 @@ int __cpuinit __cpu_up(unsigned int cpu) | |||
616 | return cpu_online(cpu) ? 0 : -ENOSYS; | 579 | return cpu_online(cpu) ? 0 : -ENOSYS; |
617 | } | 580 | } |
618 | 581 | ||
619 | |||
620 | |||
621 | #ifdef ENTRY_SYS_CPUS | ||
622 | /* Code goes along with: | ||
623 | ** entry.s: ENTRY_NAME(sys_cpus) / * 215, for cpu stat * / | ||
624 | */ | ||
625 | int sys_cpus(int argc, char **argv) | ||
626 | { | ||
627 | int i,j=0; | ||
628 | extern int current_pid(int cpu); | ||
629 | |||
630 | if( argc > 2 ) { | ||
631 | printk("sys_cpus:Only one argument supported\n"); | ||
632 | return (-1); | ||
633 | } | ||
634 | if ( argc == 1 ){ | ||
635 | |||
636 | #ifdef DUMP_MORE_STATE | ||
637 | for_each_online_cpu(i) { | ||
638 | int cpus_per_line = 4; | ||
639 | |||
640 | if (j++ % cpus_per_line) | ||
641 | printk(" %3d",i); | ||
642 | else | ||
643 | printk("\n %3d",i); | ||
644 | } | ||
645 | printk("\n"); | ||
646 | #else | ||
647 | printk("\n 0\n"); | ||
648 | #endif | ||
649 | } else if((argc==2) && !(strcmp(argv[1],"-l"))) { | ||
650 | printk("\nCPUSTATE TASK CPUNUM CPUID HARDCPU(HPA)\n"); | ||
651 | #ifdef DUMP_MORE_STATE | ||
652 | for_each_online_cpu(i) { | ||
653 | if (cpu_data[i].cpuid != NO_PROC_ID) { | ||
654 | switch(cpu_data[i].state) { | ||
655 | case STATE_RENDEZVOUS: | ||
656 | printk("RENDEZVS "); | ||
657 | break; | ||
658 | case STATE_RUNNING: | ||
659 | printk((current_pid(i)!=0) ? "RUNNING " : "IDLING "); | ||
660 | break; | ||
661 | case STATE_STOPPED: | ||
662 | printk("STOPPED "); | ||
663 | break; | ||
664 | case STATE_HALTED: | ||
665 | printk("HALTED "); | ||
666 | break; | ||
667 | default: | ||
668 | printk("%08x?", cpu_data[i].state); | ||
669 | break; | ||
670 | } | ||
671 | if(cpu_online(i)) { | ||
672 | printk(" %4d",current_pid(i)); | ||
673 | } | ||
674 | printk(" %6d",cpu_number_map(i)); | ||
675 | printk(" %5d",i); | ||
676 | printk(" 0x%lx\n",cpu_data[i].hpa); | ||
677 | } | ||
678 | } | ||
679 | #else | ||
680 | printk("\n%s %4d 0 0 --------", | ||
681 | (current->pid)?"RUNNING ": "IDLING ",current->pid); | ||
682 | #endif | ||
683 | } else if ((argc==2) && !(strcmp(argv[1],"-s"))) { | ||
684 | #ifdef DUMP_MORE_STATE | ||
685 | printk("\nCPUSTATE CPUID\n"); | ||
686 | for_each_online_cpu(i) { | ||
687 | if (cpu_data[i].cpuid != NO_PROC_ID) { | ||
688 | switch(cpu_data[i].state) { | ||
689 | case STATE_RENDEZVOUS: | ||
690 | printk("RENDEZVS");break; | ||
691 | case STATE_RUNNING: | ||
692 | printk((current_pid(i)!=0) ? "RUNNING " : "IDLING"); | ||
693 | break; | ||
694 | case STATE_STOPPED: | ||
695 | printk("STOPPED ");break; | ||
696 | case STATE_HALTED: | ||
697 | printk("HALTED ");break; | ||
698 | default: | ||
699 | } | ||
700 | printk(" %5d\n",i); | ||
701 | } | ||
702 | } | ||
703 | #else | ||
704 | printk("\n%s CPU0",(current->pid==0)?"RUNNING ":"IDLING "); | ||
705 | #endif | ||
706 | } else { | ||
707 | printk("sys_cpus:Unknown request\n"); | ||
708 | return (-1); | ||
709 | } | ||
710 | return 0; | ||
711 | } | ||
712 | #endif /* ENTRY_SYS_CPUS */ | ||
713 | |||
714 | #ifdef CONFIG_PROC_FS | 582 | #ifdef CONFIG_PROC_FS |
715 | int __init | 583 | int __init |
716 | setup_profiling_timer(unsigned int multiplier) | 584 | setup_profiling_timer(unsigned int multiplier) |
diff --git a/arch/parisc/kernel/syscall.S b/arch/parisc/kernel/syscall.S index a05800429304..10859f53e94f 100644 --- a/arch/parisc/kernel/syscall.S +++ b/arch/parisc/kernel/syscall.S | |||
@@ -12,27 +12,23 @@ | |||
12 | #include <asm/errno.h> | 12 | #include <asm/errno.h> |
13 | #include <asm/psw.h> | 13 | #include <asm/psw.h> |
14 | #include <asm/thread_info.h> | 14 | #include <asm/thread_info.h> |
15 | |||
16 | #include <asm/assembly.h> | 15 | #include <asm/assembly.h> |
17 | #include <asm/processor.h> | 16 | #include <asm/processor.h> |
18 | 17 | ||
18 | #include <linux/linkage.h> | ||
19 | |||
19 | /* We fill the empty parts of the gateway page with | 20 | /* We fill the empty parts of the gateway page with |
20 | * something that will kill the kernel or a | 21 | * something that will kill the kernel or a |
21 | * userspace application. | 22 | * userspace application. |
22 | */ | 23 | */ |
23 | #define KILL_INSN break 0,0 | 24 | #define KILL_INSN break 0,0 |
24 | 25 | ||
25 | #ifdef CONFIG_64BIT | 26 | .level LEVEL |
26 | .level 2.0w | ||
27 | #else | ||
28 | .level 1.1 | ||
29 | #endif | ||
30 | 27 | ||
31 | .text | 28 | .text |
32 | 29 | ||
33 | .import syscall_exit,code | 30 | .import syscall_exit,code |
34 | .import syscall_exit_rfi,code | 31 | .import syscall_exit_rfi,code |
35 | .export linux_gateway_page | ||
36 | 32 | ||
37 | /* Linux gateway page is aliased to virtual page 0 in the kernel | 33 | /* Linux gateway page is aliased to virtual page 0 in the kernel |
38 | * address space. Since it is a gateway page it cannot be | 34 | * address space. Since it is a gateway page it cannot be |
@@ -43,7 +39,7 @@ | |||
43 | */ | 39 | */ |
44 | 40 | ||
45 | .align ASM_PAGE_SIZE | 41 | .align ASM_PAGE_SIZE |
46 | linux_gateway_page: | 42 | ENTRY(linux_gateway_page) |
47 | 43 | ||
48 | /* ADDRESS 0x00 to 0xb0 = 176 bytes / 4 bytes per insn = 44 insns */ | 44 | /* ADDRESS 0x00 to 0xb0 = 176 bytes / 4 bytes per insn = 44 insns */ |
49 | .rept 44 | 45 | .rept 44 |
@@ -595,73 +591,43 @@ cas_action: | |||
595 | the other for the store. Either return -EFAULT. | 591 | the other for the store. Either return -EFAULT. |
596 | Each of the entries must be relocated. */ | 592 | Each of the entries must be relocated. */ |
597 | .section __ex_table,"aw" | 593 | .section __ex_table,"aw" |
598 | #ifdef CONFIG_64BIT | 594 | ASM_ULONG_INSN (1b - linux_gateway_page), (3b - linux_gateway_page) |
599 | /* Pad the address calculation */ | 595 | ASM_ULONG_INSN (2b - linux_gateway_page), (3b - linux_gateway_page) |
600 | .word 0,(2b - linux_gateway_page) | ||
601 | .word 0,(3b - linux_gateway_page) | ||
602 | #else | ||
603 | .word (2b - linux_gateway_page) | ||
604 | .word (3b - linux_gateway_page) | ||
605 | #endif | ||
606 | .previous | 596 | .previous |
607 | 597 | ||
608 | .section __ex_table,"aw" | ||
609 | #ifdef CONFIG_64BIT | ||
610 | /* Pad the address calculation */ | ||
611 | .word 0,(1b - linux_gateway_page) | ||
612 | .word 0,(3b - linux_gateway_page) | ||
613 | #else | ||
614 | .word (1b - linux_gateway_page) | ||
615 | .word (3b - linux_gateway_page) | ||
616 | #endif | ||
617 | .previous | ||
618 | |||
619 | end_compare_and_swap: | ||
620 | 598 | ||
621 | /* Make sure nothing else is placed on this page */ | 599 | /* Make sure nothing else is placed on this page */ |
622 | .align ASM_PAGE_SIZE | 600 | .align ASM_PAGE_SIZE |
623 | .export end_linux_gateway_page | 601 | END(linux_gateway_page) |
624 | end_linux_gateway_page: | 602 | ENTRY(end_linux_gateway_page) |
625 | 603 | ||
626 | /* Relocate symbols assuming linux_gateway_page is mapped | 604 | /* Relocate symbols assuming linux_gateway_page is mapped |
627 | to virtual address 0x0 */ | 605 | to virtual address 0x0 */ |
628 | #ifdef CONFIG_64BIT | 606 | |
629 | /* FIXME: The code will always be on the gateay page | 607 | #define LWS_ENTRY(_name_) ASM_ULONG_INSN (lws_##_name_ - linux_gateway_page) |
630 | and thus it will be on the first 4k, the | ||
631 | assembler seems to think that the final | ||
632 | subtraction result is only a word in | ||
633 | length, so we pad the value. | ||
634 | */ | ||
635 | #define LWS_ENTRY(_name_) .word 0,(lws_##_name_ - linux_gateway_page) | ||
636 | #else | ||
637 | #define LWS_ENTRY(_name_) .word (lws_##_name_ - linux_gateway_page) | ||
638 | #endif | ||
639 | 608 | ||
640 | .section .rodata,"a" | 609 | .section .rodata,"a" |
641 | 610 | ||
642 | .align ASM_PAGE_SIZE | 611 | .align ASM_PAGE_SIZE |
643 | /* Light-weight-syscall table */ | 612 | /* Light-weight-syscall table */ |
644 | /* Start of lws table. */ | 613 | /* Start of lws table. */ |
645 | .export lws_table | 614 | ENTRY(lws_table) |
646 | .Llws_table: | ||
647 | lws_table: | ||
648 | LWS_ENTRY(compare_and_swap32) /* 0 - ELF32 Atomic compare and swap */ | 615 | LWS_ENTRY(compare_and_swap32) /* 0 - ELF32 Atomic compare and swap */ |
649 | LWS_ENTRY(compare_and_swap64) /* 1 - ELF64 Atomic compare and swap */ | 616 | LWS_ENTRY(compare_and_swap64) /* 1 - ELF64 Atomic compare and swap */ |
617 | END(lws_table) | ||
650 | /* End of lws table */ | 618 | /* End of lws table */ |
651 | 619 | ||
652 | .align ASM_PAGE_SIZE | 620 | .align ASM_PAGE_SIZE |
653 | .export sys_call_table | 621 | ENTRY(sys_call_table) |
654 | .Lsys_call_table: | ||
655 | sys_call_table: | ||
656 | #include "syscall_table.S" | 622 | #include "syscall_table.S" |
623 | END(sys_call_table) | ||
657 | 624 | ||
658 | #ifdef CONFIG_64BIT | 625 | #ifdef CONFIG_64BIT |
659 | .align ASM_PAGE_SIZE | 626 | .align ASM_PAGE_SIZE |
660 | .export sys_call_table64 | 627 | ENTRY(sys_call_table64) |
661 | .Lsys_call_table64: | ||
662 | sys_call_table64: | ||
663 | #define SYSCALL_TABLE_64BIT | 628 | #define SYSCALL_TABLE_64BIT |
664 | #include "syscall_table.S" | 629 | #include "syscall_table.S" |
630 | END(sys_call_table64) | ||
665 | #endif | 631 | #endif |
666 | 632 | ||
667 | #ifdef CONFIG_SMP | 633 | #ifdef CONFIG_SMP |
@@ -671,9 +637,7 @@ sys_call_table64: | |||
671 | */ | 637 | */ |
672 | .section .data | 638 | .section .data |
673 | .align 4096 | 639 | .align 4096 |
674 | .export lws_lock_start | 640 | ENTRY(lws_lock_start) |
675 | .Llws_lock_start: | ||
676 | lws_lock_start: | ||
677 | /* lws locks */ | 641 | /* lws locks */ |
678 | .align 16 | 642 | .align 16 |
679 | .rept 16 | 643 | .rept 16 |
@@ -683,6 +647,7 @@ lws_lock_start: | |||
683 | .word 0 | 647 | .word 0 |
684 | .word 0 | 648 | .word 0 |
685 | .endr | 649 | .endr |
650 | END(lws_lock_start) | ||
686 | .previous | 651 | .previous |
687 | #endif | 652 | #endif |
688 | /* CONFIG_SMP for lws_lock_start */ | 653 | /* CONFIG_SMP for lws_lock_start */ |
diff --git a/arch/parisc/kernel/syscall_table.S b/arch/parisc/kernel/syscall_table.S index be8eb9a0d24a..8bf87e5d9c37 100644 --- a/arch/parisc/kernel/syscall_table.S +++ b/arch/parisc/kernel/syscall_table.S | |||
@@ -10,7 +10,7 @@ | |||
10 | * Copyright (C) 2000 Grant Grundler <grundler at parisc-linux.org> | 10 | * Copyright (C) 2000 Grant Grundler <grundler at parisc-linux.org> |
11 | * Copyright (C) 2001 Richard Hirst <rhirst with parisc-linux.org> | 11 | * Copyright (C) 2001 Richard Hirst <rhirst with parisc-linux.org> |
12 | * Copyright (C) 2001-2002 Ryan Bradetich <rbrad at parisc-linux.org> | 12 | * Copyright (C) 2001-2002 Ryan Bradetich <rbrad at parisc-linux.org> |
13 | * Copyright (C) 2001 Helge Deller <deller at parisc-linux.org> | 13 | * Copyright (C) 2001-2007 Helge Deller <deller at parisc-linux.org> |
14 | * Copyright (C) 2000-2001 Thomas Bogendoerfer <tsbogend at parisc-linux.org> | 14 | * Copyright (C) 2000-2001 Thomas Bogendoerfer <tsbogend at parisc-linux.org> |
15 | * Copyright (C) 2002 Randolph Chung <tausq with parisc-linux.org> | 15 | * Copyright (C) 2002 Randolph Chung <tausq with parisc-linux.org> |
16 | * Copyright (C) 2005-2006 Kyle McMartin <kyle at parisc-linux.org> | 16 | * Copyright (C) 2005-2006 Kyle McMartin <kyle at parisc-linux.org> |
@@ -282,8 +282,8 @@ | |||
282 | * to worry about faulting trying to copy in a larger 64-bit | 282 | * to worry about faulting trying to copy in a larger 64-bit |
283 | * struct from a 32-bit user-space app. | 283 | * struct from a 32-bit user-space app. |
284 | */ | 284 | */ |
285 | ENTRY_SAME(rt_sigqueueinfo) | 285 | ENTRY_COMP(rt_sigqueueinfo) |
286 | ENTRY_SAME(rt_sigsuspend_wrapper) /* not really SAME -- see the code */ | 286 | ENTRY_COMP(rt_sigsuspend) |
287 | ENTRY_SAME(chown) /* 180 */ | 287 | ENTRY_SAME(chown) /* 180 */ |
288 | /* setsockopt() used by iptables: SO_SET_REPLACE/SO_SET_ADD_COUNTERS */ | 288 | /* setsockopt() used by iptables: SO_SET_REPLACE/SO_SET_ADD_COUNTERS */ |
289 | ENTRY_COMP(setsockopt) | 289 | ENTRY_COMP(setsockopt) |
@@ -377,9 +377,9 @@ | |||
377 | ENTRY_SAME(inotify_init) | 377 | ENTRY_SAME(inotify_init) |
378 | ENTRY_SAME(inotify_add_watch) /* 270 */ | 378 | ENTRY_SAME(inotify_add_watch) /* 270 */ |
379 | ENTRY_SAME(inotify_rm_watch) | 379 | ENTRY_SAME(inotify_rm_watch) |
380 | ENTRY_SAME(ni_syscall) /* 271 ENTRY_COMP(pselect6) */ | ||
381 | ENTRY_SAME(ni_syscall) /* 272 ENTRY_COMP(ppoll) */ | ||
382 | ENTRY_SAME(migrate_pages) | 380 | ENTRY_SAME(migrate_pages) |
381 | ENTRY_COMP(pselect6) | ||
382 | ENTRY_COMP(ppoll) | ||
383 | ENTRY_COMP(openat) /* 275 */ | 383 | ENTRY_COMP(openat) /* 275 */ |
384 | ENTRY_SAME(mkdirat) | 384 | ENTRY_SAME(mkdirat) |
385 | ENTRY_SAME(mknodat) | 385 | ENTRY_SAME(mknodat) |
@@ -399,5 +399,11 @@ | |||
399 | ENTRY_SAME(splice) | 399 | ENTRY_SAME(splice) |
400 | ENTRY_OURS(sync_file_range) | 400 | ENTRY_OURS(sync_file_range) |
401 | ENTRY_SAME(tee) | 401 | ENTRY_SAME(tee) |
402 | ENTRY_COMP(vmsplice) | ||
403 | ENTRY_COMP(move_pages) /* 295 */ | ||
404 | ENTRY_SAME(getcpu) | ||
405 | ENTRY_SAME(epoll_pwait) | ||
406 | ENTRY_COMP(statfs64) | ||
407 | ENTRY_COMP(fstatfs64) | ||
402 | /* Nothing yet */ | 408 | /* Nothing yet */ |
403 | 409 | ||
diff --git a/arch/parisc/kernel/time.c b/arch/parisc/kernel/time.c index 5f1b51af06a9..d1db8e518654 100644 --- a/arch/parisc/kernel/time.c +++ b/arch/parisc/kernel/time.c | |||
@@ -22,6 +22,7 @@ | |||
22 | #include <linux/init.h> | 22 | #include <linux/init.h> |
23 | #include <linux/smp.h> | 23 | #include <linux/smp.h> |
24 | #include <linux/profile.h> | 24 | #include <linux/profile.h> |
25 | #include <linux/clocksource.h> | ||
25 | 26 | ||
26 | #include <asm/uaccess.h> | 27 | #include <asm/uaccess.h> |
27 | #include <asm/io.h> | 28 | #include <asm/io.h> |
@@ -98,7 +99,7 @@ irqreturn_t timer_interrupt(int irq, void *dev_id) | |||
98 | * cycles after the IT fires. But it's arbitrary how much time passes | 99 | * cycles after the IT fires. But it's arbitrary how much time passes |
99 | * before we call it "late". I've picked one second. | 100 | * before we call it "late". I've picked one second. |
100 | */ | 101 | */ |
101 | if (ticks_elapsed > HZ) { | 102 | if (unlikely(ticks_elapsed > HZ)) { |
102 | /* Scenario 3: very long delay? bad in any case */ | 103 | /* Scenario 3: very long delay? bad in any case */ |
103 | printk (KERN_CRIT "timer_interrupt(CPU %d): delayed!" | 104 | printk (KERN_CRIT "timer_interrupt(CPU %d): delayed!" |
104 | " cycles %lX rem %lX " | 105 | " cycles %lX rem %lX " |
@@ -147,10 +148,6 @@ irqreturn_t timer_interrupt(int irq, void *dev_id) | |||
147 | write_sequnlock(&xtime_lock); | 148 | write_sequnlock(&xtime_lock); |
148 | } | 149 | } |
149 | 150 | ||
150 | /* check soft power switch status */ | ||
151 | if (cpu == 0 && !atomic_read(&power_tasklet.count)) | ||
152 | tasklet_schedule(&power_tasklet); | ||
153 | |||
154 | return IRQ_HANDLED; | 151 | return IRQ_HANDLED; |
155 | } | 152 | } |
156 | 153 | ||
@@ -172,121 +169,41 @@ unsigned long profile_pc(struct pt_regs *regs) | |||
172 | EXPORT_SYMBOL(profile_pc); | 169 | EXPORT_SYMBOL(profile_pc); |
173 | 170 | ||
174 | 171 | ||
175 | /* | 172 | /* clock source code */ |
176 | * Return the number of micro-seconds that elapsed since the last | ||
177 | * update to wall time (aka xtime). The xtime_lock | ||
178 | * must be at least read-locked when calling this routine. | ||
179 | */ | ||
180 | static inline unsigned long gettimeoffset (void) | ||
181 | { | ||
182 | #ifndef CONFIG_SMP | ||
183 | /* | ||
184 | * FIXME: This won't work on smp because jiffies are updated by cpu 0. | ||
185 | * Once parisc-linux learns the cr16 difference between processors, | ||
186 | * this could be made to work. | ||
187 | */ | ||
188 | unsigned long now; | ||
189 | unsigned long prev_tick; | ||
190 | unsigned long next_tick; | ||
191 | unsigned long elapsed_cycles; | ||
192 | unsigned long usec; | ||
193 | unsigned long cpuid = smp_processor_id(); | ||
194 | unsigned long cpt = clocktick; | ||
195 | |||
196 | next_tick = cpu_data[cpuid].it_value; | ||
197 | now = mfctl(16); /* Read the hardware interval timer. */ | ||
198 | 173 | ||
199 | prev_tick = next_tick - cpt; | 174 | static cycle_t read_cr16(void) |
175 | { | ||
176 | return get_cycles(); | ||
177 | } | ||
200 | 178 | ||
201 | /* Assume Scenario 1: "now" is later than prev_tick. */ | 179 | static int cr16_update_callback(void); |
202 | elapsed_cycles = now - prev_tick; | ||
203 | 180 | ||
204 | /* aproximate HZ with shifts. Intended math is "(elapsed/clocktick) > HZ" */ | 181 | static struct clocksource clocksource_cr16 = { |
205 | #if HZ == 1000 | 182 | .name = "cr16", |
206 | if (elapsed_cycles > (cpt << 10) ) | 183 | .rating = 300, |
207 | #elif HZ == 250 | 184 | .read = read_cr16, |
208 | if (elapsed_cycles > (cpt << 8) ) | 185 | .mask = CLOCKSOURCE_MASK(BITS_PER_LONG), |
209 | #elif HZ == 100 | 186 | .mult = 0, /* to be set */ |
210 | if (elapsed_cycles > (cpt << 7) ) | 187 | .shift = 22, |
211 | #else | 188 | .update_callback = cr16_update_callback, |
212 | #warn WTF is HZ set to anyway? | 189 | .is_continuous = 1, |
213 | if (elapsed_cycles > (HZ * cpt) ) | 190 | }; |
214 | #endif | ||
215 | { | ||
216 | /* Scenario 3: clock ticks are missing. */ | ||
217 | printk (KERN_CRIT "gettimeoffset(CPU %ld): missing %ld ticks!" | ||
218 | " cycles %lX prev/now/next %lX/%lX/%lX clock %lX\n", | ||
219 | cpuid, elapsed_cycles / cpt, | ||
220 | elapsed_cycles, prev_tick, now, next_tick, cpt); | ||
221 | } | ||
222 | 191 | ||
223 | /* FIXME: Can we improve the precision? Not with PAGE0. */ | 192 | static int cr16_update_callback(void) |
224 | usec = (elapsed_cycles * 10000) / PAGE0->mem_10msec; | ||
225 | return usec; | ||
226 | #else | ||
227 | return 0; | ||
228 | #endif | ||
229 | } | ||
230 | |||
231 | void | ||
232 | do_gettimeofday (struct timeval *tv) | ||
233 | { | 193 | { |
234 | unsigned long flags, seq, usec, sec; | 194 | int change = 0; |
235 | 195 | ||
236 | /* Hold xtime_lock and adjust timeval. */ | 196 | /* since the cr16 cycle counters are not syncronized across CPUs, |
237 | do { | 197 | we'll check if we should switch to a safe clocksource: */ |
238 | seq = read_seqbegin_irqsave(&xtime_lock, flags); | 198 | if (clocksource_cr16.rating != 0 && num_online_cpus() > 1) { |
239 | usec = gettimeoffset(); | 199 | clocksource_cr16.rating = 0; |
240 | sec = xtime.tv_sec; | 200 | clocksource_reselect(); |
241 | usec += (xtime.tv_nsec / 1000); | 201 | change = 1; |
242 | } while (read_seqretry_irqrestore(&xtime_lock, seq, flags)); | ||
243 | |||
244 | /* Move adjusted usec's into sec's. */ | ||
245 | while (usec >= USEC_PER_SEC) { | ||
246 | usec -= USEC_PER_SEC; | ||
247 | ++sec; | ||
248 | } | 202 | } |
249 | 203 | ||
250 | /* Return adjusted result. */ | 204 | return change; |
251 | tv->tv_sec = sec; | ||
252 | tv->tv_usec = usec; | ||
253 | } | 205 | } |
254 | 206 | ||
255 | EXPORT_SYMBOL(do_gettimeofday); | ||
256 | |||
257 | int | ||
258 | do_settimeofday (struct timespec *tv) | ||
259 | { | ||
260 | time_t wtm_sec, sec = tv->tv_sec; | ||
261 | long wtm_nsec, nsec = tv->tv_nsec; | ||
262 | |||
263 | if ((unsigned long)tv->tv_nsec >= NSEC_PER_SEC) | ||
264 | return -EINVAL; | ||
265 | |||
266 | write_seqlock_irq(&xtime_lock); | ||
267 | { | ||
268 | /* | ||
269 | * This is revolting. We need to set "xtime" | ||
270 | * correctly. However, the value in this location is | ||
271 | * the value at the most recent update of wall time. | ||
272 | * Discover what correction gettimeofday would have | ||
273 | * done, and then undo it! | ||
274 | */ | ||
275 | nsec -= gettimeoffset() * 1000; | ||
276 | |||
277 | wtm_sec = wall_to_monotonic.tv_sec + (xtime.tv_sec - sec); | ||
278 | wtm_nsec = wall_to_monotonic.tv_nsec + (xtime.tv_nsec - nsec); | ||
279 | |||
280 | set_normalized_timespec(&xtime, sec, nsec); | ||
281 | set_normalized_timespec(&wall_to_monotonic, wtm_sec, wtm_nsec); | ||
282 | |||
283 | ntp_clear(); | ||
284 | } | ||
285 | write_sequnlock_irq(&xtime_lock); | ||
286 | clock_was_set(); | ||
287 | return 0; | ||
288 | } | ||
289 | EXPORT_SYMBOL(do_settimeofday); | ||
290 | 207 | ||
291 | void __init start_cpu_itimer(void) | 208 | void __init start_cpu_itimer(void) |
292 | { | 209 | { |
@@ -301,11 +218,18 @@ void __init start_cpu_itimer(void) | |||
301 | void __init time_init(void) | 218 | void __init time_init(void) |
302 | { | 219 | { |
303 | static struct pdc_tod tod_data; | 220 | static struct pdc_tod tod_data; |
221 | unsigned long current_cr16_khz; | ||
304 | 222 | ||
305 | clocktick = (100 * PAGE0->mem_10msec) / HZ; | 223 | clocktick = (100 * PAGE0->mem_10msec) / HZ; |
306 | 224 | ||
307 | start_cpu_itimer(); /* get CPU 0 started */ | 225 | start_cpu_itimer(); /* get CPU 0 started */ |
308 | 226 | ||
227 | /* register at clocksource framework */ | ||
228 | current_cr16_khz = PAGE0->mem_10msec/10; /* kHz */ | ||
229 | clocksource_cr16.mult = clocksource_khz2mult(current_cr16_khz, | ||
230 | clocksource_cr16.shift); | ||
231 | clocksource_register(&clocksource_cr16); | ||
232 | |||
309 | if (pdc_tod_read(&tod_data) == 0) { | 233 | if (pdc_tod_read(&tod_data) == 0) { |
310 | unsigned long flags; | 234 | unsigned long flags; |
311 | 235 | ||
diff --git a/arch/parisc/kernel/traps.c b/arch/parisc/kernel/traps.c index 65cd6ca32fed..55bc1471967d 100644 --- a/arch/parisc/kernel/traps.c +++ b/arch/parisc/kernel/traps.c | |||
@@ -26,6 +26,7 @@ | |||
26 | #include <linux/interrupt.h> | 26 | #include <linux/interrupt.h> |
27 | #include <linux/console.h> | 27 | #include <linux/console.h> |
28 | #include <linux/kallsyms.h> | 28 | #include <linux/kallsyms.h> |
29 | #include <linux/bug.h> | ||
29 | 30 | ||
30 | #include <asm/assembly.h> | 31 | #include <asm/assembly.h> |
31 | #include <asm/system.h> | 32 | #include <asm/system.h> |
@@ -39,6 +40,8 @@ | |||
39 | #include <asm/pdc.h> | 40 | #include <asm/pdc.h> |
40 | #include <asm/pdc_chassis.h> | 41 | #include <asm/pdc_chassis.h> |
41 | #include <asm/unwind.h> | 42 | #include <asm/unwind.h> |
43 | #include <asm/tlbflush.h> | ||
44 | #include <asm/cacheflush.h> | ||
42 | 45 | ||
43 | #include "../math-emu/math-emu.h" /* for handle_fpe() */ | 46 | #include "../math-emu/math-emu.h" /* for handle_fpe() */ |
44 | 47 | ||
@@ -49,7 +52,7 @@ | |||
49 | DEFINE_SPINLOCK(pa_dbit_lock); | 52 | DEFINE_SPINLOCK(pa_dbit_lock); |
50 | #endif | 53 | #endif |
51 | 54 | ||
52 | int printbinary(char *buf, unsigned long x, int nbits) | 55 | static int printbinary(char *buf, unsigned long x, int nbits) |
53 | { | 56 | { |
54 | unsigned long mask = 1UL << (nbits - 1); | 57 | unsigned long mask = 1UL << (nbits - 1); |
55 | while (mask != 0) { | 58 | while (mask != 0) { |
@@ -61,7 +64,7 @@ int printbinary(char *buf, unsigned long x, int nbits) | |||
61 | return nbits; | 64 | return nbits; |
62 | } | 65 | } |
63 | 66 | ||
64 | #ifdef __LP64__ | 67 | #ifdef CONFIG_64BIT |
65 | #define RFMT "%016lx" | 68 | #define RFMT "%016lx" |
66 | #else | 69 | #else |
67 | #define RFMT "%08lx" | 70 | #define RFMT "%08lx" |
@@ -160,13 +163,13 @@ static void do_show_stack(struct unwind_frame_info *info) | |||
160 | { | 163 | { |
161 | int i = 1; | 164 | int i = 1; |
162 | 165 | ||
163 | printk("Backtrace:\n"); | 166 | printk(KERN_CRIT "Backtrace:\n"); |
164 | while (i <= 16) { | 167 | while (i <= 16) { |
165 | if (unwind_once(info) < 0 || info->ip == 0) | 168 | if (unwind_once(info) < 0 || info->ip == 0) |
166 | break; | 169 | break; |
167 | 170 | ||
168 | if (__kernel_text_address(info->ip)) { | 171 | if (__kernel_text_address(info->ip)) { |
169 | printk(" [<" RFMT ">] ", info->ip); | 172 | printk("%s [<" RFMT ">] ", (i&0x3)==1 ? KERN_CRIT : "", info->ip); |
170 | #ifdef CONFIG_KALLSYMS | 173 | #ifdef CONFIG_KALLSYMS |
171 | print_symbol("%s\n", info->ip); | 174 | print_symbol("%s\n", info->ip); |
172 | #else | 175 | #else |
@@ -185,18 +188,19 @@ void show_stack(struct task_struct *task, unsigned long *s) | |||
185 | 188 | ||
186 | if (!task) { | 189 | if (!task) { |
187 | unsigned long sp; | 190 | unsigned long sp; |
188 | struct pt_regs *r; | ||
189 | 191 | ||
190 | HERE: | 192 | HERE: |
191 | asm volatile ("copy %%r30, %0" : "=r"(sp)); | 193 | asm volatile ("copy %%r30, %0" : "=r"(sp)); |
192 | r = kzalloc(sizeof(struct pt_regs), GFP_KERNEL); | 194 | { |
193 | if (!r) | 195 | struct pt_regs r; |
194 | return; | 196 | |
195 | r->iaoq[0] = (unsigned long)&&HERE; | 197 | memset(&r, 0, sizeof(struct pt_regs)); |
196 | r->gr[2] = (unsigned long)__builtin_return_address(0); | 198 | r.iaoq[0] = (unsigned long)&&HERE; |
197 | r->gr[30] = sp; | 199 | r.gr[2] = (unsigned long)__builtin_return_address(0); |
198 | unwind_frame_init(&info, current, r); | 200 | r.gr[30] = sp; |
199 | kfree(r); | 201 | |
202 | unwind_frame_init(&info, current, &r); | ||
203 | } | ||
200 | } else { | 204 | } else { |
201 | unwind_frame_init_from_blocked_task(&info, task); | 205 | unwind_frame_init_from_blocked_task(&info, task); |
202 | } | 206 | } |
@@ -204,6 +208,11 @@ HERE: | |||
204 | do_show_stack(&info); | 208 | do_show_stack(&info); |
205 | } | 209 | } |
206 | 210 | ||
211 | int is_valid_bugaddr(unsigned long iaoq) | ||
212 | { | ||
213 | return 1; | ||
214 | } | ||
215 | |||
207 | void die_if_kernel(char *str, struct pt_regs *regs, long err) | 216 | void die_if_kernel(char *str, struct pt_regs *regs, long err) |
208 | { | 217 | { |
209 | if (user_mode(regs)) { | 218 | if (user_mode(regs)) { |
@@ -222,15 +231,15 @@ void die_if_kernel(char *str, struct pt_regs *regs, long err) | |||
222 | oops_in_progress = 1; | 231 | oops_in_progress = 1; |
223 | 232 | ||
224 | /* Amuse the user in a SPARC fashion */ | 233 | /* Amuse the user in a SPARC fashion */ |
225 | printk( | 234 | if (err) printk( |
226 | " _______________________________ \n" | 235 | KERN_CRIT " _______________________________ \n" |
227 | " < Your System ate a SPARC! Gah! >\n" | 236 | KERN_CRIT " < Your System ate a SPARC! Gah! >\n" |
228 | " ------------------------------- \n" | 237 | KERN_CRIT " ------------------------------- \n" |
229 | " \\ ^__^\n" | 238 | KERN_CRIT " \\ ^__^\n" |
230 | " \\ (xx)\\_______\n" | 239 | KERN_CRIT " \\ (xx)\\_______\n" |
231 | " (__)\\ )\\/\\\n" | 240 | KERN_CRIT " (__)\\ )\\/\\\n" |
232 | " U ||----w |\n" | 241 | KERN_CRIT " U ||----w |\n" |
233 | " || ||\n"); | 242 | KERN_CRIT " || ||\n"); |
234 | 243 | ||
235 | /* unlock the pdc lock if necessary */ | 244 | /* unlock the pdc lock if necessary */ |
236 | pdc_emergency_unlock(); | 245 | pdc_emergency_unlock(); |
@@ -242,9 +251,20 @@ void die_if_kernel(char *str, struct pt_regs *regs, long err) | |||
242 | if (!console_drivers) | 251 | if (!console_drivers) |
243 | pdc_console_restart(); | 252 | pdc_console_restart(); |
244 | 253 | ||
245 | printk(KERN_CRIT "%s (pid %d): %s (code %ld)\n", | 254 | if (err) |
246 | current->comm, current->pid, str, err); | 255 | printk(KERN_CRIT "%s (pid %d): %s (code %ld)\n", |
256 | current->comm, current->pid, str, err); | ||
257 | |||
258 | /* Wot's wrong wif bein' racy? */ | ||
259 | if (current->thread.flags & PARISC_KERNEL_DEATH) { | ||
260 | printk(KERN_CRIT "%s() recursion detected.\n", __FUNCTION__); | ||
261 | local_irq_enable(); | ||
262 | while (1); | ||
263 | } | ||
264 | current->thread.flags |= PARISC_KERNEL_DEATH; | ||
265 | |||
247 | show_regs(regs); | 266 | show_regs(regs); |
267 | dump_stack(); | ||
248 | 268 | ||
249 | if (in_interrupt()) | 269 | if (in_interrupt()) |
250 | panic("Fatal exception in interrupt"); | 270 | panic("Fatal exception in interrupt"); |
@@ -255,14 +275,6 @@ void die_if_kernel(char *str, struct pt_regs *regs, long err) | |||
255 | panic("Fatal exception"); | 275 | panic("Fatal exception"); |
256 | } | 276 | } |
257 | 277 | ||
258 | /* Wot's wrong wif bein' racy? */ | ||
259 | if (current->thread.flags & PARISC_KERNEL_DEATH) { | ||
260 | printk(KERN_CRIT "%s() recursion detected.\n", __FUNCTION__); | ||
261 | local_irq_enable(); | ||
262 | while (1); | ||
263 | } | ||
264 | |||
265 | current->thread.flags |= PARISC_KERNEL_DEATH; | ||
266 | do_exit(SIGSEGV); | 278 | do_exit(SIGSEGV); |
267 | } | 279 | } |
268 | 280 | ||
@@ -273,61 +285,45 @@ int syscall_ipi(int (*syscall) (struct pt_regs *), struct pt_regs *regs) | |||
273 | 285 | ||
274 | /* gdb uses break 4,8 */ | 286 | /* gdb uses break 4,8 */ |
275 | #define GDB_BREAK_INSN 0x10004 | 287 | #define GDB_BREAK_INSN 0x10004 |
276 | void handle_gdb_break(struct pt_regs *regs, int wot) | 288 | static void handle_gdb_break(struct pt_regs *regs, int wot) |
277 | { | 289 | { |
278 | struct siginfo si; | 290 | struct siginfo si; |
279 | 291 | ||
280 | si.si_code = wot; | ||
281 | si.si_addr = (void __user *) (regs->iaoq[0] & ~3); | ||
282 | si.si_signo = SIGTRAP; | 292 | si.si_signo = SIGTRAP; |
283 | si.si_errno = 0; | 293 | si.si_errno = 0; |
294 | si.si_code = wot; | ||
295 | si.si_addr = (void __user *) (regs->iaoq[0] & ~3); | ||
284 | force_sig_info(SIGTRAP, &si, current); | 296 | force_sig_info(SIGTRAP, &si, current); |
285 | } | 297 | } |
286 | 298 | ||
287 | void handle_break(unsigned iir, struct pt_regs *regs) | 299 | static void handle_break(struct pt_regs *regs) |
288 | { | 300 | { |
289 | struct siginfo si; | 301 | unsigned iir = regs->iir; |
290 | 302 | ||
291 | switch(iir) { | 303 | if (unlikely(iir == PARISC_BUG_BREAK_INSN && !user_mode(regs))) { |
292 | case 0x00: | 304 | /* check if a BUG() or WARN() trapped here. */ |
293 | #ifdef PRINT_USER_FAULTS | 305 | enum bug_trap_type tt; |
294 | printk(KERN_DEBUG "break 0,0: pid=%d command='%s'\n", | 306 | tt = report_bug(regs->iaoq[0] & ~3); |
295 | current->pid, current->comm); | 307 | if (tt == BUG_TRAP_TYPE_WARN) { |
296 | #endif | 308 | regs->iaoq[0] += 4; |
297 | die_if_kernel("Breakpoint", regs, 0); | 309 | regs->iaoq[1] += 4; |
298 | #ifdef PRINT_USER_FAULTS | 310 | return; /* return to next instruction when WARN_ON(). */ |
299 | show_regs(regs); | 311 | } |
300 | #endif | 312 | die_if_kernel("Unknown kernel breakpoint", regs, |
301 | si.si_code = TRAP_BRKPT; | 313 | (tt == BUG_TRAP_TYPE_NONE) ? 9 : 0); |
302 | si.si_addr = (void __user *) (regs->iaoq[0] & ~3); | 314 | } |
303 | si.si_signo = SIGTRAP; | ||
304 | force_sig_info(SIGTRAP, &si, current); | ||
305 | break; | ||
306 | |||
307 | case GDB_BREAK_INSN: | ||
308 | die_if_kernel("Breakpoint", regs, 0); | ||
309 | handle_gdb_break(regs, TRAP_BRKPT); | ||
310 | break; | ||
311 | 315 | ||
312 | default: | ||
313 | #ifdef PRINT_USER_FAULTS | 316 | #ifdef PRINT_USER_FAULTS |
314 | printk(KERN_DEBUG "break %#08x: pid=%d command='%s'\n", | 317 | if (unlikely(iir != GDB_BREAK_INSN)) { |
315 | iir, current->pid, current->comm); | 318 | printk(KERN_DEBUG "break %d,%d: pid=%d command='%s'\n", |
319 | iir & 31, (iir>>13) & ((1<<13)-1), | ||
320 | current->pid, current->comm); | ||
316 | show_regs(regs); | 321 | show_regs(regs); |
317 | #endif | ||
318 | si.si_signo = SIGTRAP; | ||
319 | si.si_code = TRAP_BRKPT; | ||
320 | si.si_addr = (void __user *) (regs->iaoq[0] & ~3); | ||
321 | force_sig_info(SIGTRAP, &si, current); | ||
322 | return; | ||
323 | } | 322 | } |
324 | } | 323 | #endif |
325 | |||
326 | 324 | ||
327 | int handle_toc(void) | 325 | /* send standard GDB signal */ |
328 | { | 326 | handle_gdb_break(regs, TRAP_BRKPT); |
329 | printk(KERN_CRIT "TOC call.\n"); | ||
330 | return 0; | ||
331 | } | 327 | } |
332 | 328 | ||
333 | static void default_trap(int code, struct pt_regs *regs) | 329 | static void default_trap(int code, struct pt_regs *regs) |
@@ -336,7 +332,7 @@ static void default_trap(int code, struct pt_regs *regs) | |||
336 | show_regs(regs); | 332 | show_regs(regs); |
337 | } | 333 | } |
338 | 334 | ||
339 | void (*cpu_lpmc) (int code, struct pt_regs *regs) = default_trap; | 335 | void (*cpu_lpmc) (int code, struct pt_regs *regs) __read_mostly = default_trap; |
340 | 336 | ||
341 | 337 | ||
342 | void transfer_pim_to_trap_frame(struct pt_regs *regs) | 338 | void transfer_pim_to_trap_frame(struct pt_regs *regs) |
@@ -554,7 +550,8 @@ void handle_interruption(int code, struct pt_regs *regs) | |||
554 | /* Low-priority machine check */ | 550 | /* Low-priority machine check */ |
555 | pdc_chassis_send_status(PDC_CHASSIS_DIRECT_LPMC); | 551 | pdc_chassis_send_status(PDC_CHASSIS_DIRECT_LPMC); |
556 | 552 | ||
557 | flush_all_caches(); | 553 | flush_cache_all(); |
554 | flush_tlb_all(); | ||
558 | cpu_lpmc(5, regs); | 555 | cpu_lpmc(5, regs); |
559 | return; | 556 | return; |
560 | 557 | ||
@@ -572,7 +569,7 @@ void handle_interruption(int code, struct pt_regs *regs) | |||
572 | 569 | ||
573 | case 9: | 570 | case 9: |
574 | /* Break instruction trap */ | 571 | /* Break instruction trap */ |
575 | handle_break(regs->iir,regs); | 572 | handle_break(regs); |
576 | return; | 573 | return; |
577 | 574 | ||
578 | case 10: | 575 | case 10: |
@@ -840,7 +837,7 @@ int __init check_ivt(void *iva) | |||
840 | return 0; | 837 | return 0; |
841 | } | 838 | } |
842 | 839 | ||
843 | #ifndef __LP64__ | 840 | #ifndef CONFIG_64BIT |
844 | extern const void fault_vector_11; | 841 | extern const void fault_vector_11; |
845 | #endif | 842 | #endif |
846 | extern const void fault_vector_20; | 843 | extern const void fault_vector_20; |
@@ -852,7 +849,7 @@ void __init trap_init(void) | |||
852 | if (boot_cpu_data.cpu_type >= pcxu) | 849 | if (boot_cpu_data.cpu_type >= pcxu) |
853 | iva = (void *) &fault_vector_20; | 850 | iva = (void *) &fault_vector_20; |
854 | else | 851 | else |
855 | #ifdef __LP64__ | 852 | #ifdef CONFIG_64BIT |
856 | panic("Can't boot 64-bit OS on PA1.1 processor!"); | 853 | panic("Can't boot 64-bit OS on PA1.1 processor!"); |
857 | #else | 854 | #else |
858 | iva = (void *) &fault_vector_11; | 855 | iva = (void *) &fault_vector_11; |
diff --git a/arch/parisc/kernel/unaligned.c b/arch/parisc/kernel/unaligned.c index bd2230d6a2a6..347bb922e6d0 100644 --- a/arch/parisc/kernel/unaligned.c +++ b/arch/parisc/kernel/unaligned.c | |||
@@ -20,8 +20,11 @@ | |||
20 | * | 20 | * |
21 | */ | 21 | */ |
22 | 22 | ||
23 | #include <linux/jiffies.h> | ||
23 | #include <linux/kernel.h> | 24 | #include <linux/kernel.h> |
24 | #include <linux/module.h> | 25 | #include <linux/module.h> |
26 | #include <linux/sched.h> | ||
27 | #include <linux/signal.h> | ||
25 | #include <asm/uaccess.h> | 28 | #include <asm/uaccess.h> |
26 | 29 | ||
27 | /* #define DEBUG_UNALIGNED 1 */ | 30 | /* #define DEBUG_UNALIGNED 1 */ |
@@ -32,7 +35,7 @@ | |||
32 | #define DPRINTF(fmt, args...) | 35 | #define DPRINTF(fmt, args...) |
33 | #endif | 36 | #endif |
34 | 37 | ||
35 | #ifdef __LP64__ | 38 | #ifdef CONFIG_64BIT |
36 | #define RFMT "%016lx" | 39 | #define RFMT "%016lx" |
37 | #else | 40 | #else |
38 | #define RFMT "%08lx" | 41 | #define RFMT "%08lx" |
@@ -147,15 +150,8 @@ static int emulate_ldh(struct pt_regs *regs, int toreg) | |||
147 | "4: ldi -2, %1\n" | 150 | "4: ldi -2, %1\n" |
148 | FIXUP_BRANCH(3b) | 151 | FIXUP_BRANCH(3b) |
149 | " .previous\n" | 152 | " .previous\n" |
150 | " .section __ex_table,\"aw\"\n" | 153 | ASM_EXCEPTIONTABLE_ENTRY(1b, 4b) |
151 | #ifdef __LP64__ | 154 | ASM_EXCEPTIONTABLE_ENTRY(2b, 4b) |
152 | " .dword 1b,4b\n" | ||
153 | " .dword 2b,4b\n" | ||
154 | #else | ||
155 | " .word 1b,4b\n" | ||
156 | " .word 2b,4b\n" | ||
157 | #endif | ||
158 | " .previous\n" | ||
159 | : "=r" (val), "=r" (ret) | 155 | : "=r" (val), "=r" (ret) |
160 | : "0" (val), "r" (saddr), "r" (regs->isr) | 156 | : "0" (val), "r" (saddr), "r" (regs->isr) |
161 | : "r20", FIXUP_BRANCH_CLOBBER ); | 157 | : "r20", FIXUP_BRANCH_CLOBBER ); |
@@ -192,15 +188,8 @@ static int emulate_ldw(struct pt_regs *regs, int toreg, int flop) | |||
192 | "4: ldi -2, %1\n" | 188 | "4: ldi -2, %1\n" |
193 | FIXUP_BRANCH(3b) | 189 | FIXUP_BRANCH(3b) |
194 | " .previous\n" | 190 | " .previous\n" |
195 | " .section __ex_table,\"aw\"\n" | 191 | ASM_EXCEPTIONTABLE_ENTRY(1b, 4b) |
196 | #ifdef __LP64__ | 192 | ASM_EXCEPTIONTABLE_ENTRY(2b, 4b) |
197 | " .dword 1b,4b\n" | ||
198 | " .dword 2b,4b\n" | ||
199 | #else | ||
200 | " .word 1b,4b\n" | ||
201 | " .word 2b,4b\n" | ||
202 | #endif | ||
203 | " .previous\n" | ||
204 | : "=r" (val), "=r" (ret) | 193 | : "=r" (val), "=r" (ret) |
205 | : "0" (val), "r" (saddr), "r" (regs->isr) | 194 | : "0" (val), "r" (saddr), "r" (regs->isr) |
206 | : "r19", "r20", FIXUP_BRANCH_CLOBBER ); | 195 | : "r19", "r20", FIXUP_BRANCH_CLOBBER ); |
@@ -224,7 +213,7 @@ static int emulate_ldd(struct pt_regs *regs, int toreg, int flop) | |||
224 | regs->isr, regs->ior, toreg); | 213 | regs->isr, regs->ior, toreg); |
225 | #ifdef CONFIG_PA20 | 214 | #ifdef CONFIG_PA20 |
226 | 215 | ||
227 | #ifndef __LP64__ | 216 | #ifndef CONFIG_64BIT |
228 | if (!flop) | 217 | if (!flop) |
229 | return -1; | 218 | return -1; |
230 | #endif | 219 | #endif |
@@ -243,15 +232,8 @@ static int emulate_ldd(struct pt_regs *regs, int toreg, int flop) | |||
243 | "4: ldi -2, %1\n" | 232 | "4: ldi -2, %1\n" |
244 | FIXUP_BRANCH(3b) | 233 | FIXUP_BRANCH(3b) |
245 | " .previous\n" | 234 | " .previous\n" |
246 | " .section __ex_table,\"aw\"\n" | 235 | ASM_EXCEPTIONTABLE_ENTRY(1b,4b) |
247 | #ifdef __LP64__ | 236 | ASM_EXCEPTIONTABLE_ENTRY(2b,4b) |
248 | " .dword 1b,4b\n" | ||
249 | " .dword 2b,4b\n" | ||
250 | #else | ||
251 | " .word 1b,4b\n" | ||
252 | " .word 2b,4b\n" | ||
253 | #endif | ||
254 | " .previous\n" | ||
255 | : "=r" (val), "=r" (ret) | 237 | : "=r" (val), "=r" (ret) |
256 | : "0" (val), "r" (saddr), "r" (regs->isr) | 238 | : "0" (val), "r" (saddr), "r" (regs->isr) |
257 | : "r19", "r20", FIXUP_BRANCH_CLOBBER ); | 239 | : "r19", "r20", FIXUP_BRANCH_CLOBBER ); |
@@ -275,17 +257,9 @@ static int emulate_ldd(struct pt_regs *regs, int toreg, int flop) | |||
275 | "5: ldi -2, %2\n" | 257 | "5: ldi -2, %2\n" |
276 | FIXUP_BRANCH(4b) | 258 | FIXUP_BRANCH(4b) |
277 | " .previous\n" | 259 | " .previous\n" |
278 | " .section __ex_table,\"aw\"\n" | 260 | ASM_EXCEPTIONTABLE_ENTRY(1b,5b) |
279 | #ifdef __LP64__ | 261 | ASM_EXCEPTIONTABLE_ENTRY(2b,5b) |
280 | " .dword 1b,5b\n" | 262 | ASM_EXCEPTIONTABLE_ENTRY(3b,5b) |
281 | " .dword 2b,5b\n" | ||
282 | " .dword 3b,5b\n" | ||
283 | #else | ||
284 | " .word 1b,5b\n" | ||
285 | " .word 2b,5b\n" | ||
286 | " .word 3b,5b\n" | ||
287 | #endif | ||
288 | " .previous\n" | ||
289 | : "=r" (valh), "=r" (vall), "=r" (ret) | 263 | : "=r" (valh), "=r" (vall), "=r" (ret) |
290 | : "0" (valh), "1" (vall), "r" (saddr), "r" (regs->isr) | 264 | : "0" (valh), "1" (vall), "r" (saddr), "r" (regs->isr) |
291 | : "r19", "r20", FIXUP_BRANCH_CLOBBER ); | 265 | : "r19", "r20", FIXUP_BRANCH_CLOBBER ); |
@@ -325,15 +299,8 @@ static int emulate_sth(struct pt_regs *regs, int frreg) | |||
325 | "4: ldi -2, %0\n" | 299 | "4: ldi -2, %0\n" |
326 | FIXUP_BRANCH(3b) | 300 | FIXUP_BRANCH(3b) |
327 | " .previous\n" | 301 | " .previous\n" |
328 | " .section __ex_table,\"aw\"\n" | 302 | ASM_EXCEPTIONTABLE_ENTRY(1b,4b) |
329 | #ifdef __LP64__ | 303 | ASM_EXCEPTIONTABLE_ENTRY(2b,4b) |
330 | " .dword 1b,4b\n" | ||
331 | " .dword 2b,4b\n" | ||
332 | #else | ||
333 | " .word 1b,4b\n" | ||
334 | " .word 2b,4b\n" | ||
335 | #endif | ||
336 | " .previous\n" | ||
337 | : "=r" (ret) | 304 | : "=r" (ret) |
338 | : "r" (val), "r" (regs->ior), "r" (regs->isr) | 305 | : "r" (val), "r" (regs->ior), "r" (regs->isr) |
339 | : "r19", FIXUP_BRANCH_CLOBBER ); | 306 | : "r19", FIXUP_BRANCH_CLOBBER ); |
@@ -379,15 +346,8 @@ static int emulate_stw(struct pt_regs *regs, int frreg, int flop) | |||
379 | "4: ldi -2, %0\n" | 346 | "4: ldi -2, %0\n" |
380 | FIXUP_BRANCH(3b) | 347 | FIXUP_BRANCH(3b) |
381 | " .previous\n" | 348 | " .previous\n" |
382 | " .section __ex_table,\"aw\"\n" | 349 | ASM_EXCEPTIONTABLE_ENTRY(1b,4b) |
383 | #ifdef __LP64__ | 350 | ASM_EXCEPTIONTABLE_ENTRY(2b,4b) |
384 | " .dword 1b,4b\n" | ||
385 | " .dword 2b,4b\n" | ||
386 | #else | ||
387 | " .word 1b,4b\n" | ||
388 | " .word 2b,4b\n" | ||
389 | #endif | ||
390 | " .previous\n" | ||
391 | : "=r" (ret) | 351 | : "=r" (ret) |
392 | : "r" (val), "r" (regs->ior), "r" (regs->isr) | 352 | : "r" (val), "r" (regs->ior), "r" (regs->isr) |
393 | : "r19", "r20", "r21", "r22", "r1", FIXUP_BRANCH_CLOBBER ); | 353 | : "r19", "r20", "r21", "r22", "r1", FIXUP_BRANCH_CLOBBER ); |
@@ -410,7 +370,7 @@ static int emulate_std(struct pt_regs *regs, int frreg, int flop) | |||
410 | val, regs->isr, regs->ior); | 370 | val, regs->isr, regs->ior); |
411 | 371 | ||
412 | #ifdef CONFIG_PA20 | 372 | #ifdef CONFIG_PA20 |
413 | #ifndef __LP64__ | 373 | #ifndef CONFIG_64BIT |
414 | if (!flop) | 374 | if (!flop) |
415 | return -1; | 375 | return -1; |
416 | #endif | 376 | #endif |
@@ -436,19 +396,10 @@ static int emulate_std(struct pt_regs *regs, int frreg, int flop) | |||
436 | "6: ldi -2, %0\n" | 396 | "6: ldi -2, %0\n" |
437 | FIXUP_BRANCH(5b) | 397 | FIXUP_BRANCH(5b) |
438 | " .previous\n" | 398 | " .previous\n" |
439 | " .section __ex_table,\"aw\"\n" | 399 | ASM_EXCEPTIONTABLE_ENTRY(1b,6b) |
440 | #ifdef __LP64__ | 400 | ASM_EXCEPTIONTABLE_ENTRY(2b,6b) |
441 | " .dword 1b,6b\n" | 401 | ASM_EXCEPTIONTABLE_ENTRY(3b,6b) |
442 | " .dword 2b,6b\n" | 402 | ASM_EXCEPTIONTABLE_ENTRY(4b,6b) |
443 | " .dword 3b,6b\n" | ||
444 | " .dword 4b,6b\n" | ||
445 | #else | ||
446 | " .word 1b,6b\n" | ||
447 | " .word 2b,6b\n" | ||
448 | " .word 3b,6b\n" | ||
449 | " .word 4b,6b\n" | ||
450 | #endif | ||
451 | " .previous\n" | ||
452 | : "=r" (ret) | 403 | : "=r" (ret) |
453 | : "r" (val), "r" (regs->ior), "r" (regs->isr) | 404 | : "r" (val), "r" (regs->ior), "r" (regs->isr) |
454 | : "r19", "r20", "r21", "r22", "r1", FIXUP_BRANCH_CLOBBER ); | 405 | : "r19", "r20", "r21", "r22", "r1", FIXUP_BRANCH_CLOBBER ); |
@@ -479,21 +430,11 @@ static int emulate_std(struct pt_regs *regs, int frreg, int flop) | |||
479 | "7: ldi -2, %0\n" | 430 | "7: ldi -2, %0\n" |
480 | FIXUP_BRANCH(6b) | 431 | FIXUP_BRANCH(6b) |
481 | " .previous\n" | 432 | " .previous\n" |
482 | " .section __ex_table,\"aw\"\n" | 433 | ASM_EXCEPTIONTABLE_ENTRY(1b,7b) |
483 | #ifdef __LP64__ | 434 | ASM_EXCEPTIONTABLE_ENTRY(2b,7b) |
484 | " .dword 1b,7b\n" | 435 | ASM_EXCEPTIONTABLE_ENTRY(3b,7b) |
485 | " .dword 2b,7b\n" | 436 | ASM_EXCEPTIONTABLE_ENTRY(4b,7b) |
486 | " .dword 3b,7b\n" | 437 | ASM_EXCEPTIONTABLE_ENTRY(5b,7b) |
487 | " .dword 4b,7b\n" | ||
488 | " .dword 5b,7b\n" | ||
489 | #else | ||
490 | " .word 1b,7b\n" | ||
491 | " .word 2b,7b\n" | ||
492 | " .word 3b,7b\n" | ||
493 | " .word 4b,7b\n" | ||
494 | " .word 5b,7b\n" | ||
495 | #endif | ||
496 | " .previous\n" | ||
497 | : "=r" (ret) | 438 | : "=r" (ret) |
498 | : "r" (valh), "r" (vall), "r" (regs->ior), "r" (regs->isr) | 439 | : "r" (valh), "r" (vall), "r" (regs->ior), "r" (regs->isr) |
499 | : "r19", "r20", "r21", "r1", FIXUP_BRANCH_CLOBBER ); | 440 | : "r19", "r20", "r21", "r1", FIXUP_BRANCH_CLOBBER ); |
diff --git a/arch/parisc/kernel/unwind.c b/arch/parisc/kernel/unwind.c index c10ab47d81fa..5f75b3e65986 100644 --- a/arch/parisc/kernel/unwind.c +++ b/arch/parisc/kernel/unwind.c | |||
@@ -10,6 +10,7 @@ | |||
10 | 10 | ||
11 | #include <linux/kernel.h> | 11 | #include <linux/kernel.h> |
12 | #include <linux/init.h> | 12 | #include <linux/init.h> |
13 | #include <linux/sched.h> | ||
13 | #include <linux/slab.h> | 14 | #include <linux/slab.h> |
14 | #include <linux/kallsyms.h> | 15 | #include <linux/kallsyms.h> |
15 | 16 | ||
diff --git a/arch/parisc/kernel/vmlinux.lds.S b/arch/parisc/kernel/vmlinux.lds.S index 3b78c2794c36..2a8253358c6c 100644 --- a/arch/parisc/kernel/vmlinux.lds.S +++ b/arch/parisc/kernel/vmlinux.lds.S | |||
@@ -68,6 +68,8 @@ SECTIONS | |||
68 | 68 | ||
69 | RODATA | 69 | RODATA |
70 | 70 | ||
71 | BUG_TABLE | ||
72 | |||
71 | /* writeable */ | 73 | /* writeable */ |
72 | . = ALIGN(ASM_PAGE_SIZE); /* Make sure this is page aligned so | 74 | . = ALIGN(ASM_PAGE_SIZE); /* Make sure this is page aligned so |
73 | that we can properly leave these | 75 | that we can properly leave these |
diff --git a/arch/parisc/lib/bitops.c b/arch/parisc/lib/bitops.c index f352666b5b2f..e3eb739fab19 100644 --- a/arch/parisc/lib/bitops.c +++ b/arch/parisc/lib/bitops.c | |||
@@ -17,7 +17,7 @@ raw_spinlock_t __atomic_hash[ATOMIC_HASH_SIZE] __lock_aligned = { | |||
17 | }; | 17 | }; |
18 | #endif | 18 | #endif |
19 | 19 | ||
20 | #ifdef __LP64__ | 20 | #ifdef CONFIG_64BIT |
21 | unsigned long __xchg64(unsigned long x, unsigned long *ptr) | 21 | unsigned long __xchg64(unsigned long x, unsigned long *ptr) |
22 | { | 22 | { |
23 | unsigned long temp, flags; | 23 | unsigned long temp, flags; |
@@ -56,7 +56,7 @@ unsigned long __xchg8(char x, char *ptr) | |||
56 | } | 56 | } |
57 | 57 | ||
58 | 58 | ||
59 | #ifdef __LP64__ | 59 | #ifdef CONFIG_64BIT |
60 | unsigned long __cmpxchg_u64(volatile unsigned long *ptr, unsigned long old, unsigned long new) | 60 | unsigned long __cmpxchg_u64(volatile unsigned long *ptr, unsigned long old, unsigned long new) |
61 | { | 61 | { |
62 | unsigned long flags; | 62 | unsigned long flags; |
diff --git a/arch/parisc/lib/fixup.S b/arch/parisc/lib/fixup.S index ecce3d35401f..d172d4245cdc 100644 --- a/arch/parisc/lib/fixup.S +++ b/arch/parisc/lib/fixup.S | |||
@@ -22,6 +22,7 @@ | |||
22 | #include <asm/asm-offsets.h> | 22 | #include <asm/asm-offsets.h> |
23 | #include <asm/assembly.h> | 23 | #include <asm/assembly.h> |
24 | #include <asm/errno.h> | 24 | #include <asm/errno.h> |
25 | #include <linux/linkage.h> | ||
25 | 26 | ||
26 | #ifdef CONFIG_SMP | 27 | #ifdef CONFIG_SMP |
27 | .macro get_fault_ip t1 t2 | 28 | .macro get_fault_ip t1 t2 |
@@ -30,7 +31,7 @@ | |||
30 | /* t2 = smp_processor_id() */ | 31 | /* t2 = smp_processor_id() */ |
31 | mfctl 30,\t2 | 32 | mfctl 30,\t2 |
32 | ldw TI_CPU(\t2),\t2 | 33 | ldw TI_CPU(\t2),\t2 |
33 | #ifdef __LP64__ | 34 | #ifdef CONFIG_64BIT |
34 | extrd,u \t2,63,32,\t2 | 35 | extrd,u \t2,63,32,\t2 |
35 | #endif | 36 | #endif |
36 | /* t2 = &__per_cpu_offset[smp_processor_id()]; */ | 37 | /* t2 = &__per_cpu_offset[smp_processor_id()]; */ |
@@ -58,33 +59,34 @@ | |||
58 | .section .fixup, "ax" | 59 | .section .fixup, "ax" |
59 | 60 | ||
60 | /* get_user() fixups, store -EFAULT in r8, and 0 in r9 */ | 61 | /* get_user() fixups, store -EFAULT in r8, and 0 in r9 */ |
61 | .export fixup_get_user_skip_1 | 62 | ENTRY(fixup_get_user_skip_1) |
62 | fixup_get_user_skip_1: | ||
63 | get_fault_ip %r1,%r8 | 63 | get_fault_ip %r1,%r8 |
64 | ldo 4(%r1), %r1 | 64 | ldo 4(%r1), %r1 |
65 | ldi -EFAULT, %r8 | 65 | ldi -EFAULT, %r8 |
66 | bv %r0(%r1) | 66 | bv %r0(%r1) |
67 | copy %r0, %r9 | 67 | copy %r0, %r9 |
68 | ENDPROC(fixup_get_user_skip_1) | ||
68 | 69 | ||
69 | .export fixup_get_user_skip_2 | 70 | ENTRY(fixup_get_user_skip_2) |
70 | fixup_get_user_skip_2: | ||
71 | get_fault_ip %r1,%r8 | 71 | get_fault_ip %r1,%r8 |
72 | ldo 8(%r1), %r1 | 72 | ldo 8(%r1), %r1 |
73 | ldi -EFAULT, %r8 | 73 | ldi -EFAULT, %r8 |
74 | bv %r0(%r1) | 74 | bv %r0(%r1) |
75 | copy %r0, %r9 | 75 | copy %r0, %r9 |
76 | ENDPROC(fixup_get_user_skip_2) | ||
76 | 77 | ||
77 | /* put_user() fixups, store -EFAULT in r8 */ | 78 | /* put_user() fixups, store -EFAULT in r8 */ |
78 | .export fixup_put_user_skip_1 | 79 | ENTRY(fixup_put_user_skip_1) |
79 | fixup_put_user_skip_1: | ||
80 | get_fault_ip %r1,%r8 | 80 | get_fault_ip %r1,%r8 |
81 | ldo 4(%r1), %r1 | 81 | ldo 4(%r1), %r1 |
82 | bv %r0(%r1) | 82 | bv %r0(%r1) |
83 | ldi -EFAULT, %r8 | 83 | ldi -EFAULT, %r8 |
84 | ENDPROC(fixup_put_user_skip_1) | ||
84 | 85 | ||
85 | .export fixup_put_user_skip_2 | 86 | ENTRY(fixup_put_user_skip_2) |
86 | fixup_put_user_skip_2: | ||
87 | get_fault_ip %r1,%r8 | 87 | get_fault_ip %r1,%r8 |
88 | ldo 8(%r1), %r1 | 88 | ldo 8(%r1), %r1 |
89 | bv %r0(%r1) | 89 | bv %r0(%r1) |
90 | ldi -EFAULT, %r8 | 90 | ldi -EFAULT, %r8 |
91 | ENDPROC(fixup_put_user_skip_2) | ||
92 | |||
diff --git a/arch/parisc/lib/lusercopy.S b/arch/parisc/lib/lusercopy.S index a0509855c9a7..1bd23ccec17b 100644 --- a/arch/parisc/lib/lusercopy.S +++ b/arch/parisc/lib/lusercopy.S | |||
@@ -37,6 +37,7 @@ | |||
37 | 37 | ||
38 | #include <asm/assembly.h> | 38 | #include <asm/assembly.h> |
39 | #include <asm/errno.h> | 39 | #include <asm/errno.h> |
40 | #include <linux/linkage.h> | ||
40 | 41 | ||
41 | /* | 42 | /* |
42 | * get_sr gets the appropriate space value into | 43 | * get_sr gets the appropriate space value into |
@@ -67,8 +68,7 @@ | |||
67 | * otherwise strlen (i.e. excludes zero byte) | 68 | * otherwise strlen (i.e. excludes zero byte) |
68 | */ | 69 | */ |
69 | 70 | ||
70 | .export lstrncpy_from_user,code | 71 | ENTRY(lstrncpy_from_user) |
71 | lstrncpy_from_user: | ||
72 | .proc | 72 | .proc |
73 | .callinfo NO_CALLS | 73 | .callinfo NO_CALLS |
74 | .entry | 74 | .entry |
@@ -87,6 +87,7 @@ $lsfu_exit: | |||
87 | bv %r0(%r2) | 87 | bv %r0(%r2) |
88 | nop | 88 | nop |
89 | .exit | 89 | .exit |
90 | ENDPROC(lstrncpy_from_user) | ||
90 | 91 | ||
91 | .section .fixup,"ax" | 92 | .section .fixup,"ax" |
92 | 3: fixup_branch $lsfu_exit | 93 | 3: fixup_branch $lsfu_exit |
@@ -94,13 +95,8 @@ $lsfu_exit: | |||
94 | .previous | 95 | .previous |
95 | 96 | ||
96 | .section __ex_table,"aw" | 97 | .section __ex_table,"aw" |
97 | #ifdef __LP64__ | 98 | ASM_ULONG_INSN 1b,3b |
98 | .dword 1b,3b | 99 | ASM_ULONG_INSN 2b,3b |
99 | .dword 2b,3b | ||
100 | #else | ||
101 | .word 1b,3b | ||
102 | .word 2b,3b | ||
103 | #endif | ||
104 | .previous | 100 | .previous |
105 | 101 | ||
106 | .procend | 102 | .procend |
@@ -112,8 +108,7 @@ $lsfu_exit: | |||
112 | * otherwise, returns number of bytes not transferred. | 108 | * otherwise, returns number of bytes not transferred. |
113 | */ | 109 | */ |
114 | 110 | ||
115 | .export lclear_user,code | 111 | ENTRY(lclear_user) |
116 | lclear_user: | ||
117 | .proc | 112 | .proc |
118 | .callinfo NO_CALLS | 113 | .callinfo NO_CALLS |
119 | .entry | 114 | .entry |
@@ -127,6 +122,7 @@ $lclu_done: | |||
127 | bv %r0(%r2) | 122 | bv %r0(%r2) |
128 | copy %r25,%r28 | 123 | copy %r25,%r28 |
129 | .exit | 124 | .exit |
125 | ENDPROC(lclear_user) | ||
130 | 126 | ||
131 | .section .fixup,"ax" | 127 | .section .fixup,"ax" |
132 | 2: fixup_branch $lclu_done | 128 | 2: fixup_branch $lclu_done |
@@ -134,11 +130,7 @@ $lclu_done: | |||
134 | .previous | 130 | .previous |
135 | 131 | ||
136 | .section __ex_table,"aw" | 132 | .section __ex_table,"aw" |
137 | #ifdef __LP64__ | 133 | ASM_ULONG_INSN 1b,2b |
138 | .dword 1b,2b | ||
139 | #else | ||
140 | .word 1b,2b | ||
141 | #endif | ||
142 | .previous | 134 | .previous |
143 | 135 | ||
144 | .procend | 136 | .procend |
@@ -151,8 +143,7 @@ $lclu_done: | |||
151 | * else strlen + 1 (i.e. includes zero byte). | 143 | * else strlen + 1 (i.e. includes zero byte). |
152 | */ | 144 | */ |
153 | 145 | ||
154 | .export lstrnlen_user,code | 146 | ENTRY(lstrnlen_user) |
155 | lstrnlen_user: | ||
156 | .proc | 147 | .proc |
157 | .callinfo NO_CALLS | 148 | .callinfo NO_CALLS |
158 | .entry | 149 | .entry |
@@ -172,6 +163,7 @@ $lslen_done: | |||
172 | $lslen_nzero: | 163 | $lslen_nzero: |
173 | b $lslen_done | 164 | b $lslen_done |
174 | ldo 1(%r26),%r26 /* special case for N == 0 */ | 165 | ldo 1(%r26),%r26 /* special case for N == 0 */ |
166 | ENDPROC(lstrnlen_user) | ||
175 | 167 | ||
176 | .section .fixup,"ax" | 168 | .section .fixup,"ax" |
177 | 3: fixup_branch $lslen_done | 169 | 3: fixup_branch $lslen_done |
@@ -179,13 +171,8 @@ $lslen_nzero: | |||
179 | .previous | 171 | .previous |
180 | 172 | ||
181 | .section __ex_table,"aw" | 173 | .section __ex_table,"aw" |
182 | #ifdef __LP64__ | 174 | ASM_ULONG_INSN 1b,3b |
183 | .dword 1b,3b | 175 | ASM_ULONG_INSN 2b,3b |
184 | .dword 2b,3b | ||
185 | #else | ||
186 | .word 1b,3b | ||
187 | .word 2b,3b | ||
188 | #endif | ||
189 | .previous | 176 | .previous |
190 | 177 | ||
191 | .procend | 178 | .procend |
diff --git a/arch/parisc/lib/memcpy.c b/arch/parisc/lib/memcpy.c index 5575e41f9d60..2c43ebe99a9c 100644 --- a/arch/parisc/lib/memcpy.c +++ b/arch/parisc/lib/memcpy.c | |||
@@ -96,30 +96,18 @@ DECLARE_PER_CPU(struct exception_data, exception_data); | |||
96 | #define DPRINTF(fmt, args...) | 96 | #define DPRINTF(fmt, args...) |
97 | #endif | 97 | #endif |
98 | 98 | ||
99 | #ifndef __LP64__ | ||
100 | #define EXC_WORD ".word" | ||
101 | #else | ||
102 | #define EXC_WORD ".dword" | ||
103 | #endif | ||
104 | |||
105 | #define def_load_ai_insn(_insn,_sz,_tt,_s,_a,_t,_e) \ | 99 | #define def_load_ai_insn(_insn,_sz,_tt,_s,_a,_t,_e) \ |
106 | __asm__ __volatile__ ( \ | 100 | __asm__ __volatile__ ( \ |
107 | "1:\t" #_insn ",ma " #_sz "(" _s ",%1), %0\n" \ | 101 | "1:\t" #_insn ",ma " #_sz "(" _s ",%1), %0\n\t" \ |
108 | "\t.section __ex_table,\"aw\"\n" \ | 102 | ASM_EXCEPTIONTABLE_ENTRY(1b,_e) \ |
109 | "\t" EXC_WORD "\t1b\n" \ | ||
110 | "\t" EXC_WORD "\t" #_e "\n" \ | ||
111 | "\t.previous\n" \ | ||
112 | : _tt(_t), "+r"(_a) \ | 103 | : _tt(_t), "+r"(_a) \ |
113 | : \ | 104 | : \ |
114 | : "r8") | 105 | : "r8") |
115 | 106 | ||
116 | #define def_store_ai_insn(_insn,_sz,_tt,_s,_a,_t,_e) \ | 107 | #define def_store_ai_insn(_insn,_sz,_tt,_s,_a,_t,_e) \ |
117 | __asm__ __volatile__ ( \ | 108 | __asm__ __volatile__ ( \ |
118 | "1:\t" #_insn ",ma %1, " #_sz "(" _s ",%0)\n" \ | 109 | "1:\t" #_insn ",ma %1, " #_sz "(" _s ",%0)\n\t" \ |
119 | "\t.section __ex_table,\"aw\"\n" \ | 110 | ASM_EXCEPTIONTABLE_ENTRY(1b,_e) \ |
120 | "\t" EXC_WORD "\t1b\n" \ | ||
121 | "\t" EXC_WORD "\t" #_e "\n" \ | ||
122 | "\t.previous\n" \ | ||
123 | : "+r"(_a) \ | 111 | : "+r"(_a) \ |
124 | : _tt(_t) \ | 112 | : _tt(_t) \ |
125 | : "r8") | 113 | : "r8") |
@@ -133,22 +121,16 @@ DECLARE_PER_CPU(struct exception_data, exception_data); | |||
133 | 121 | ||
134 | #define def_load_insn(_insn,_tt,_s,_o,_a,_t,_e) \ | 122 | #define def_load_insn(_insn,_tt,_s,_o,_a,_t,_e) \ |
135 | __asm__ __volatile__ ( \ | 123 | __asm__ __volatile__ ( \ |
136 | "1:\t" #_insn " " #_o "(" _s ",%1), %0\n" \ | 124 | "1:\t" #_insn " " #_o "(" _s ",%1), %0\n\t" \ |
137 | "\t.section __ex_table,\"aw\"\n" \ | 125 | ASM_EXCEPTIONTABLE_ENTRY(1b,_e) \ |
138 | "\t" EXC_WORD "\t1b\n" \ | ||
139 | "\t" EXC_WORD "\t" #_e "\n" \ | ||
140 | "\t.previous\n" \ | ||
141 | : _tt(_t) \ | 126 | : _tt(_t) \ |
142 | : "r"(_a) \ | 127 | : "r"(_a) \ |
143 | : "r8") | 128 | : "r8") |
144 | 129 | ||
145 | #define def_store_insn(_insn,_tt,_s,_t,_o,_a,_e) \ | 130 | #define def_store_insn(_insn,_tt,_s,_t,_o,_a,_e) \ |
146 | __asm__ __volatile__ ( \ | 131 | __asm__ __volatile__ ( \ |
147 | "1:\t" #_insn " %0, " #_o "(" _s ",%1)\n" \ | 132 | "1:\t" #_insn " %0, " #_o "(" _s ",%1)\n\t" \ |
148 | "\t.section __ex_table,\"aw\"\n" \ | 133 | ASM_EXCEPTIONTABLE_ENTRY(1b,_e) \ |
149 | "\t" EXC_WORD "\t1b\n" \ | ||
150 | "\t" EXC_WORD "\t" #_e "\n" \ | ||
151 | "\t.previous\n" \ | ||
152 | : \ | 134 | : \ |
153 | : _tt(_t), "r"(_a) \ | 135 | : _tt(_t), "r"(_a) \ |
154 | : "r8") | 136 | : "r8") |
@@ -167,8 +149,8 @@ extern inline void prefetch_dst(const void *addr) | |||
167 | __asm__("ldd 0(" d_space ",%0), %%r0" : : "r" (addr)); | 149 | __asm__("ldd 0(" d_space ",%0), %%r0" : : "r" (addr)); |
168 | } | 150 | } |
169 | #else | 151 | #else |
170 | #define prefetch_src(addr) | 152 | #define prefetch_src(addr) do { } while(0) |
171 | #define prefetch_dst(addr) | 153 | #define prefetch_dst(addr) do { } while(0) |
172 | #endif | 154 | #endif |
173 | 155 | ||
174 | /* Copy from a not-aligned src to an aligned dst, using shifts. Handles 4 words | 156 | /* Copy from a not-aligned src to an aligned dst, using shifts. Handles 4 words |
diff --git a/arch/parisc/mm/fault.c b/arch/parisc/mm/fault.c index 641f9c920eee..f6f67554c623 100644 --- a/arch/parisc/mm/fault.c +++ b/arch/parisc/mm/fault.c | |||
@@ -24,10 +24,6 @@ | |||
24 | /* dumped to the console via printk) */ | 24 | /* dumped to the console via printk) */ |
25 | 25 | ||
26 | 26 | ||
27 | /* Defines for parisc_acctyp() */ | ||
28 | #define READ 0 | ||
29 | #define WRITE 1 | ||
30 | |||
31 | /* Various important other fields */ | 27 | /* Various important other fields */ |
32 | #define bit22set(x) (x & 0x00000200) | 28 | #define bit22set(x) (x & 0x00000200) |
33 | #define bits23_25set(x) (x & 0x000001c0) | 29 | #define bits23_25set(x) (x & 0x000001c0) |
diff --git a/arch/parisc/mm/init.c b/arch/parisc/mm/init.c index 12117db0043b..75ea9f2a8a41 100644 --- a/arch/parisc/mm/init.c +++ b/arch/parisc/mm/init.c | |||
@@ -6,7 +6,7 @@ | |||
6 | * changed by Philipp Rumpf | 6 | * changed by Philipp Rumpf |
7 | * Copyright 1999 Philipp Rumpf (prumpf@tux.org) | 7 | * Copyright 1999 Philipp Rumpf (prumpf@tux.org) |
8 | * Copyright 2004 Randolph Chung (tausq@debian.org) | 8 | * Copyright 2004 Randolph Chung (tausq@debian.org) |
9 | * Copyright 2006 Helge Deller (deller@gmx.de) | 9 | * Copyright 2006-2007 Helge Deller (deller@gmx.de) |
10 | * | 10 | * |
11 | */ | 11 | */ |
12 | 12 | ||
@@ -24,6 +24,7 @@ | |||
24 | #include <linux/pagemap.h> /* for release_pages and page_cache_release */ | 24 | #include <linux/pagemap.h> /* for release_pages and page_cache_release */ |
25 | 25 | ||
26 | #include <asm/pgalloc.h> | 26 | #include <asm/pgalloc.h> |
27 | #include <asm/pgtable.h> | ||
27 | #include <asm/tlb.h> | 28 | #include <asm/tlb.h> |
28 | #include <asm/pdc_chassis.h> | 29 | #include <asm/pdc_chassis.h> |
29 | #include <asm/mmzone.h> | 30 | #include <asm/mmzone.h> |
@@ -65,11 +66,11 @@ static struct resource sysram_resources[MAX_PHYSMEM_RANGES] __read_mostly; | |||
65 | physmem_range_t pmem_ranges[MAX_PHYSMEM_RANGES] __read_mostly; | 66 | physmem_range_t pmem_ranges[MAX_PHYSMEM_RANGES] __read_mostly; |
66 | int npmem_ranges __read_mostly; | 67 | int npmem_ranges __read_mostly; |
67 | 68 | ||
68 | #ifdef __LP64__ | 69 | #ifdef CONFIG_64BIT |
69 | #define MAX_MEM (~0UL) | 70 | #define MAX_MEM (~0UL) |
70 | #else /* !__LP64__ */ | 71 | #else /* !CONFIG_64BIT */ |
71 | #define MAX_MEM (3584U*1024U*1024U) | 72 | #define MAX_MEM (3584U*1024U*1024U) |
72 | #endif /* !__LP64__ */ | 73 | #endif /* !CONFIG_64BIT */ |
73 | 74 | ||
74 | static unsigned long mem_limit __read_mostly = MAX_MEM; | 75 | static unsigned long mem_limit __read_mostly = MAX_MEM; |
75 | 76 | ||
@@ -452,6 +453,8 @@ unsigned long pcxl_dma_start __read_mostly; | |||
452 | 453 | ||
453 | void __init mem_init(void) | 454 | void __init mem_init(void) |
454 | { | 455 | { |
456 | int codesize, reservedpages, datasize, initsize; | ||
457 | |||
455 | high_memory = __va((max_pfn << PAGE_SHIFT)); | 458 | high_memory = __va((max_pfn << PAGE_SHIFT)); |
456 | 459 | ||
457 | #ifndef CONFIG_DISCONTIGMEM | 460 | #ifndef CONFIG_DISCONTIGMEM |
@@ -466,7 +469,32 @@ void __init mem_init(void) | |||
466 | } | 469 | } |
467 | #endif | 470 | #endif |
468 | 471 | ||
469 | printk(KERN_INFO "Memory: %luk available\n", num_physpages << (PAGE_SHIFT-10)); | 472 | codesize = (unsigned long)_etext - (unsigned long)_text; |
473 | datasize = (unsigned long)_edata - (unsigned long)_etext; | ||
474 | initsize = (unsigned long)__init_end - (unsigned long)__init_begin; | ||
475 | |||
476 | reservedpages = 0; | ||
477 | { | ||
478 | unsigned long pfn; | ||
479 | #ifdef CONFIG_DISCONTIGMEM | ||
480 | int i; | ||
481 | |||
482 | for (i = 0; i < npmem_ranges; i++) { | ||
483 | for (pfn = node_start_pfn(i); pfn < node_end_pfn(i); pfn++) { | ||
484 | if (PageReserved(pfn_to_page(pfn))) | ||
485 | reservedpages++; | ||
486 | } | ||
487 | } | ||
488 | #else /* !CONFIG_DISCONTIGMEM */ | ||
489 | for (pfn = 0; pfn < max_pfn; pfn++) { | ||
490 | /* | ||
491 | * Only count reserved RAM pages | ||
492 | */ | ||
493 | if (PageReserved(pfn_to_page(pfn))) | ||
494 | reservedpages++; | ||
495 | } | ||
496 | #endif | ||
497 | } | ||
470 | 498 | ||
471 | #ifdef CONFIG_PA11 | 499 | #ifdef CONFIG_PA11 |
472 | if (hppa_dma_ops == &pcxl_dma_ops) { | 500 | if (hppa_dma_ops == &pcxl_dma_ops) { |
@@ -480,6 +508,38 @@ void __init mem_init(void) | |||
480 | vmalloc_start = SET_MAP_OFFSET(MAP_START); | 508 | vmalloc_start = SET_MAP_OFFSET(MAP_START); |
481 | #endif | 509 | #endif |
482 | 510 | ||
511 | printk(KERN_INFO "Memory: %luk/%luk available (%dk kernel code, %dk reserved, %dk data, %dk init)\n", | ||
512 | (unsigned long)nr_free_pages() << (PAGE_SHIFT-10), | ||
513 | num_physpages << (PAGE_SHIFT-10), | ||
514 | codesize >> 10, | ||
515 | reservedpages << (PAGE_SHIFT-10), | ||
516 | datasize >> 10, | ||
517 | initsize >> 10 | ||
518 | ); | ||
519 | |||
520 | #ifdef CONFIG_DEBUG_KERNEL /* double-sanity-check paranoia */ | ||
521 | printk("virtual kernel memory layout:\n" | ||
522 | " vmalloc : 0x%p - 0x%p (%4ld MB)\n" | ||
523 | " memory : 0x%p - 0x%p (%4ld MB)\n" | ||
524 | " .init : 0x%p - 0x%p (%4ld kB)\n" | ||
525 | " .data : 0x%p - 0x%p (%4ld kB)\n" | ||
526 | " .text : 0x%p - 0x%p (%4ld kB)\n", | ||
527 | |||
528 | (void*)VMALLOC_START, (void*)VMALLOC_END, | ||
529 | (VMALLOC_END - VMALLOC_START) >> 20, | ||
530 | |||
531 | __va(0), high_memory, | ||
532 | ((unsigned long)high_memory - (unsigned long)__va(0)) >> 20, | ||
533 | |||
534 | __init_begin, __init_end, | ||
535 | ((unsigned long)__init_end - (unsigned long)__init_begin) >> 10, | ||
536 | |||
537 | _etext, _edata, | ||
538 | ((unsigned long)_edata - (unsigned long)_etext) >> 10, | ||
539 | |||
540 | _text, _etext, | ||
541 | ((unsigned long)_etext - (unsigned long)_text) >> 10); | ||
542 | #endif | ||
483 | } | 543 | } |
484 | 544 | ||
485 | unsigned long *empty_zero_page __read_mostly; | 545 | unsigned long *empty_zero_page __read_mostly; |
@@ -547,7 +607,7 @@ void show_mem(void) | |||
547 | 607 | ||
548 | printk("Zone list for zone %d on node %d: ", j, i); | 608 | printk("Zone list for zone %d on node %d: ", j, i); |
549 | for (k = 0; zl->zones[k] != NULL; k++) | 609 | for (k = 0; zl->zones[k] != NULL; k++) |
550 | printk("[%d/%s] ", zone_to_nid(zl->zones[k]), zl->zones[k]->name); | 610 | printk("[%ld/%s] ", zone_to_nid(zl->zones[k]), zl->zones[k]->name); |
551 | printk("\n"); | 611 | printk("\n"); |
552 | } | 612 | } |
553 | } | 613 | } |
diff --git a/arch/parisc/mm/ioremap.c b/arch/parisc/mm/ioremap.c index 44b42c7f639d..92d496ad07c9 100644 --- a/arch/parisc/mm/ioremap.c +++ b/arch/parisc/mm/ioremap.c | |||
@@ -26,7 +26,7 @@ | |||
26 | */ | 26 | */ |
27 | void __iomem * __ioremap(unsigned long phys_addr, unsigned long size, unsigned long flags) | 27 | void __iomem * __ioremap(unsigned long phys_addr, unsigned long size, unsigned long flags) |
28 | { | 28 | { |
29 | void *addr; | 29 | void __iomem *addr; |
30 | struct vm_struct *area; | 30 | struct vm_struct *area; |
31 | unsigned long offset, last_addr; | 31 | unsigned long offset, last_addr; |
32 | pgprot_t pgprot; | 32 | pgprot_t pgprot; |
@@ -80,14 +80,14 @@ void __iomem * __ioremap(unsigned long phys_addr, unsigned long size, unsigned l | |||
80 | if (!area) | 80 | if (!area) |
81 | return NULL; | 81 | return NULL; |
82 | 82 | ||
83 | addr = area->addr; | 83 | addr = (void __iomem *) area->addr; |
84 | if (ioremap_page_range((unsigned long)addr, (unsigned long)addr + size, | 84 | if (ioremap_page_range((unsigned long)addr, (unsigned long)addr + size, |
85 | phys_addr, pgprot)) { | 85 | phys_addr, pgprot)) { |
86 | vfree(addr); | 86 | vfree(addr); |
87 | return NULL; | 87 | return NULL; |
88 | } | 88 | } |
89 | 89 | ||
90 | return (void __iomem *) (offset + (char *)addr); | 90 | return (void __iomem *) (offset + (char __iomem *)addr); |
91 | } | 91 | } |
92 | EXPORT_SYMBOL(__ioremap); | 92 | EXPORT_SYMBOL(__ioremap); |
93 | 93 | ||
diff --git a/arch/parisc/mm/kmap.c b/arch/parisc/mm/kmap.c deleted file mode 100644 index 1b1acd5e2f6e..000000000000 --- a/arch/parisc/mm/kmap.c +++ /dev/null | |||
@@ -1,166 +0,0 @@ | |||
1 | /* | ||
2 | * kmap/page table map and unmap support routines | ||
3 | * | ||
4 | * Copyright 1999,2000 Hewlett-Packard Company | ||
5 | * Copyright 2000 John Marvin <jsm at hp.com> | ||
6 | * Copyright 2000 Grant Grundler <grundler at parisc-linux.org> | ||
7 | * Copyright 2000 Philipp Rumpf <prumpf@tux.org> | ||
8 | * | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License as published by | ||
12 | * the Free Software Foundation; either version 2 of the License, or | ||
13 | * (at your option) any later version. | ||
14 | * | ||
15 | * This program is distributed in the hope that it will be useful, | ||
16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
18 | * GNU General Public License for more details. | ||
19 | * | ||
20 | * You should have received a copy of the GNU General Public License | ||
21 | * along with this program; if not, write to the Free Software | ||
22 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
23 | */ | ||
24 | /* | ||
25 | ** Stolen mostly from arch/parisc/kernel/pci-dma.c | ||
26 | */ | ||
27 | |||
28 | #include <linux/types.h> | ||
29 | #include <linux/mm.h> | ||
30 | #include <linux/string.h> | ||
31 | #include <linux/pci.h> | ||
32 | |||
33 | #include <linux/slab.h> | ||
34 | #include <linux/vmalloc.h> | ||
35 | |||
36 | #include <asm/uaccess.h> | ||
37 | #include <asm/pgalloc.h> | ||
38 | |||
39 | #include <asm/io.h> | ||
40 | #include <asm/page.h> /* get_order */ | ||
41 | |||
42 | #undef flush_cache_all | ||
43 | #define flush_cache_all flush_all_caches | ||
44 | |||
45 | typedef void (*pte_iterator_t) (pte_t * pte, unsigned long arg); | ||
46 | |||
47 | #if 0 | ||
48 | /* XXX This routine could be used with iterate_page() to replace | ||
49 | * unmap_uncached_page() and save a little code space but I didn't | ||
50 | * do that since I'm not certain whether this is the right path. -PB | ||
51 | */ | ||
52 | static void unmap_cached_pte(pte_t * pte, unsigned long addr, unsigned long arg) | ||
53 | { | ||
54 | pte_t page = *pte; | ||
55 | pte_clear(&init_mm, addr, pte); | ||
56 | if (!pte_none(page)) { | ||
57 | if (pte_present(page)) { | ||
58 | unsigned long map_nr = pte_pagenr(page); | ||
59 | if (map_nr < max_mapnr) | ||
60 | __free_page(mem_map + map_nr); | ||
61 | } else { | ||
62 | printk(KERN_CRIT | ||
63 | "Whee.. Swapped out page in kernel page table\n"); | ||
64 | } | ||
65 | } | ||
66 | } | ||
67 | #endif | ||
68 | |||
69 | /* These two routines should probably check a few things... */ | ||
70 | static void set_uncached(pte_t * pte, unsigned long arg) | ||
71 | { | ||
72 | pte_val(*pte) |= _PAGE_NO_CACHE; | ||
73 | } | ||
74 | |||
75 | static void set_cached(pte_t * pte, unsigned long arg) | ||
76 | { | ||
77 | pte_val(*pte) &= ~_PAGE_NO_CACHE; | ||
78 | } | ||
79 | |||
80 | static inline void iterate_pte(pmd_t * pmd, unsigned long address, | ||
81 | unsigned long size, pte_iterator_t op, | ||
82 | unsigned long arg) | ||
83 | { | ||
84 | pte_t *pte; | ||
85 | unsigned long end; | ||
86 | |||
87 | if (pmd_none(*pmd)) | ||
88 | return; | ||
89 | if (pmd_bad(*pmd)) { | ||
90 | pmd_ERROR(*pmd); | ||
91 | pmd_clear(pmd); | ||
92 | return; | ||
93 | } | ||
94 | pte = pte_offset(pmd, address); | ||
95 | address &= ~PMD_MASK; | ||
96 | end = address + size; | ||
97 | if (end > PMD_SIZE) | ||
98 | end = PMD_SIZE; | ||
99 | do { | ||
100 | op(pte, arg); | ||
101 | address += PAGE_SIZE; | ||
102 | pte++; | ||
103 | } while (address < end); | ||
104 | } | ||
105 | |||
106 | static inline void iterate_pmd(pgd_t * dir, unsigned long address, | ||
107 | unsigned long size, pte_iterator_t op, | ||
108 | unsigned long arg) | ||
109 | { | ||
110 | pmd_t *pmd; | ||
111 | unsigned long end; | ||
112 | |||
113 | if (pgd_none(*dir)) | ||
114 | return; | ||
115 | if (pgd_bad(*dir)) { | ||
116 | pgd_ERROR(*dir); | ||
117 | pgd_clear(dir); | ||
118 | return; | ||
119 | } | ||
120 | pmd = pmd_offset(dir, address); | ||
121 | address &= ~PGDIR_MASK; | ||
122 | end = address + size; | ||
123 | if (end > PGDIR_SIZE) | ||
124 | end = PGDIR_SIZE; | ||
125 | do { | ||
126 | iterate_pte(pmd, address, end - address, op, arg); | ||
127 | address = (address + PMD_SIZE) & PMD_MASK; | ||
128 | pmd++; | ||
129 | } while (address < end); | ||
130 | } | ||
131 | |||
132 | static void iterate_pages(unsigned long address, unsigned long size, | ||
133 | pte_iterator_t op, unsigned long arg) | ||
134 | { | ||
135 | pgd_t *dir; | ||
136 | unsigned long end = address + size; | ||
137 | |||
138 | dir = pgd_offset_k(address); | ||
139 | flush_cache_all(); | ||
140 | do { | ||
141 | iterate_pmd(dir, address, end - address, op, arg); | ||
142 | address = (address + PGDIR_SIZE) & PGDIR_MASK; | ||
143 | dir++; | ||
144 | } while (address && (address < end)); | ||
145 | flush_tlb_all(); | ||
146 | } | ||
147 | |||
148 | void | ||
149 | kernel_set_cachemode(unsigned long vaddr, unsigned long size, int what) | ||
150 | { | ||
151 | switch (what) { | ||
152 | case IOMAP_FULL_CACHING: | ||
153 | iterate_pages(vaddr, size, set_cached, 0); | ||
154 | flush_tlb_range(NULL, vaddr, size); | ||
155 | break; | ||
156 | case IOMAP_NOCACHE_SER: | ||
157 | iterate_pages(vaddr, size, set_uncached, 0); | ||
158 | flush_tlb_range(NULL, vaddr, size); | ||
159 | break; | ||
160 | default: | ||
161 | printk(KERN_CRIT | ||
162 | "kernel_set_cachemode mode %d not understood\n", | ||
163 | what); | ||
164 | break; | ||
165 | } | ||
166 | } | ||
diff --git a/arch/parisc/oprofile/init.c b/arch/parisc/oprofile/init.c index a5b898c4d0b0..113f5139f551 100644 --- a/arch/parisc/oprofile/init.c +++ b/arch/parisc/oprofile/init.c | |||
@@ -18,6 +18,6 @@ int __init oprofile_arch_init(struct oprofile_operations * ops) | |||
18 | } | 18 | } |
19 | 19 | ||
20 | 20 | ||
21 | void oprofile_arch_exit() | 21 | void oprofile_arch_exit(void) |
22 | { | 22 | { |
23 | } | 23 | } |
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig index eaaac3788110..d9425f59be91 100644 --- a/arch/s390/Kconfig +++ b/arch/s390/Kconfig | |||
@@ -8,8 +8,8 @@ config MMU | |||
8 | default y | 8 | default y |
9 | 9 | ||
10 | config ZONE_DMA | 10 | config ZONE_DMA |
11 | bool | 11 | def_bool y |
12 | default y | 12 | depends on 64BIT |
13 | 13 | ||
14 | config LOCKDEP_SUPPORT | 14 | config LOCKDEP_SUPPORT |
15 | bool | 15 | bool |
diff --git a/arch/s390/Makefile b/arch/s390/Makefile index 6598e5268573..b1e558496469 100644 --- a/arch/s390/Makefile +++ b/arch/s390/Makefile | |||
@@ -82,18 +82,18 @@ AFLAGS += $(aflags-y) | |||
82 | OBJCOPYFLAGS := -O binary | 82 | OBJCOPYFLAGS := -O binary |
83 | LDFLAGS_vmlinux := -e start | 83 | LDFLAGS_vmlinux := -e start |
84 | 84 | ||
85 | head-y := arch/$(ARCH)/kernel/head.o arch/$(ARCH)/kernel/init_task.o | 85 | head-y := arch/s390/kernel/head.o arch/s390/kernel/init_task.o |
86 | 86 | ||
87 | core-y += arch/$(ARCH)/mm/ arch/$(ARCH)/kernel/ arch/$(ARCH)/crypto/ \ | 87 | core-y += arch/s390/mm/ arch/s390/kernel/ arch/s390/crypto/ \ |
88 | arch/$(ARCH)/appldata/ arch/$(ARCH)/hypfs/ | 88 | arch/s390/appldata/ arch/s390/hypfs/ |
89 | libs-y += arch/$(ARCH)/lib/ | 89 | libs-y += arch/s390/lib/ |
90 | drivers-y += drivers/s390/ | 90 | drivers-y += drivers/s390/ |
91 | drivers-$(CONFIG_MATHEMU) += arch/$(ARCH)/math-emu/ | 91 | drivers-$(CONFIG_MATHEMU) += arch/s390/math-emu/ |
92 | 92 | ||
93 | # must be linked after kernel | 93 | # must be linked after kernel |
94 | drivers-$(CONFIG_OPROFILE) += arch/s390/oprofile/ | 94 | drivers-$(CONFIG_OPROFILE) += arch/s390/oprofile/ |
95 | 95 | ||
96 | boot := arch/$(ARCH)/boot | 96 | boot := arch/s390/boot |
97 | 97 | ||
98 | all: image | 98 | all: image |
99 | 99 | ||
diff --git a/arch/s390/defconfig b/arch/s390/defconfig index 1406400bf3ea..741d2bbb2b37 100644 --- a/arch/s390/defconfig +++ b/arch/s390/defconfig | |||
@@ -1,9 +1,10 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20-rc1 | 3 | # Linux kernel version: 2.6.21-rc1 |
4 | # Fri Dec 15 16:52:28 2006 | 4 | # Wed Feb 21 10:44:30 2007 |
5 | # | 5 | # |
6 | CONFIG_MMU=y | 6 | CONFIG_MMU=y |
7 | CONFIG_ZONE_DMA=y | ||
7 | CONFIG_LOCKDEP_SUPPORT=y | 8 | CONFIG_LOCKDEP_SUPPORT=y |
8 | CONFIG_STACKTRACE_SUPPORT=y | 9 | CONFIG_STACKTRACE_SUPPORT=y |
9 | CONFIG_RWSEM_XCHGADD_ALGORITHM=y | 10 | CONFIG_RWSEM_XCHGADD_ALGORITHM=y |
@@ -11,6 +12,7 @@ CONFIG_RWSEM_XCHGADD_ALGORITHM=y | |||
11 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | 12 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set |
12 | CONFIG_GENERIC_HWEIGHT=y | 13 | CONFIG_GENERIC_HWEIGHT=y |
13 | CONFIG_GENERIC_TIME=y | 14 | CONFIG_GENERIC_TIME=y |
15 | CONFIG_NO_IOMEM=y | ||
14 | CONFIG_S390=y | 16 | CONFIG_S390=y |
15 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | 17 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" |
16 | 18 | ||
@@ -29,6 +31,7 @@ CONFIG_LOCALVERSION_AUTO=y | |||
29 | CONFIG_SWAP=y | 31 | CONFIG_SWAP=y |
30 | CONFIG_SYSVIPC=y | 32 | CONFIG_SYSVIPC=y |
31 | # CONFIG_IPC_NS is not set | 33 | # CONFIG_IPC_NS is not set |
34 | CONFIG_SYSVIPC_SYSCTL=y | ||
32 | CONFIG_POSIX_MQUEUE=y | 35 | CONFIG_POSIX_MQUEUE=y |
33 | # CONFIG_BSD_PROCESS_ACCT is not set | 36 | # CONFIG_BSD_PROCESS_ACCT is not set |
34 | # CONFIG_TASKSTATS is not set | 37 | # CONFIG_TASKSTATS is not set |
@@ -133,6 +136,7 @@ CONFIG_FLAT_NODE_MEM_MAP=y | |||
133 | # CONFIG_SPARSEMEM_STATIC is not set | 136 | # CONFIG_SPARSEMEM_STATIC is not set |
134 | CONFIG_SPLIT_PTLOCK_CPUS=4 | 137 | CONFIG_SPLIT_PTLOCK_CPUS=4 |
135 | CONFIG_RESOURCES_64BIT=y | 138 | CONFIG_RESOURCES_64BIT=y |
139 | CONFIG_ZONE_DMA_FLAG=1 | ||
136 | CONFIG_HOLES_IN_ZONE=y | 140 | CONFIG_HOLES_IN_ZONE=y |
137 | 141 | ||
138 | # | 142 | # |
@@ -178,7 +182,9 @@ CONFIG_UNIX=y | |||
178 | CONFIG_XFRM=y | 182 | CONFIG_XFRM=y |
179 | # CONFIG_XFRM_USER is not set | 183 | # CONFIG_XFRM_USER is not set |
180 | # CONFIG_XFRM_SUB_POLICY is not set | 184 | # CONFIG_XFRM_SUB_POLICY is not set |
185 | # CONFIG_XFRM_MIGRATE is not set | ||
181 | CONFIG_NET_KEY=y | 186 | CONFIG_NET_KEY=y |
187 | # CONFIG_NET_KEY_MIGRATE is not set | ||
182 | CONFIG_IUCV=m | 188 | CONFIG_IUCV=m |
183 | CONFIG_AFIUCV=m | 189 | CONFIG_AFIUCV=m |
184 | CONFIG_INET=y | 190 | CONFIG_INET=y |
@@ -195,7 +201,7 @@ CONFIG_IP_FIB_HASH=y | |||
195 | # CONFIG_INET_ESP is not set | 201 | # CONFIG_INET_ESP is not set |
196 | # CONFIG_INET_IPCOMP is not set | 202 | # CONFIG_INET_IPCOMP is not set |
197 | # CONFIG_INET_XFRM_TUNNEL is not set | 203 | # CONFIG_INET_XFRM_TUNNEL is not set |
198 | # CONFIG_INET_TUNNEL is not set | 204 | CONFIG_INET_TUNNEL=y |
199 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | 205 | CONFIG_INET_XFRM_MODE_TRANSPORT=y |
200 | CONFIG_INET_XFRM_MODE_TUNNEL=y | 206 | CONFIG_INET_XFRM_MODE_TUNNEL=y |
201 | CONFIG_INET_XFRM_MODE_BEET=y | 207 | CONFIG_INET_XFRM_MODE_BEET=y |
@@ -313,6 +319,7 @@ CONFIG_STANDALONE=y | |||
313 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 319 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
314 | # CONFIG_FW_LOADER is not set | 320 | # CONFIG_FW_LOADER is not set |
315 | # CONFIG_DEBUG_DRIVER is not set | 321 | # CONFIG_DEBUG_DRIVER is not set |
322 | # CONFIG_DEBUG_DEVRES is not set | ||
316 | CONFIG_SYS_HYPERVISOR=y | 323 | CONFIG_SYS_HYPERVISOR=y |
317 | 324 | ||
318 | # | 325 | # |
@@ -686,13 +693,13 @@ CONFIG_HEADERS_CHECK=y | |||
686 | CONFIG_DEBUG_KERNEL=y | 693 | CONFIG_DEBUG_KERNEL=y |
687 | CONFIG_LOG_BUF_SHIFT=17 | 694 | CONFIG_LOG_BUF_SHIFT=17 |
688 | # CONFIG_SCHEDSTATS is not set | 695 | # CONFIG_SCHEDSTATS is not set |
696 | # CONFIG_TIMER_STATS is not set | ||
689 | # CONFIG_DEBUG_SLAB is not set | 697 | # CONFIG_DEBUG_SLAB is not set |
690 | CONFIG_DEBUG_PREEMPT=y | 698 | CONFIG_DEBUG_PREEMPT=y |
691 | # CONFIG_DEBUG_RT_MUTEXES is not set | 699 | # CONFIG_DEBUG_RT_MUTEXES is not set |
692 | # CONFIG_RT_MUTEX_TESTER is not set | 700 | # CONFIG_RT_MUTEX_TESTER is not set |
693 | CONFIG_DEBUG_SPINLOCK=y | 701 | CONFIG_DEBUG_SPINLOCK=y |
694 | CONFIG_DEBUG_MUTEXES=y | 702 | CONFIG_DEBUG_MUTEXES=y |
695 | # CONFIG_DEBUG_RWSEMS is not set | ||
696 | # CONFIG_DEBUG_LOCK_ALLOC is not set | 703 | # CONFIG_DEBUG_LOCK_ALLOC is not set |
697 | # CONFIG_PROVE_LOCKING is not set | 704 | # CONFIG_PROVE_LOCKING is not set |
698 | CONFIG_DEBUG_SPINLOCK_SLEEP=y | 705 | CONFIG_DEBUG_SPINLOCK_SLEEP=y |
@@ -702,10 +709,10 @@ CONFIG_DEBUG_SPINLOCK_SLEEP=y | |||
702 | # CONFIG_DEBUG_VM is not set | 709 | # CONFIG_DEBUG_VM is not set |
703 | # CONFIG_DEBUG_LIST is not set | 710 | # CONFIG_DEBUG_LIST is not set |
704 | # CONFIG_FRAME_POINTER is not set | 711 | # CONFIG_FRAME_POINTER is not set |
705 | # CONFIG_UNWIND_INFO is not set | ||
706 | CONFIG_FORCED_INLINING=y | 712 | CONFIG_FORCED_INLINING=y |
707 | # CONFIG_RCU_TORTURE_TEST is not set | 713 | # CONFIG_RCU_TORTURE_TEST is not set |
708 | # CONFIG_LKDTM is not set | 714 | # CONFIG_LKDTM is not set |
715 | # CONFIG_FAULT_INJECTION is not set | ||
709 | 716 | ||
710 | # | 717 | # |
711 | # Security options | 718 | # Security options |
@@ -733,8 +740,10 @@ CONFIG_CRYPTO_MANAGER=y | |||
733 | # CONFIG_CRYPTO_GF128MUL is not set | 740 | # CONFIG_CRYPTO_GF128MUL is not set |
734 | CONFIG_CRYPTO_ECB=m | 741 | CONFIG_CRYPTO_ECB=m |
735 | CONFIG_CRYPTO_CBC=y | 742 | CONFIG_CRYPTO_CBC=y |
743 | CONFIG_CRYPTO_PCBC=m | ||
736 | # CONFIG_CRYPTO_LRW is not set | 744 | # CONFIG_CRYPTO_LRW is not set |
737 | # CONFIG_CRYPTO_DES is not set | 745 | # CONFIG_CRYPTO_DES is not set |
746 | CONFIG_CRYPTO_FCRYPT=m | ||
738 | # CONFIG_CRYPTO_BLOWFISH is not set | 747 | # CONFIG_CRYPTO_BLOWFISH is not set |
739 | # CONFIG_CRYPTO_TWOFISH is not set | 748 | # CONFIG_CRYPTO_TWOFISH is not set |
740 | # CONFIG_CRYPTO_SERPENT is not set | 749 | # CONFIG_CRYPTO_SERPENT is not set |
@@ -748,6 +757,7 @@ CONFIG_CRYPTO_CBC=y | |||
748 | # CONFIG_CRYPTO_DEFLATE is not set | 757 | # CONFIG_CRYPTO_DEFLATE is not set |
749 | # CONFIG_CRYPTO_MICHAEL_MIC is not set | 758 | # CONFIG_CRYPTO_MICHAEL_MIC is not set |
750 | # CONFIG_CRYPTO_CRC32C is not set | 759 | # CONFIG_CRYPTO_CRC32C is not set |
760 | CONFIG_CRYPTO_CAMELLIA=m | ||
751 | # CONFIG_CRYPTO_TEST is not set | 761 | # CONFIG_CRYPTO_TEST is not set |
752 | 762 | ||
753 | # | 763 | # |
@@ -768,4 +778,3 @@ CONFIG_BITREVERSE=m | |||
768 | CONFIG_CRC32=m | 778 | CONFIG_CRC32=m |
769 | # CONFIG_LIBCRC32C is not set | 779 | # CONFIG_LIBCRC32C is not set |
770 | CONFIG_PLIST=y | 780 | CONFIG_PLIST=y |
771 | CONFIG_IOMAP_COPY=y | ||
diff --git a/arch/s390/kernel/early.c b/arch/s390/kernel/early.c index e518dd53eff5..afca1c6f4d21 100644 --- a/arch/s390/kernel/early.c +++ b/arch/s390/kernel/early.c | |||
@@ -14,6 +14,7 @@ | |||
14 | #include <linux/module.h> | 14 | #include <linux/module.h> |
15 | #include <linux/pfn.h> | 15 | #include <linux/pfn.h> |
16 | #include <linux/uaccess.h> | 16 | #include <linux/uaccess.h> |
17 | #include <asm/ipl.h> | ||
17 | #include <asm/lowcore.h> | 18 | #include <asm/lowcore.h> |
18 | #include <asm/processor.h> | 19 | #include <asm/processor.h> |
19 | #include <asm/sections.h> | 20 | #include <asm/sections.h> |
@@ -109,7 +110,7 @@ static inline void create_kernel_nss(void) { } | |||
109 | */ | 110 | */ |
110 | static noinline __init void clear_bss_section(void) | 111 | static noinline __init void clear_bss_section(void) |
111 | { | 112 | { |
112 | memset(__bss_start, 0, _end - __bss_start); | 113 | memset(__bss_start, 0, __bss_stop - __bss_start); |
113 | } | 114 | } |
114 | 115 | ||
115 | /* | 116 | /* |
@@ -129,7 +130,7 @@ static noinline __init void detect_machine_type(void) | |||
129 | { | 130 | { |
130 | struct cpuinfo_S390 *cpuinfo = &S390_lowcore.cpu_data; | 131 | struct cpuinfo_S390 *cpuinfo = &S390_lowcore.cpu_data; |
131 | 132 | ||
132 | asm volatile("stidp %0" : "=m" (S390_lowcore.cpu_data.cpu_id)); | 133 | get_cpu_id(&S390_lowcore.cpu_data.cpu_id); |
133 | 134 | ||
134 | /* Running under z/VM ? */ | 135 | /* Running under z/VM ? */ |
135 | if (cpuinfo->cpu_id.version == 0xff) | 136 | if (cpuinfo->cpu_id.version == 0xff) |
diff --git a/arch/s390/kernel/head31.S b/arch/s390/kernel/head31.S index 453fd3b4edea..da7c8bb80982 100644 --- a/arch/s390/kernel/head31.S +++ b/arch/s390/kernel/head31.S | |||
@@ -148,20 +148,9 @@ startup_continue: | |||
148 | .Lstartup_init: | 148 | .Lstartup_init: |
149 | .long startup_init | 149 | .long startup_init |
150 | 150 | ||
151 | .globl ipl_schib | ||
152 | ipl_schib: | ||
153 | .rept 13 | ||
154 | .long 0 | ||
155 | .endr | ||
156 | |||
157 | .globl ipl_flags | ||
158 | ipl_flags: | ||
159 | .long 0 | ||
160 | .globl ipl_devno | ||
161 | ipl_devno: | ||
162 | .word 0 | ||
163 | |||
164 | .org 0x12000 | 151 | .org 0x12000 |
152 | .globl _ehead | ||
153 | _ehead: | ||
165 | #ifdef CONFIG_SHARED_KERNEL | 154 | #ifdef CONFIG_SHARED_KERNEL |
166 | .org 0x100000 | 155 | .org 0x100000 |
167 | #endif | 156 | #endif |
diff --git a/arch/s390/kernel/head64.S b/arch/s390/kernel/head64.S index b8fec4e5c5d4..af09e18cc5d0 100644 --- a/arch/s390/kernel/head64.S +++ b/arch/s390/kernel/head64.S | |||
@@ -154,21 +154,9 @@ startup_continue: | |||
154 | .Lparmaddr: | 154 | .Lparmaddr: |
155 | .quad PARMAREA | 155 | .quad PARMAREA |
156 | 156 | ||
157 | .globl ipl_schib | ||
158 | ipl_schib: | ||
159 | .rept 13 | ||
160 | .long 0 | ||
161 | .endr | ||
162 | |||
163 | .globl ipl_flags | ||
164 | ipl_flags: | ||
165 | .long 0 | ||
166 | .globl ipl_devno | ||
167 | ipl_devno: | ||
168 | .word 0 | ||
169 | |||
170 | .org 0x12000 | 157 | .org 0x12000 |
171 | 158 | .globl _ehead | |
159 | _ehead: | ||
172 | #ifdef CONFIG_SHARED_KERNEL | 160 | #ifdef CONFIG_SHARED_KERNEL |
173 | .org 0x100000 | 161 | .org 0x100000 |
174 | #endif | 162 | #endif |
diff --git a/arch/s390/kernel/ipl.c b/arch/s390/kernel/ipl.c index 052259530651..5a863a3bf10c 100644 --- a/arch/s390/kernel/ipl.c +++ b/arch/s390/kernel/ipl.c | |||
@@ -14,6 +14,7 @@ | |||
14 | #include <linux/delay.h> | 14 | #include <linux/delay.h> |
15 | #include <linux/reboot.h> | 15 | #include <linux/reboot.h> |
16 | #include <linux/ctype.h> | 16 | #include <linux/ctype.h> |
17 | #include <asm/ipl.h> | ||
17 | #include <asm/smp.h> | 18 | #include <asm/smp.h> |
18 | #include <asm/setup.h> | 19 | #include <asm/setup.h> |
19 | #include <asm/cpcmd.h> | 20 | #include <asm/cpcmd.h> |
@@ -42,6 +43,13 @@ enum ipl_type { | |||
42 | #define IPL_FCP_STR "fcp" | 43 | #define IPL_FCP_STR "fcp" |
43 | #define IPL_NSS_STR "nss" | 44 | #define IPL_NSS_STR "nss" |
44 | 45 | ||
46 | /* | ||
47 | * Must be in data section since the bss section | ||
48 | * is not cleared when these are accessed. | ||
49 | */ | ||
50 | u16 ipl_devno __attribute__((__section__(".data"))) = 0; | ||
51 | u32 ipl_flags __attribute__((__section__(".data"))) = 0; | ||
52 | |||
45 | static char *ipl_type_str(enum ipl_type type) | 53 | static char *ipl_type_str(enum ipl_type type) |
46 | { | 54 | { |
47 | switch (type) { | 55 | switch (type) { |
@@ -90,31 +98,10 @@ static char *shutdown_action_str(enum shutdown_action action) | |||
90 | case SHUTDOWN_STOP: | 98 | case SHUTDOWN_STOP: |
91 | return SHUTDOWN_STOP_STR; | 99 | return SHUTDOWN_STOP_STR; |
92 | default: | 100 | default: |
93 | BUG(); | 101 | return NULL; |
94 | } | 102 | } |
95 | } | 103 | } |
96 | 104 | ||
97 | enum diag308_subcode { | ||
98 | DIAG308_IPL = 3, | ||
99 | DIAG308_DUMP = 4, | ||
100 | DIAG308_SET = 5, | ||
101 | DIAG308_STORE = 6, | ||
102 | }; | ||
103 | |||
104 | enum diag308_ipl_type { | ||
105 | DIAG308_IPL_TYPE_FCP = 0, | ||
106 | DIAG308_IPL_TYPE_CCW = 2, | ||
107 | }; | ||
108 | |||
109 | enum diag308_opt { | ||
110 | DIAG308_IPL_OPT_IPL = 0x10, | ||
111 | DIAG308_IPL_OPT_DUMP = 0x20, | ||
112 | }; | ||
113 | |||
114 | enum diag308_rc { | ||
115 | DIAG308_RC_OK = 1, | ||
116 | }; | ||
117 | |||
118 | static int diag308_set_works = 0; | 105 | static int diag308_set_works = 0; |
119 | 106 | ||
120 | static int reipl_capabilities = IPL_TYPE_UNKNOWN; | 107 | static int reipl_capabilities = IPL_TYPE_UNKNOWN; |
@@ -134,7 +121,7 @@ static struct ipl_parameter_block *dump_block_ccw; | |||
134 | 121 | ||
135 | static enum shutdown_action on_panic_action = SHUTDOWN_STOP; | 122 | static enum shutdown_action on_panic_action = SHUTDOWN_STOP; |
136 | 123 | ||
137 | static int diag308(unsigned long subcode, void *addr) | 124 | int diag308(unsigned long subcode, void *addr) |
138 | { | 125 | { |
139 | register unsigned long _addr asm("0") = (unsigned long) addr; | 126 | register unsigned long _addr asm("0") = (unsigned long) addr; |
140 | register unsigned long _rc asm("1") = 0; | 127 | register unsigned long _rc asm("1") = 0; |
diff --git a/arch/s390/kernel/setup.c b/arch/s390/kernel/setup.c index 50c5210fbc64..863c8d08c026 100644 --- a/arch/s390/kernel/setup.c +++ b/arch/s390/kernel/setup.c | |||
@@ -41,6 +41,7 @@ | |||
41 | #include <linux/ctype.h> | 41 | #include <linux/ctype.h> |
42 | #include <linux/reboot.h> | 42 | #include <linux/reboot.h> |
43 | 43 | ||
44 | #include <asm/ipl.h> | ||
44 | #include <asm/uaccess.h> | 45 | #include <asm/uaccess.h> |
45 | #include <asm/system.h> | 46 | #include <asm/system.h> |
46 | #include <asm/smp.h> | 47 | #include <asm/smp.h> |
@@ -106,7 +107,7 @@ void __devinit cpu_init (void) | |||
106 | /* | 107 | /* |
107 | * Store processor id in lowcore (used e.g. in timer_interrupt) | 108 | * Store processor id in lowcore (used e.g. in timer_interrupt) |
108 | */ | 109 | */ |
109 | asm volatile("stidp %0": "=m" (S390_lowcore.cpu_data.cpu_id)); | 110 | get_cpu_id(&S390_lowcore.cpu_data.cpu_id); |
110 | S390_lowcore.cpu_data.cpu_addr = addr; | 111 | S390_lowcore.cpu_data.cpu_addr = addr; |
111 | 112 | ||
112 | /* | 113 | /* |
@@ -689,9 +690,14 @@ setup_memory(void) | |||
689 | psw_set_key(PAGE_DEFAULT_KEY); | 690 | psw_set_key(PAGE_DEFAULT_KEY); |
690 | 691 | ||
691 | free_bootmem_with_active_regions(0, max_pfn); | 692 | free_bootmem_with_active_regions(0, max_pfn); |
692 | reserve_bootmem(0, PFN_PHYS(start_pfn)); | ||
693 | 693 | ||
694 | /* | 694 | /* |
695 | * Reserve memory used for lowcore/command line/kernel image. | ||
696 | */ | ||
697 | reserve_bootmem(0, (unsigned long)_ehead); | ||
698 | reserve_bootmem((unsigned long)_stext, | ||
699 | PFN_PHYS(start_pfn) - (unsigned long)_stext); | ||
700 | /* | ||
695 | * Reserve the bootmem bitmap itself as well. We do this in two | 701 | * Reserve the bootmem bitmap itself as well. We do this in two |
696 | * steps (first step was init_bootmem()) because this catches | 702 | * steps (first step was init_bootmem()) because this catches |
697 | * the (very unlikely) case of us accidentally initializing the | 703 | * the (very unlikely) case of us accidentally initializing the |
diff --git a/arch/s390/kernel/smp.c b/arch/s390/kernel/smp.c index 83a4ea6e3d60..ecaa432a99f8 100644 --- a/arch/s390/kernel/smp.c +++ b/arch/s390/kernel/smp.c | |||
@@ -31,6 +31,7 @@ | |||
31 | #include <linux/interrupt.h> | 31 | #include <linux/interrupt.h> |
32 | #include <linux/cpu.h> | 32 | #include <linux/cpu.h> |
33 | #include <linux/timex.h> | 33 | #include <linux/timex.h> |
34 | #include <asm/ipl.h> | ||
34 | #include <asm/setup.h> | 35 | #include <asm/setup.h> |
35 | #include <asm/sigp.h> | 36 | #include <asm/sigp.h> |
36 | #include <asm/pgalloc.h> | 37 | #include <asm/pgalloc.h> |
@@ -54,19 +55,18 @@ cpumask_t cpu_possible_map = CPU_MASK_NONE; | |||
54 | static struct task_struct *current_set[NR_CPUS]; | 55 | static struct task_struct *current_set[NR_CPUS]; |
55 | 56 | ||
56 | static void smp_ext_bitcall(int, ec_bit_sig); | 57 | static void smp_ext_bitcall(int, ec_bit_sig); |
57 | static void smp_ext_bitcall_others(ec_bit_sig); | ||
58 | 58 | ||
59 | /* | 59 | /* |
60 | * Structure and data for smp_call_function(). This is designed to minimise | 60 | * Structure and data for __smp_call_function_map(). This is designed to |
61 | * static memory requirements. It also looks cleaner. | 61 | * minimise static memory requirements. It also looks cleaner. |
62 | */ | 62 | */ |
63 | static DEFINE_SPINLOCK(call_lock); | 63 | static DEFINE_SPINLOCK(call_lock); |
64 | 64 | ||
65 | struct call_data_struct { | 65 | struct call_data_struct { |
66 | void (*func) (void *info); | 66 | void (*func) (void *info); |
67 | void *info; | 67 | void *info; |
68 | atomic_t started; | 68 | cpumask_t started; |
69 | atomic_t finished; | 69 | cpumask_t finished; |
70 | int wait; | 70 | int wait; |
71 | }; | 71 | }; |
72 | 72 | ||
@@ -81,118 +81,113 @@ static void do_call_function(void) | |||
81 | void *info = call_data->info; | 81 | void *info = call_data->info; |
82 | int wait = call_data->wait; | 82 | int wait = call_data->wait; |
83 | 83 | ||
84 | atomic_inc(&call_data->started); | 84 | cpu_set(smp_processor_id(), call_data->started); |
85 | (*func)(info); | 85 | (*func)(info); |
86 | if (wait) | 86 | if (wait) |
87 | atomic_inc(&call_data->finished); | 87 | cpu_set(smp_processor_id(), call_data->finished);; |
88 | } | 88 | } |
89 | 89 | ||
90 | /* | 90 | static void __smp_call_function_map(void (*func) (void *info), void *info, |
91 | * this function sends a 'generic call function' IPI to all other CPUs | 91 | int nonatomic, int wait, cpumask_t map) |
92 | * in the system. | ||
93 | */ | ||
94 | |||
95 | int smp_call_function (void (*func) (void *info), void *info, int nonatomic, | ||
96 | int wait) | ||
97 | /* | ||
98 | * [SUMMARY] Run a function on all other CPUs. | ||
99 | * <func> The function to run. This must be fast and non-blocking. | ||
100 | * <info> An arbitrary pointer to pass to the function. | ||
101 | * <nonatomic> currently unused. | ||
102 | * <wait> If true, wait (atomically) until function has completed on other CPUs. | ||
103 | * [RETURNS] 0 on success, else a negative status code. Does not return until | ||
104 | * remote CPUs are nearly ready to execute <<func>> or are or have executed. | ||
105 | * | ||
106 | * You must not call this function with disabled interrupts or from a | ||
107 | * hardware interrupt handler. | ||
108 | */ | ||
109 | { | 92 | { |
110 | struct call_data_struct data; | 93 | struct call_data_struct data; |
111 | int cpus = num_online_cpus()-1; | 94 | int cpu, local = 0; |
112 | 95 | ||
113 | if (cpus <= 0) | 96 | /* |
114 | return 0; | 97 | * Can deadlock when interrupts are disabled or if in wrong context, |
98 | * caller must disable preemption | ||
99 | */ | ||
100 | WARN_ON(irqs_disabled() || in_irq() || preemptible()); | ||
115 | 101 | ||
116 | /* Can deadlock when interrupts are disabled or if in wrong context */ | 102 | /* |
117 | WARN_ON(irqs_disabled() || in_irq()); | 103 | * Check for local function call. We have to have the same call order |
104 | * as in on_each_cpu() because of machine_restart_smp(). | ||
105 | */ | ||
106 | if (cpu_isset(smp_processor_id(), map)) { | ||
107 | local = 1; | ||
108 | cpu_clear(smp_processor_id(), map); | ||
109 | } | ||
110 | |||
111 | cpus_and(map, map, cpu_online_map); | ||
112 | if (cpus_empty(map)) | ||
113 | goto out; | ||
118 | 114 | ||
119 | data.func = func; | 115 | data.func = func; |
120 | data.info = info; | 116 | data.info = info; |
121 | atomic_set(&data.started, 0); | 117 | data.started = CPU_MASK_NONE; |
122 | data.wait = wait; | 118 | data.wait = wait; |
123 | if (wait) | 119 | if (wait) |
124 | atomic_set(&data.finished, 0); | 120 | data.finished = CPU_MASK_NONE; |
125 | 121 | ||
126 | spin_lock_bh(&call_lock); | 122 | spin_lock_bh(&call_lock); |
127 | call_data = &data; | 123 | call_data = &data; |
128 | /* Send a message to all other CPUs and wait for them to respond */ | 124 | |
129 | smp_ext_bitcall_others(ec_call_function); | 125 | for_each_cpu_mask(cpu, map) |
126 | smp_ext_bitcall(cpu, ec_call_function); | ||
130 | 127 | ||
131 | /* Wait for response */ | 128 | /* Wait for response */ |
132 | while (atomic_read(&data.started) != cpus) | 129 | while (!cpus_equal(map, data.started)) |
133 | cpu_relax(); | 130 | cpu_relax(); |
134 | 131 | ||
135 | if (wait) | 132 | if (wait) |
136 | while (atomic_read(&data.finished) != cpus) | 133 | while (!cpus_equal(map, data.finished)) |
137 | cpu_relax(); | 134 | cpu_relax(); |
135 | |||
138 | spin_unlock_bh(&call_lock); | 136 | spin_unlock_bh(&call_lock); |
139 | 137 | ||
140 | return 0; | 138 | out: |
139 | local_irq_disable(); | ||
140 | if (local) | ||
141 | func(info); | ||
142 | local_irq_enable(); | ||
141 | } | 143 | } |
142 | 144 | ||
143 | /* | 145 | /* |
144 | * Call a function on one CPU | 146 | * smp_call_function: |
145 | * cpu : the CPU the function should be executed on | 147 | * @func: the function to run; this must be fast and non-blocking |
148 | * @info: an arbitrary pointer to pass to the function | ||
149 | * @nonatomic: unused | ||
150 | * @wait: if true, wait (atomically) until function has completed on other CPUs | ||
146 | * | 151 | * |
147 | * You must not call this function with disabled interrupts or from a | 152 | * Run a function on all other CPUs. |
148 | * hardware interrupt handler. You may call it from a bottom half. | ||
149 | * | 153 | * |
150 | * It is guaranteed that the called function runs on the specified CPU, | 154 | * You must not call this function with disabled interrupts or from a |
151 | * preemption is disabled. | 155 | * hardware interrupt handler. Must be called with preemption disabled. |
156 | * You may call it from a bottom half. | ||
152 | */ | 157 | */ |
153 | int smp_call_function_on(void (*func) (void *info), void *info, | 158 | int smp_call_function(void (*func) (void *info), void *info, int nonatomic, |
154 | int nonatomic, int wait, int cpu) | 159 | int wait) |
155 | { | 160 | { |
156 | struct call_data_struct data; | 161 | cpumask_t map; |
157 | int curr_cpu; | ||
158 | |||
159 | if (!cpu_online(cpu)) | ||
160 | return -EINVAL; | ||
161 | |||
162 | /* Can deadlock when interrupts are disabled or if in wrong context */ | ||
163 | WARN_ON(irqs_disabled() || in_irq()); | ||
164 | |||
165 | /* disable preemption for local function call */ | ||
166 | curr_cpu = get_cpu(); | ||
167 | |||
168 | if (curr_cpu == cpu) { | ||
169 | /* direct call to function */ | ||
170 | func(info); | ||
171 | put_cpu(); | ||
172 | return 0; | ||
173 | } | ||
174 | |||
175 | data.func = func; | ||
176 | data.info = info; | ||
177 | atomic_set(&data.started, 0); | ||
178 | data.wait = wait; | ||
179 | if (wait) | ||
180 | atomic_set(&data.finished, 0); | ||
181 | |||
182 | spin_lock_bh(&call_lock); | ||
183 | call_data = &data; | ||
184 | smp_ext_bitcall(cpu, ec_call_function); | ||
185 | 162 | ||
186 | /* Wait for response */ | 163 | map = cpu_online_map; |
187 | while (atomic_read(&data.started) != 1) | 164 | cpu_clear(smp_processor_id(), map); |
188 | cpu_relax(); | 165 | __smp_call_function_map(func, info, nonatomic, wait, map); |
166 | return 0; | ||
167 | } | ||
168 | EXPORT_SYMBOL(smp_call_function); | ||
189 | 169 | ||
190 | if (wait) | 170 | /* |
191 | while (atomic_read(&data.finished) != 1) | 171 | * smp_call_function_on: |
192 | cpu_relax(); | 172 | * @func: the function to run; this must be fast and non-blocking |
173 | * @info: an arbitrary pointer to pass to the function | ||
174 | * @nonatomic: unused | ||
175 | * @wait: if true, wait (atomically) until function has completed on other CPUs | ||
176 | * @cpu: the CPU where func should run | ||
177 | * | ||
178 | * Run a function on one processor. | ||
179 | * | ||
180 | * You must not call this function with disabled interrupts or from a | ||
181 | * hardware interrupt handler. Must be called with preemption disabled. | ||
182 | * You may call it from a bottom half. | ||
183 | */ | ||
184 | int smp_call_function_on(void (*func) (void *info), void *info, int nonatomic, | ||
185 | int wait, int cpu) | ||
186 | { | ||
187 | cpumask_t map = CPU_MASK_NONE; | ||
193 | 188 | ||
194 | spin_unlock_bh(&call_lock); | 189 | cpu_set(cpu, map); |
195 | put_cpu(); | 190 | __smp_call_function_map(func, info, nonatomic, wait, map); |
196 | return 0; | 191 | return 0; |
197 | } | 192 | } |
198 | EXPORT_SYMBOL(smp_call_function_on); | 193 | EXPORT_SYMBOL(smp_call_function_on); |
@@ -325,26 +320,6 @@ static void smp_ext_bitcall(int cpu, ec_bit_sig sig) | |||
325 | udelay(10); | 320 | udelay(10); |
326 | } | 321 | } |
327 | 322 | ||
328 | /* | ||
329 | * Send an external call sigp to every other cpu in the system and | ||
330 | * return without waiting for its completion. | ||
331 | */ | ||
332 | static void smp_ext_bitcall_others(ec_bit_sig sig) | ||
333 | { | ||
334 | int cpu; | ||
335 | |||
336 | for_each_online_cpu(cpu) { | ||
337 | if (cpu == smp_processor_id()) | ||
338 | continue; | ||
339 | /* | ||
340 | * Set signaling bit in lowcore of target cpu and kick it | ||
341 | */ | ||
342 | set_bit(sig, (unsigned long *) &lowcore_ptr[cpu]->ext_call_fast); | ||
343 | while (signal_processor(cpu, sigp_emergency_signal) == sigp_busy) | ||
344 | udelay(10); | ||
345 | } | ||
346 | } | ||
347 | |||
348 | #ifndef CONFIG_64BIT | 323 | #ifndef CONFIG_64BIT |
349 | /* | 324 | /* |
350 | * this function sends a 'purge tlb' signal to another CPU. | 325 | * this function sends a 'purge tlb' signal to another CPU. |
@@ -807,6 +782,5 @@ EXPORT_SYMBOL(cpu_possible_map); | |||
807 | EXPORT_SYMBOL(lowcore_ptr); | 782 | EXPORT_SYMBOL(lowcore_ptr); |
808 | EXPORT_SYMBOL(smp_ctl_set_bit); | 783 | EXPORT_SYMBOL(smp_ctl_set_bit); |
809 | EXPORT_SYMBOL(smp_ctl_clear_bit); | 784 | EXPORT_SYMBOL(smp_ctl_clear_bit); |
810 | EXPORT_SYMBOL(smp_call_function); | ||
811 | EXPORT_SYMBOL(smp_get_cpu); | 785 | EXPORT_SYMBOL(smp_get_cpu); |
812 | EXPORT_SYMBOL(smp_put_cpu); | 786 | EXPORT_SYMBOL(smp_put_cpu); |
diff --git a/arch/s390/kernel/time.c b/arch/s390/kernel/time.c index ee9fd7b85928..e1ad464b6f20 100644 --- a/arch/s390/kernel/time.c +++ b/arch/s390/kernel/time.c | |||
@@ -747,6 +747,7 @@ static void etr_adjust_time(unsigned long long clock, unsigned long long delay) | |||
747 | } | 747 | } |
748 | } | 748 | } |
749 | 749 | ||
750 | #ifdef CONFIG_SMP | ||
750 | static void etr_sync_cpu_start(void *dummy) | 751 | static void etr_sync_cpu_start(void *dummy) |
751 | { | 752 | { |
752 | int *in_sync = dummy; | 753 | int *in_sync = dummy; |
@@ -758,8 +759,14 @@ static void etr_sync_cpu_start(void *dummy) | |||
758 | * __udelay will stop the cpu on an enabled wait psw until the | 759 | * __udelay will stop the cpu on an enabled wait psw until the |
759 | * TOD is running again. | 760 | * TOD is running again. |
760 | */ | 761 | */ |
761 | while (*in_sync == 0) | 762 | while (*in_sync == 0) { |
762 | __udelay(1); | 763 | __udelay(1); |
764 | /* | ||
765 | * A different cpu changes *in_sync. Therefore use | ||
766 | * barrier() to force memory access. | ||
767 | */ | ||
768 | barrier(); | ||
769 | } | ||
763 | if (*in_sync != 1) | 770 | if (*in_sync != 1) |
764 | /* Didn't work. Clear per-cpu in sync bit again. */ | 771 | /* Didn't work. Clear per-cpu in sync bit again. */ |
765 | etr_disable_sync_clock(NULL); | 772 | etr_disable_sync_clock(NULL); |
@@ -773,6 +780,7 @@ static void etr_sync_cpu_start(void *dummy) | |||
773 | static void etr_sync_cpu_end(void *dummy) | 780 | static void etr_sync_cpu_end(void *dummy) |
774 | { | 781 | { |
775 | } | 782 | } |
783 | #endif /* CONFIG_SMP */ | ||
776 | 784 | ||
777 | /* | 785 | /* |
778 | * Sync the TOD clock using the port refered to by aibp. This port | 786 | * Sync the TOD clock using the port refered to by aibp. This port |
diff --git a/arch/s390/lib/delay.c b/arch/s390/lib/delay.c index 02854449b74b..70f2a862b670 100644 --- a/arch/s390/lib/delay.c +++ b/arch/s390/lib/delay.c | |||
@@ -15,6 +15,7 @@ | |||
15 | #include <linux/delay.h> | 15 | #include <linux/delay.h> |
16 | #include <linux/timex.h> | 16 | #include <linux/timex.h> |
17 | #include <linux/irqflags.h> | 17 | #include <linux/irqflags.h> |
18 | #include <linux/interrupt.h> | ||
18 | 19 | ||
19 | void __delay(unsigned long loops) | 20 | void __delay(unsigned long loops) |
20 | { | 21 | { |
@@ -35,7 +36,11 @@ void __udelay(unsigned long usecs) | |||
35 | { | 36 | { |
36 | u64 end, time, jiffy_timer = 0; | 37 | u64 end, time, jiffy_timer = 0; |
37 | unsigned long flags, cr0, mask, dummy; | 38 | unsigned long flags, cr0, mask, dummy; |
39 | int irq_context; | ||
38 | 40 | ||
41 | irq_context = in_interrupt(); | ||
42 | if (!irq_context) | ||
43 | local_bh_disable(); | ||
39 | local_irq_save(flags); | 44 | local_irq_save(flags); |
40 | if (raw_irqs_disabled_flags(flags)) { | 45 | if (raw_irqs_disabled_flags(flags)) { |
41 | jiffy_timer = S390_lowcore.jiffy_timer; | 46 | jiffy_timer = S390_lowcore.jiffy_timer; |
@@ -62,6 +67,8 @@ void __udelay(unsigned long usecs) | |||
62 | __ctl_load(cr0, 0, 0); | 67 | __ctl_load(cr0, 0, 0); |
63 | S390_lowcore.jiffy_timer = jiffy_timer; | 68 | S390_lowcore.jiffy_timer = jiffy_timer; |
64 | } | 69 | } |
70 | if (!irq_context) | ||
71 | _local_bh_enable(); | ||
65 | set_clock_comparator(S390_lowcore.jiffy_timer); | 72 | set_clock_comparator(S390_lowcore.jiffy_timer); |
66 | local_irq_restore(flags); | 73 | local_irq_restore(flags); |
67 | } | 74 | } |
diff --git a/arch/s390/mm/init.c b/arch/s390/mm/init.c index b3e7c45efb63..916b72a8cde8 100644 --- a/arch/s390/mm/init.c +++ b/arch/s390/mm/init.c | |||
@@ -141,7 +141,9 @@ void __init paging_init(void) | |||
141 | __raw_local_irq_ssm(ssm_mask); | 141 | __raw_local_irq_ssm(ssm_mask); |
142 | 142 | ||
143 | memset(max_zone_pfns, 0, sizeof(max_zone_pfns)); | 143 | memset(max_zone_pfns, 0, sizeof(max_zone_pfns)); |
144 | #ifdef CONFIG_ZONE_DMA | ||
144 | max_zone_pfns[ZONE_DMA] = PFN_DOWN(MAX_DMA_ADDRESS); | 145 | max_zone_pfns[ZONE_DMA] = PFN_DOWN(MAX_DMA_ADDRESS); |
146 | #endif | ||
145 | max_zone_pfns[ZONE_NORMAL] = max_low_pfn; | 147 | max_zone_pfns[ZONE_NORMAL] = max_low_pfn; |
146 | free_area_init_nodes(max_zone_pfns); | 148 | free_area_init_nodes(max_zone_pfns); |
147 | } | 149 | } |
diff --git a/arch/sparc64/defconfig b/arch/sparc64/defconfig index 0f44a6a6675f..59eef403c60a 100644 --- a/arch/sparc64/defconfig +++ b/arch/sparc64/defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.21-rc1 |
4 | # Sun Feb 11 23:47:40 2007 | 4 | # Mon Feb 26 10:45:21 2007 |
5 | # | 5 | # |
6 | CONFIG_SPARC=y | 6 | CONFIG_SPARC=y |
7 | CONFIG_SPARC64=y | 7 | CONFIG_SPARC64=y |
@@ -41,6 +41,7 @@ CONFIG_LOCALVERSION="" | |||
41 | CONFIG_SWAP=y | 41 | CONFIG_SWAP=y |
42 | CONFIG_SYSVIPC=y | 42 | CONFIG_SYSVIPC=y |
43 | # CONFIG_IPC_NS is not set | 43 | # CONFIG_IPC_NS is not set |
44 | CONFIG_SYSVIPC_SYSCTL=y | ||
44 | CONFIG_POSIX_MQUEUE=y | 45 | CONFIG_POSIX_MQUEUE=y |
45 | # CONFIG_BSD_PROCESS_ACCT is not set | 46 | # CONFIG_BSD_PROCESS_ACCT is not set |
46 | # CONFIG_TASKSTATS is not set | 47 | # CONFIG_TASKSTATS is not set |
@@ -322,6 +323,7 @@ CONFIG_CONNECTOR=m | |||
322 | # | 323 | # |
323 | # Plug and Play support | 324 | # Plug and Play support |
324 | # | 325 | # |
326 | # CONFIG_PNPACPI is not set | ||
325 | 327 | ||
326 | # | 328 | # |
327 | # Block devices | 329 | # Block devices |
@@ -787,6 +789,7 @@ CONFIG_I2C_ALGOBIT=y | |||
787 | # CONFIG_I2C_NFORCE2 is not set | 789 | # CONFIG_I2C_NFORCE2 is not set |
788 | # CONFIG_I2C_OCORES is not set | 790 | # CONFIG_I2C_OCORES is not set |
789 | # CONFIG_I2C_PARPORT_LIGHT is not set | 791 | # CONFIG_I2C_PARPORT_LIGHT is not set |
792 | # CONFIG_I2C_PASEMI is not set | ||
790 | # CONFIG_I2C_PROSAVAGE is not set | 793 | # CONFIG_I2C_PROSAVAGE is not set |
791 | # CONFIG_I2C_SAVAGE4 is not set | 794 | # CONFIG_I2C_SAVAGE4 is not set |
792 | # CONFIG_I2C_SIS5595 is not set | 795 | # CONFIG_I2C_SIS5595 is not set |
@@ -833,6 +836,7 @@ CONFIG_HWMON=y | |||
833 | # CONFIG_SENSORS_ADM1021 is not set | 836 | # CONFIG_SENSORS_ADM1021 is not set |
834 | # CONFIG_SENSORS_ADM1025 is not set | 837 | # CONFIG_SENSORS_ADM1025 is not set |
835 | # CONFIG_SENSORS_ADM1026 is not set | 838 | # CONFIG_SENSORS_ADM1026 is not set |
839 | # CONFIG_SENSORS_ADM1029 is not set | ||
836 | # CONFIG_SENSORS_ADM1031 is not set | 840 | # CONFIG_SENSORS_ADM1031 is not set |
837 | # CONFIG_SENSORS_ADM9240 is not set | 841 | # CONFIG_SENSORS_ADM9240 is not set |
838 | # CONFIG_SENSORS_ASB100 is not set | 842 | # CONFIG_SENSORS_ASB100 is not set |
@@ -874,6 +878,11 @@ CONFIG_HWMON=y | |||
874 | # CONFIG_HWMON_DEBUG_CHIP is not set | 878 | # CONFIG_HWMON_DEBUG_CHIP is not set |
875 | 879 | ||
876 | # | 880 | # |
881 | # Multifunction device drivers | ||
882 | # | ||
883 | # CONFIG_MFD_SM501 is not set | ||
884 | |||
885 | # | ||
877 | # Multimedia devices | 886 | # Multimedia devices |
878 | # | 887 | # |
879 | # CONFIG_VIDEO_DEV is not set | 888 | # CONFIG_VIDEO_DEV is not set |
@@ -887,16 +896,22 @@ CONFIG_HWMON=y | |||
887 | # | 896 | # |
888 | # Graphics support | 897 | # Graphics support |
889 | # | 898 | # |
890 | # CONFIG_FIRMWARE_EDID is not set | 899 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set |
891 | CONFIG_FB=y | 900 | CONFIG_FB=y |
901 | # CONFIG_FIRMWARE_EDID is not set | ||
892 | CONFIG_FB_DDC=y | 902 | CONFIG_FB_DDC=y |
893 | CONFIG_FB_CFB_FILLRECT=y | 903 | CONFIG_FB_CFB_FILLRECT=y |
894 | CONFIG_FB_CFB_COPYAREA=y | 904 | CONFIG_FB_CFB_COPYAREA=y |
895 | CONFIG_FB_CFB_IMAGEBLIT=y | 905 | CONFIG_FB_CFB_IMAGEBLIT=y |
906 | # CONFIG_FB_SVGALIB is not set | ||
896 | # CONFIG_FB_MACMODES is not set | 907 | # CONFIG_FB_MACMODES is not set |
897 | # CONFIG_FB_BACKLIGHT is not set | 908 | # CONFIG_FB_BACKLIGHT is not set |
898 | CONFIG_FB_MODE_HELPERS=y | 909 | CONFIG_FB_MODE_HELPERS=y |
899 | CONFIG_FB_TILEBLITTING=y | 910 | CONFIG_FB_TILEBLITTING=y |
911 | |||
912 | # | ||
913 | # Frambuffer hardware drivers | ||
914 | # | ||
900 | # CONFIG_FB_CIRRUS is not set | 915 | # CONFIG_FB_CIRRUS is not set |
901 | # CONFIG_FB_PM2 is not set | 916 | # CONFIG_FB_PM2 is not set |
902 | # CONFIG_FB_ASILIANT is not set | 917 | # CONFIG_FB_ASILIANT is not set |
@@ -908,9 +923,11 @@ CONFIG_FB_TILEBLITTING=y | |||
908 | # CONFIG_FB_MATROX is not set | 923 | # CONFIG_FB_MATROX is not set |
909 | CONFIG_FB_RADEON=y | 924 | CONFIG_FB_RADEON=y |
910 | CONFIG_FB_RADEON_I2C=y | 925 | CONFIG_FB_RADEON_I2C=y |
926 | # CONFIG_FB_RADEON_BACKLIGHT is not set | ||
911 | # CONFIG_FB_RADEON_DEBUG is not set | 927 | # CONFIG_FB_RADEON_DEBUG is not set |
912 | # CONFIG_FB_ATY128 is not set | 928 | # CONFIG_FB_ATY128 is not set |
913 | # CONFIG_FB_ATY is not set | 929 | # CONFIG_FB_ATY is not set |
930 | # CONFIG_FB_S3 is not set | ||
914 | # CONFIG_FB_SAVAGE is not set | 931 | # CONFIG_FB_SAVAGE is not set |
915 | # CONFIG_FB_SIS is not set | 932 | # CONFIG_FB_SIS is not set |
916 | # CONFIG_FB_NEOMAGIC is not set | 933 | # CONFIG_FB_NEOMAGIC is not set |
@@ -947,7 +964,6 @@ CONFIG_LOGO=y | |||
947 | # CONFIG_LOGO_LINUX_VGA16 is not set | 964 | # CONFIG_LOGO_LINUX_VGA16 is not set |
948 | # CONFIG_LOGO_LINUX_CLUT224 is not set | 965 | # CONFIG_LOGO_LINUX_CLUT224 is not set |
949 | CONFIG_LOGO_SUN_CLUT224=y | 966 | CONFIG_LOGO_SUN_CLUT224=y |
950 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | ||
951 | 967 | ||
952 | # | 968 | # |
953 | # Sound | 969 | # Sound |
@@ -1192,6 +1208,7 @@ CONFIG_USB_HIDDEV=y | |||
1192 | # CONFIG_USB_RIO500 is not set | 1208 | # CONFIG_USB_RIO500 is not set |
1193 | # CONFIG_USB_LEGOTOWER is not set | 1209 | # CONFIG_USB_LEGOTOWER is not set |
1194 | # CONFIG_USB_LCD is not set | 1210 | # CONFIG_USB_LCD is not set |
1211 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1195 | # CONFIG_USB_LED is not set | 1212 | # CONFIG_USB_LED is not set |
1196 | # CONFIG_USB_CYPRESS_CY7C63 is not set | 1213 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
1197 | # CONFIG_USB_CYTHERM is not set | 1214 | # CONFIG_USB_CYTHERM is not set |
@@ -1445,9 +1462,11 @@ CONFIG_MAGIC_SYSRQ=y | |||
1445 | CONFIG_DEBUG_FS=y | 1462 | CONFIG_DEBUG_FS=y |
1446 | # CONFIG_HEADERS_CHECK is not set | 1463 | # CONFIG_HEADERS_CHECK is not set |
1447 | CONFIG_DEBUG_KERNEL=y | 1464 | CONFIG_DEBUG_KERNEL=y |
1465 | # CONFIG_DEBUG_SHIRQ is not set | ||
1448 | CONFIG_LOG_BUF_SHIFT=18 | 1466 | CONFIG_LOG_BUF_SHIFT=18 |
1449 | CONFIG_DETECT_SOFTLOCKUP=y | 1467 | CONFIG_DETECT_SOFTLOCKUP=y |
1450 | CONFIG_SCHEDSTATS=y | 1468 | CONFIG_SCHEDSTATS=y |
1469 | # CONFIG_TIMER_STATS is not set | ||
1451 | # CONFIG_DEBUG_SLAB is not set | 1470 | # CONFIG_DEBUG_SLAB is not set |
1452 | # CONFIG_DEBUG_RT_MUTEXES is not set | 1471 | # CONFIG_DEBUG_RT_MUTEXES is not set |
1453 | # CONFIG_RT_MUTEX_TESTER is not set | 1472 | # CONFIG_RT_MUTEX_TESTER is not set |
@@ -1465,6 +1484,7 @@ CONFIG_DEBUG_BUGVERBOSE=y | |||
1465 | CONFIG_FORCED_INLINING=y | 1484 | CONFIG_FORCED_INLINING=y |
1466 | # CONFIG_RCU_TORTURE_TEST is not set | 1485 | # CONFIG_RCU_TORTURE_TEST is not set |
1467 | # CONFIG_LKDTM is not set | 1486 | # CONFIG_LKDTM is not set |
1487 | # CONFIG_FAULT_INJECTION is not set | ||
1468 | # CONFIG_DEBUG_STACK_USAGE is not set | 1488 | # CONFIG_DEBUG_STACK_USAGE is not set |
1469 | # CONFIG_DEBUG_DCFLUSH is not set | 1489 | # CONFIG_DEBUG_DCFLUSH is not set |
1470 | # CONFIG_STACK_DEBUG is not set | 1490 | # CONFIG_STACK_DEBUG is not set |
diff --git a/arch/sparc64/kernel/irq.c b/arch/sparc64/kernel/irq.c index b5ff3ee5ace1..c443db184371 100644 --- a/arch/sparc64/kernel/irq.c +++ b/arch/sparc64/kernel/irq.c | |||
@@ -109,6 +109,7 @@ static unsigned char virt_irq_alloc(unsigned int real_irq) | |||
109 | return ent; | 109 | return ent; |
110 | } | 110 | } |
111 | 111 | ||
112 | #ifdef CONFIG_PCI_MSI | ||
112 | static void virt_irq_free(unsigned int virt_irq) | 113 | static void virt_irq_free(unsigned int virt_irq) |
113 | { | 114 | { |
114 | unsigned int real_irq; | 115 | unsigned int real_irq; |
@@ -121,6 +122,7 @@ static void virt_irq_free(unsigned int virt_irq) | |||
121 | 122 | ||
122 | __bucket(real_irq)->virt_irq = 0; | 123 | __bucket(real_irq)->virt_irq = 0; |
123 | } | 124 | } |
125 | #endif | ||
124 | 126 | ||
125 | static unsigned int virt_to_real_irq(unsigned char virt_irq) | 127 | static unsigned int virt_to_real_irq(unsigned char virt_irq) |
126 | { | 128 | { |
diff --git a/arch/sparc64/kernel/pci.c b/arch/sparc64/kernel/pci.c index 6b740eb6fe7e..6fedfb98f8b0 100644 --- a/arch/sparc64/kernel/pci.c +++ b/arch/sparc64/kernel/pci.c | |||
@@ -668,7 +668,7 @@ int arch_setup_msi_irq(struct pci_dev *pdev, struct msi_desc *desc) | |||
668 | 668 | ||
669 | void arch_teardown_msi_irq(unsigned int virt_irq) | 669 | void arch_teardown_msi_irq(unsigned int virt_irq) |
670 | { | 670 | { |
671 | struct msi_desc *entry = get_irq_data(virt_irq); | 671 | struct msi_desc *entry = get_irq_msi(virt_irq); |
672 | struct pci_dev *pdev = entry->dev; | 672 | struct pci_dev *pdev = entry->dev; |
673 | struct pcidev_cookie *pcp = pdev->sysdata; | 673 | struct pcidev_cookie *pcp = pdev->sysdata; |
674 | struct pci_pbm_info *pbm = pcp->pbm; | 674 | struct pci_pbm_info *pbm = pcp->pbm; |
diff --git a/arch/x86_64/kernel/entry.S b/arch/x86_64/kernel/entry.S index 9f5dac64aa8f..ed4350ced3d0 100644 --- a/arch/x86_64/kernel/entry.S +++ b/arch/x86_64/kernel/entry.S | |||
@@ -675,6 +675,9 @@ END(invalidate_interrupt\num) | |||
675 | ENTRY(call_function_interrupt) | 675 | ENTRY(call_function_interrupt) |
676 | apicinterrupt CALL_FUNCTION_VECTOR,smp_call_function_interrupt | 676 | apicinterrupt CALL_FUNCTION_VECTOR,smp_call_function_interrupt |
677 | END(call_function_interrupt) | 677 | END(call_function_interrupt) |
678 | ENTRY(irq_move_cleanup_interrupt) | ||
679 | apicinterrupt IRQ_MOVE_CLEANUP_VECTOR,smp_irq_move_cleanup_interrupt | ||
680 | END(irq_move_cleanup_interrupt) | ||
678 | #endif | 681 | #endif |
679 | 682 | ||
680 | ENTRY(apic_timer_interrupt) | 683 | ENTRY(apic_timer_interrupt) |
diff --git a/arch/x86_64/kernel/i8259.c b/arch/x86_64/kernel/i8259.c index 01e2cf0bdeb1..21d95b747437 100644 --- a/arch/x86_64/kernel/i8259.c +++ b/arch/x86_64/kernel/i8259.c | |||
@@ -299,7 +299,7 @@ void init_8259A(int auto_eoi) | |||
299 | * outb_p - this has to work on a wide range of PC hardware. | 299 | * outb_p - this has to work on a wide range of PC hardware. |
300 | */ | 300 | */ |
301 | outb_p(0x11, 0x20); /* ICW1: select 8259A-1 init */ | 301 | outb_p(0x11, 0x20); /* ICW1: select 8259A-1 init */ |
302 | outb_p(0x20 + 0, 0x21); /* ICW2: 8259A-1 IR0-7 mapped to 0x20-0x27 */ | 302 | outb_p(IRQ0_VECTOR, 0x21); /* ICW2: 8259A-1 IR0-7 mapped to 0x20-0x27 */ |
303 | outb_p(0x04, 0x21); /* 8259A-1 (the master) has a slave on IR2 */ | 303 | outb_p(0x04, 0x21); /* 8259A-1 (the master) has a slave on IR2 */ |
304 | if (auto_eoi) | 304 | if (auto_eoi) |
305 | outb_p(0x03, 0x21); /* master does Auto EOI */ | 305 | outb_p(0x03, 0x21); /* master does Auto EOI */ |
@@ -307,7 +307,7 @@ void init_8259A(int auto_eoi) | |||
307 | outb_p(0x01, 0x21); /* master expects normal EOI */ | 307 | outb_p(0x01, 0x21); /* master expects normal EOI */ |
308 | 308 | ||
309 | outb_p(0x11, 0xA0); /* ICW1: select 8259A-2 init */ | 309 | outb_p(0x11, 0xA0); /* ICW1: select 8259A-2 init */ |
310 | outb_p(0x20 + 8, 0xA1); /* ICW2: 8259A-2 IR0-7 mapped to 0x28-0x2f */ | 310 | outb_p(IRQ8_VECTOR, 0xA1); /* ICW2: 8259A-2 IR0-7 mapped to 0x28-0x2f */ |
311 | outb_p(0x02, 0xA1); /* 8259A-2 is a slave on master's IR2 */ | 311 | outb_p(0x02, 0xA1); /* 8259A-2 is a slave on master's IR2 */ |
312 | outb_p(0x01, 0xA1); /* (slave's support for AEOI in flat mode | 312 | outb_p(0x01, 0xA1); /* (slave's support for AEOI in flat mode |
313 | is to be investigated) */ | 313 | is to be investigated) */ |
@@ -398,24 +398,24 @@ device_initcall(i8259A_init_sysfs); | |||
398 | 398 | ||
399 | static struct irqaction irq2 = { no_action, 0, CPU_MASK_NONE, "cascade", NULL, NULL}; | 399 | static struct irqaction irq2 = { no_action, 0, CPU_MASK_NONE, "cascade", NULL, NULL}; |
400 | DEFINE_PER_CPU(vector_irq_t, vector_irq) = { | 400 | DEFINE_PER_CPU(vector_irq_t, vector_irq) = { |
401 | [0 ... FIRST_EXTERNAL_VECTOR - 1] = -1, | 401 | [0 ... IRQ0_VECTOR - 1] = -1, |
402 | [FIRST_EXTERNAL_VECTOR + 0] = 0, | 402 | [IRQ0_VECTOR] = 0, |
403 | [FIRST_EXTERNAL_VECTOR + 1] = 1, | 403 | [IRQ1_VECTOR] = 1, |
404 | [FIRST_EXTERNAL_VECTOR + 2] = 2, | 404 | [IRQ2_VECTOR] = 2, |
405 | [FIRST_EXTERNAL_VECTOR + 3] = 3, | 405 | [IRQ3_VECTOR] = 3, |
406 | [FIRST_EXTERNAL_VECTOR + 4] = 4, | 406 | [IRQ4_VECTOR] = 4, |
407 | [FIRST_EXTERNAL_VECTOR + 5] = 5, | 407 | [IRQ5_VECTOR] = 5, |
408 | [FIRST_EXTERNAL_VECTOR + 6] = 6, | 408 | [IRQ6_VECTOR] = 6, |
409 | [FIRST_EXTERNAL_VECTOR + 7] = 7, | 409 | [IRQ7_VECTOR] = 7, |
410 | [FIRST_EXTERNAL_VECTOR + 8] = 8, | 410 | [IRQ8_VECTOR] = 8, |
411 | [FIRST_EXTERNAL_VECTOR + 9] = 9, | 411 | [IRQ9_VECTOR] = 9, |
412 | [FIRST_EXTERNAL_VECTOR + 10] = 10, | 412 | [IRQ10_VECTOR] = 10, |
413 | [FIRST_EXTERNAL_VECTOR + 11] = 11, | 413 | [IRQ11_VECTOR] = 11, |
414 | [FIRST_EXTERNAL_VECTOR + 12] = 12, | 414 | [IRQ12_VECTOR] = 12, |
415 | [FIRST_EXTERNAL_VECTOR + 13] = 13, | 415 | [IRQ13_VECTOR] = 13, |
416 | [FIRST_EXTERNAL_VECTOR + 14] = 14, | 416 | [IRQ14_VECTOR] = 14, |
417 | [FIRST_EXTERNAL_VECTOR + 15] = 15, | 417 | [IRQ15_VECTOR] = 15, |
418 | [FIRST_EXTERNAL_VECTOR + 16 ... NR_VECTORS - 1] = -1 | 418 | [IRQ15_VECTOR + 1 ... NR_VECTORS - 1] = -1 |
419 | }; | 419 | }; |
420 | 420 | ||
421 | void __init init_ISA_irqs (void) | 421 | void __init init_ISA_irqs (void) |
@@ -450,6 +450,7 @@ void spurious_interrupt(void); | |||
450 | void error_interrupt(void); | 450 | void error_interrupt(void); |
451 | void reschedule_interrupt(void); | 451 | void reschedule_interrupt(void); |
452 | void call_function_interrupt(void); | 452 | void call_function_interrupt(void); |
453 | void irq_move_cleanup_interrupt(void); | ||
453 | void invalidate_interrupt0(void); | 454 | void invalidate_interrupt0(void); |
454 | void invalidate_interrupt1(void); | 455 | void invalidate_interrupt1(void); |
455 | void invalidate_interrupt2(void); | 456 | void invalidate_interrupt2(void); |
@@ -520,12 +521,6 @@ void __init init_IRQ(void) | |||
520 | 521 | ||
521 | #ifdef CONFIG_SMP | 522 | #ifdef CONFIG_SMP |
522 | /* | 523 | /* |
523 | * IRQ0 must be given a fixed assignment and initialized, | ||
524 | * because it's used before the IO-APIC is set up. | ||
525 | */ | ||
526 | __get_cpu_var(vector_irq)[FIRST_DEVICE_VECTOR] = 0; | ||
527 | |||
528 | /* | ||
529 | * The reschedule interrupt is a CPU-to-CPU reschedule-helper | 524 | * The reschedule interrupt is a CPU-to-CPU reschedule-helper |
530 | * IPI, driven by wakeup. | 525 | * IPI, driven by wakeup. |
531 | */ | 526 | */ |
@@ -543,7 +538,10 @@ void __init init_IRQ(void) | |||
543 | 538 | ||
544 | /* IPI for generic function call */ | 539 | /* IPI for generic function call */ |
545 | set_intr_gate(CALL_FUNCTION_VECTOR, call_function_interrupt); | 540 | set_intr_gate(CALL_FUNCTION_VECTOR, call_function_interrupt); |
546 | #endif | 541 | |
542 | /* Low priority IPI to cleanup after moving an irq */ | ||
543 | set_intr_gate(IRQ_MOVE_CLEANUP_VECTOR, irq_move_cleanup_interrupt); | ||
544 | #endif | ||
547 | set_intr_gate(THERMAL_APIC_VECTOR, thermal_interrupt); | 545 | set_intr_gate(THERMAL_APIC_VECTOR, thermal_interrupt); |
548 | set_intr_gate(THRESHOLD_APIC_VECTOR, threshold_interrupt); | 546 | set_intr_gate(THRESHOLD_APIC_VECTOR, threshold_interrupt); |
549 | 547 | ||
diff --git a/arch/x86_64/kernel/io_apic.c b/arch/x86_64/kernel/io_apic.c index 950682f35766..48593f6b708f 100644 --- a/arch/x86_64/kernel/io_apic.c +++ b/arch/x86_64/kernel/io_apic.c | |||
@@ -36,6 +36,7 @@ | |||
36 | #include <acpi/acpi_bus.h> | 36 | #include <acpi/acpi_bus.h> |
37 | #endif | 37 | #endif |
38 | 38 | ||
39 | #include <asm/idle.h> | ||
39 | #include <asm/io.h> | 40 | #include <asm/io.h> |
40 | #include <asm/smp.h> | 41 | #include <asm/smp.h> |
41 | #include <asm/desc.h> | 42 | #include <asm/desc.h> |
@@ -47,7 +48,35 @@ | |||
47 | #include <asm/msidef.h> | 48 | #include <asm/msidef.h> |
48 | #include <asm/hypertransport.h> | 49 | #include <asm/hypertransport.h> |
49 | 50 | ||
50 | static int assign_irq_vector(int irq, cpumask_t mask, cpumask_t *result); | 51 | struct irq_cfg { |
52 | cpumask_t domain; | ||
53 | cpumask_t old_domain; | ||
54 | unsigned move_cleanup_count; | ||
55 | u8 vector; | ||
56 | u8 move_in_progress : 1; | ||
57 | }; | ||
58 | |||
59 | /* irq_cfg is indexed by the sum of all RTEs in all I/O APICs. */ | ||
60 | struct irq_cfg irq_cfg[NR_IRQS] __read_mostly = { | ||
61 | [0] = { .domain = CPU_MASK_ALL, .vector = IRQ0_VECTOR, }, | ||
62 | [1] = { .domain = CPU_MASK_ALL, .vector = IRQ1_VECTOR, }, | ||
63 | [2] = { .domain = CPU_MASK_ALL, .vector = IRQ2_VECTOR, }, | ||
64 | [3] = { .domain = CPU_MASK_ALL, .vector = IRQ3_VECTOR, }, | ||
65 | [4] = { .domain = CPU_MASK_ALL, .vector = IRQ4_VECTOR, }, | ||
66 | [5] = { .domain = CPU_MASK_ALL, .vector = IRQ5_VECTOR, }, | ||
67 | [6] = { .domain = CPU_MASK_ALL, .vector = IRQ6_VECTOR, }, | ||
68 | [7] = { .domain = CPU_MASK_ALL, .vector = IRQ7_VECTOR, }, | ||
69 | [8] = { .domain = CPU_MASK_ALL, .vector = IRQ8_VECTOR, }, | ||
70 | [9] = { .domain = CPU_MASK_ALL, .vector = IRQ9_VECTOR, }, | ||
71 | [10] = { .domain = CPU_MASK_ALL, .vector = IRQ10_VECTOR, }, | ||
72 | [11] = { .domain = CPU_MASK_ALL, .vector = IRQ11_VECTOR, }, | ||
73 | [12] = { .domain = CPU_MASK_ALL, .vector = IRQ12_VECTOR, }, | ||
74 | [13] = { .domain = CPU_MASK_ALL, .vector = IRQ13_VECTOR, }, | ||
75 | [14] = { .domain = CPU_MASK_ALL, .vector = IRQ14_VECTOR, }, | ||
76 | [15] = { .domain = CPU_MASK_ALL, .vector = IRQ15_VECTOR, }, | ||
77 | }; | ||
78 | |||
79 | static int assign_irq_vector(int irq, cpumask_t mask); | ||
51 | 80 | ||
52 | #define __apicdebuginit __init | 81 | #define __apicdebuginit __init |
53 | 82 | ||
@@ -74,7 +103,7 @@ int nr_ioapic_registers[MAX_IO_APICS]; | |||
74 | * Rough estimation of how many shared IRQs there are, can | 103 | * Rough estimation of how many shared IRQs there are, can |
75 | * be changed anytime. | 104 | * be changed anytime. |
76 | */ | 105 | */ |
77 | #define MAX_PLUS_SHARED_IRQS NR_IRQ_VECTORS | 106 | #define MAX_PLUS_SHARED_IRQS NR_IRQS |
78 | #define PIN_MAP_SIZE (MAX_PLUS_SHARED_IRQS + NR_IRQS) | 107 | #define PIN_MAP_SIZE (MAX_PLUS_SHARED_IRQS + NR_IRQS) |
79 | 108 | ||
80 | /* | 109 | /* |
@@ -149,11 +178,11 @@ static inline void io_apic_sync(unsigned int apic) | |||
149 | reg = io_apic_read(entry->apic, 0x10 + R + pin*2); \ | 178 | reg = io_apic_read(entry->apic, 0x10 + R + pin*2); \ |
150 | reg ACTION; \ | 179 | reg ACTION; \ |
151 | io_apic_modify(entry->apic, reg); \ | 180 | io_apic_modify(entry->apic, reg); \ |
181 | FINAL; \ | ||
152 | if (!entry->next) \ | 182 | if (!entry->next) \ |
153 | break; \ | 183 | break; \ |
154 | entry = irq_2_pin + entry->next; \ | 184 | entry = irq_2_pin + entry->next; \ |
155 | } \ | 185 | } \ |
156 | FINAL; \ | ||
157 | } | 186 | } |
158 | 187 | ||
159 | union entry_union { | 188 | union entry_union { |
@@ -237,21 +266,19 @@ static void __target_IO_APIC_irq(unsigned int irq, unsigned int dest, u8 vector) | |||
237 | 266 | ||
238 | static void set_ioapic_affinity_irq(unsigned int irq, cpumask_t mask) | 267 | static void set_ioapic_affinity_irq(unsigned int irq, cpumask_t mask) |
239 | { | 268 | { |
269 | struct irq_cfg *cfg = irq_cfg + irq; | ||
240 | unsigned long flags; | 270 | unsigned long flags; |
241 | unsigned int dest; | 271 | unsigned int dest; |
242 | cpumask_t tmp; | 272 | cpumask_t tmp; |
243 | int vector; | ||
244 | 273 | ||
245 | cpus_and(tmp, mask, cpu_online_map); | 274 | cpus_and(tmp, mask, cpu_online_map); |
246 | if (cpus_empty(tmp)) | 275 | if (cpus_empty(tmp)) |
247 | tmp = TARGET_CPUS; | 276 | return; |
248 | |||
249 | cpus_and(mask, tmp, CPU_MASK_ALL); | ||
250 | 277 | ||
251 | vector = assign_irq_vector(irq, mask, &tmp); | 278 | if (assign_irq_vector(irq, mask)) |
252 | if (vector < 0) | ||
253 | return; | 279 | return; |
254 | 280 | ||
281 | cpus_and(tmp, cfg->domain, mask); | ||
255 | dest = cpu_mask_to_apicid(tmp); | 282 | dest = cpu_mask_to_apicid(tmp); |
256 | 283 | ||
257 | /* | 284 | /* |
@@ -260,8 +287,8 @@ static void set_ioapic_affinity_irq(unsigned int irq, cpumask_t mask) | |||
260 | dest = SET_APIC_LOGICAL_ID(dest); | 287 | dest = SET_APIC_LOGICAL_ID(dest); |
261 | 288 | ||
262 | spin_lock_irqsave(&ioapic_lock, flags); | 289 | spin_lock_irqsave(&ioapic_lock, flags); |
263 | __target_IO_APIC_irq(irq, dest, vector); | 290 | __target_IO_APIC_irq(irq, dest, cfg->vector); |
264 | set_native_irq_info(irq, mask); | 291 | irq_desc[irq].affinity = mask; |
265 | spin_unlock_irqrestore(&ioapic_lock, flags); | 292 | spin_unlock_irqrestore(&ioapic_lock, flags); |
266 | } | 293 | } |
267 | #endif | 294 | #endif |
@@ -615,63 +642,7 @@ static int pin_2_irq(int idx, int apic, int pin) | |||
615 | return irq; | 642 | return irq; |
616 | } | 643 | } |
617 | 644 | ||
618 | static inline int IO_APIC_irq_trigger(int irq) | 645 | static int __assign_irq_vector(int irq, cpumask_t mask) |
619 | { | ||
620 | int apic, idx, pin; | ||
621 | |||
622 | for (apic = 0; apic < nr_ioapics; apic++) { | ||
623 | for (pin = 0; pin < nr_ioapic_registers[apic]; pin++) { | ||
624 | idx = find_irq_entry(apic,pin,mp_INT); | ||
625 | if ((idx != -1) && (irq == pin_2_irq(idx,apic,pin))) | ||
626 | return irq_trigger(idx); | ||
627 | } | ||
628 | } | ||
629 | /* | ||
630 | * nonexistent IRQs are edge default | ||
631 | */ | ||
632 | return 0; | ||
633 | } | ||
634 | |||
635 | /* irq_vectors is indexed by the sum of all RTEs in all I/O APICs. */ | ||
636 | static u8 irq_vector[NR_IRQ_VECTORS] __read_mostly = { | ||
637 | [0] = FIRST_EXTERNAL_VECTOR + 0, | ||
638 | [1] = FIRST_EXTERNAL_VECTOR + 1, | ||
639 | [2] = FIRST_EXTERNAL_VECTOR + 2, | ||
640 | [3] = FIRST_EXTERNAL_VECTOR + 3, | ||
641 | [4] = FIRST_EXTERNAL_VECTOR + 4, | ||
642 | [5] = FIRST_EXTERNAL_VECTOR + 5, | ||
643 | [6] = FIRST_EXTERNAL_VECTOR + 6, | ||
644 | [7] = FIRST_EXTERNAL_VECTOR + 7, | ||
645 | [8] = FIRST_EXTERNAL_VECTOR + 8, | ||
646 | [9] = FIRST_EXTERNAL_VECTOR + 9, | ||
647 | [10] = FIRST_EXTERNAL_VECTOR + 10, | ||
648 | [11] = FIRST_EXTERNAL_VECTOR + 11, | ||
649 | [12] = FIRST_EXTERNAL_VECTOR + 12, | ||
650 | [13] = FIRST_EXTERNAL_VECTOR + 13, | ||
651 | [14] = FIRST_EXTERNAL_VECTOR + 14, | ||
652 | [15] = FIRST_EXTERNAL_VECTOR + 15, | ||
653 | }; | ||
654 | |||
655 | static cpumask_t irq_domain[NR_IRQ_VECTORS] __read_mostly = { | ||
656 | [0] = CPU_MASK_ALL, | ||
657 | [1] = CPU_MASK_ALL, | ||
658 | [2] = CPU_MASK_ALL, | ||
659 | [3] = CPU_MASK_ALL, | ||
660 | [4] = CPU_MASK_ALL, | ||
661 | [5] = CPU_MASK_ALL, | ||
662 | [6] = CPU_MASK_ALL, | ||
663 | [7] = CPU_MASK_ALL, | ||
664 | [8] = CPU_MASK_ALL, | ||
665 | [9] = CPU_MASK_ALL, | ||
666 | [10] = CPU_MASK_ALL, | ||
667 | [11] = CPU_MASK_ALL, | ||
668 | [12] = CPU_MASK_ALL, | ||
669 | [13] = CPU_MASK_ALL, | ||
670 | [14] = CPU_MASK_ALL, | ||
671 | [15] = CPU_MASK_ALL, | ||
672 | }; | ||
673 | |||
674 | static int __assign_irq_vector(int irq, cpumask_t mask, cpumask_t *result) | ||
675 | { | 646 | { |
676 | /* | 647 | /* |
677 | * NOTE! The local APIC isn't very good at handling | 648 | * NOTE! The local APIC isn't very good at handling |
@@ -685,20 +656,25 @@ static int __assign_irq_vector(int irq, cpumask_t mask, cpumask_t *result) | |||
685 | * 0x80, because int 0x80 is hm, kind of importantish. ;) | 656 | * 0x80, because int 0x80 is hm, kind of importantish. ;) |
686 | */ | 657 | */ |
687 | static int current_vector = FIRST_DEVICE_VECTOR, current_offset = 0; | 658 | static int current_vector = FIRST_DEVICE_VECTOR, current_offset = 0; |
688 | int old_vector = -1; | 659 | unsigned int old_vector; |
689 | int cpu; | 660 | int cpu; |
661 | struct irq_cfg *cfg; | ||
690 | 662 | ||
691 | BUG_ON((unsigned)irq >= NR_IRQ_VECTORS); | 663 | BUG_ON((unsigned)irq >= NR_IRQS); |
664 | cfg = &irq_cfg[irq]; | ||
692 | 665 | ||
693 | /* Only try and allocate irqs on cpus that are present */ | 666 | /* Only try and allocate irqs on cpus that are present */ |
694 | cpus_and(mask, mask, cpu_online_map); | 667 | cpus_and(mask, mask, cpu_online_map); |
695 | 668 | ||
696 | if (irq_vector[irq] > 0) | 669 | if ((cfg->move_in_progress) || cfg->move_cleanup_count) |
697 | old_vector = irq_vector[irq]; | 670 | return -EBUSY; |
698 | if (old_vector > 0) { | 671 | |
699 | cpus_and(*result, irq_domain[irq], mask); | 672 | old_vector = cfg->vector; |
700 | if (!cpus_empty(*result)) | 673 | if (old_vector) { |
701 | return old_vector; | 674 | cpumask_t tmp; |
675 | cpus_and(tmp, cfg->domain, mask); | ||
676 | if (!cpus_empty(tmp)) | ||
677 | return 0; | ||
702 | } | 678 | } |
703 | 679 | ||
704 | for_each_cpu_mask(cpu, mask) { | 680 | for_each_cpu_mask(cpu, mask) { |
@@ -728,48 +704,47 @@ next: | |||
728 | /* Found one! */ | 704 | /* Found one! */ |
729 | current_vector = vector; | 705 | current_vector = vector; |
730 | current_offset = offset; | 706 | current_offset = offset; |
731 | if (old_vector >= 0) { | 707 | if (old_vector) { |
732 | cpumask_t old_mask; | 708 | cfg->move_in_progress = 1; |
733 | int old_cpu; | 709 | cfg->old_domain = cfg->domain; |
734 | cpus_and(old_mask, irq_domain[irq], cpu_online_map); | ||
735 | for_each_cpu_mask(old_cpu, old_mask) | ||
736 | per_cpu(vector_irq, old_cpu)[old_vector] = -1; | ||
737 | } | 710 | } |
738 | for_each_cpu_mask(new_cpu, new_mask) | 711 | for_each_cpu_mask(new_cpu, new_mask) |
739 | per_cpu(vector_irq, new_cpu)[vector] = irq; | 712 | per_cpu(vector_irq, new_cpu)[vector] = irq; |
740 | irq_vector[irq] = vector; | 713 | cfg->vector = vector; |
741 | irq_domain[irq] = domain; | 714 | cfg->domain = domain; |
742 | cpus_and(*result, domain, mask); | 715 | return 0; |
743 | return vector; | ||
744 | } | 716 | } |
745 | return -ENOSPC; | 717 | return -ENOSPC; |
746 | } | 718 | } |
747 | 719 | ||
748 | static int assign_irq_vector(int irq, cpumask_t mask, cpumask_t *result) | 720 | static int assign_irq_vector(int irq, cpumask_t mask) |
749 | { | 721 | { |
750 | int vector; | 722 | int err; |
751 | unsigned long flags; | 723 | unsigned long flags; |
752 | 724 | ||
753 | spin_lock_irqsave(&vector_lock, flags); | 725 | spin_lock_irqsave(&vector_lock, flags); |
754 | vector = __assign_irq_vector(irq, mask, result); | 726 | err = __assign_irq_vector(irq, mask); |
755 | spin_unlock_irqrestore(&vector_lock, flags); | 727 | spin_unlock_irqrestore(&vector_lock, flags); |
756 | return vector; | 728 | return err; |
757 | } | 729 | } |
758 | 730 | ||
759 | static void __clear_irq_vector(int irq) | 731 | static void __clear_irq_vector(int irq) |
760 | { | 732 | { |
733 | struct irq_cfg *cfg; | ||
761 | cpumask_t mask; | 734 | cpumask_t mask; |
762 | int cpu, vector; | 735 | int cpu, vector; |
763 | 736 | ||
764 | BUG_ON(!irq_vector[irq]); | 737 | BUG_ON((unsigned)irq >= NR_IRQS); |
738 | cfg = &irq_cfg[irq]; | ||
739 | BUG_ON(!cfg->vector); | ||
765 | 740 | ||
766 | vector = irq_vector[irq]; | 741 | vector = cfg->vector; |
767 | cpus_and(mask, irq_domain[irq], cpu_online_map); | 742 | cpus_and(mask, cfg->domain, cpu_online_map); |
768 | for_each_cpu_mask(cpu, mask) | 743 | for_each_cpu_mask(cpu, mask) |
769 | per_cpu(vector_irq, cpu)[vector] = -1; | 744 | per_cpu(vector_irq, cpu)[vector] = -1; |
770 | 745 | ||
771 | irq_vector[irq] = 0; | 746 | cfg->vector = 0; |
772 | irq_domain[irq] = CPU_MASK_NONE; | 747 | cfg->domain = CPU_MASK_NONE; |
773 | } | 748 | } |
774 | 749 | ||
775 | void __setup_vector_irq(int cpu) | 750 | void __setup_vector_irq(int cpu) |
@@ -779,10 +754,10 @@ void __setup_vector_irq(int cpu) | |||
779 | int irq, vector; | 754 | int irq, vector; |
780 | 755 | ||
781 | /* Mark the inuse vectors */ | 756 | /* Mark the inuse vectors */ |
782 | for (irq = 0; irq < NR_IRQ_VECTORS; ++irq) { | 757 | for (irq = 0; irq < NR_IRQS; ++irq) { |
783 | if (!cpu_isset(cpu, irq_domain[irq])) | 758 | if (!cpu_isset(cpu, irq_cfg[irq].domain)) |
784 | continue; | 759 | continue; |
785 | vector = irq_vector[irq]; | 760 | vector = irq_cfg[irq].vector; |
786 | per_cpu(vector_irq, cpu)[vector] = irq; | 761 | per_cpu(vector_irq, cpu)[vector] = irq; |
787 | } | 762 | } |
788 | /* Mark the free vectors */ | 763 | /* Mark the free vectors */ |
@@ -790,36 +765,46 @@ void __setup_vector_irq(int cpu) | |||
790 | irq = per_cpu(vector_irq, cpu)[vector]; | 765 | irq = per_cpu(vector_irq, cpu)[vector]; |
791 | if (irq < 0) | 766 | if (irq < 0) |
792 | continue; | 767 | continue; |
793 | if (!cpu_isset(cpu, irq_domain[irq])) | 768 | if (!cpu_isset(cpu, irq_cfg[irq].domain)) |
794 | per_cpu(vector_irq, cpu)[vector] = -1; | 769 | per_cpu(vector_irq, cpu)[vector] = -1; |
795 | } | 770 | } |
796 | } | 771 | } |
797 | 772 | ||
798 | 773 | ||
799 | extern void (*interrupt[NR_IRQS])(void); | ||
800 | |||
801 | static struct irq_chip ioapic_chip; | 774 | static struct irq_chip ioapic_chip; |
802 | 775 | ||
803 | #define IOAPIC_AUTO -1 | 776 | static void ioapic_register_intr(int irq, unsigned long trigger) |
804 | #define IOAPIC_EDGE 0 | ||
805 | #define IOAPIC_LEVEL 1 | ||
806 | |||
807 | static void ioapic_register_intr(int irq, int vector, unsigned long trigger) | ||
808 | { | 777 | { |
809 | if ((trigger == IOAPIC_AUTO && IO_APIC_irq_trigger(irq)) || | 778 | if (trigger) |
810 | trigger == IOAPIC_LEVEL) | ||
811 | set_irq_chip_and_handler_name(irq, &ioapic_chip, | 779 | set_irq_chip_and_handler_name(irq, &ioapic_chip, |
812 | handle_fasteoi_irq, "fasteoi"); | 780 | handle_fasteoi_irq, "fasteoi"); |
813 | else | 781 | else |
814 | set_irq_chip_and_handler_name(irq, &ioapic_chip, | 782 | set_irq_chip_and_handler_name(irq, &ioapic_chip, |
815 | handle_edge_irq, "edge"); | 783 | handle_edge_irq, "edge"); |
816 | } | 784 | } |
817 | static void __init setup_IO_APIC_irq(int apic, int pin, int idx, int irq) | 785 | |
786 | static void setup_IO_APIC_irq(int apic, int pin, unsigned int irq, | ||
787 | int trigger, int polarity) | ||
818 | { | 788 | { |
789 | struct irq_cfg *cfg = irq_cfg + irq; | ||
819 | struct IO_APIC_route_entry entry; | 790 | struct IO_APIC_route_entry entry; |
820 | int vector; | 791 | cpumask_t mask; |
821 | unsigned long flags; | 792 | unsigned long flags; |
822 | 793 | ||
794 | if (!IO_APIC_IRQ(irq)) | ||
795 | return; | ||
796 | |||
797 | mask = TARGET_CPUS; | ||
798 | if (assign_irq_vector(irq, mask)) | ||
799 | return; | ||
800 | |||
801 | cpus_and(mask, cfg->domain, mask); | ||
802 | |||
803 | apic_printk(APIC_VERBOSE,KERN_DEBUG | ||
804 | "IOAPIC[%d]: Set routing entry (%d-%d -> 0x%x -> " | ||
805 | "IRQ %d Mode:%i Active:%i)\n", | ||
806 | apic, mp_ioapics[apic].mpc_apicid, pin, cfg->vector, | ||
807 | irq, trigger, polarity); | ||
823 | 808 | ||
824 | /* | 809 | /* |
825 | * add it to the IO-APIC irq-routing table: | 810 | * add it to the IO-APIC irq-routing table: |
@@ -828,41 +813,27 @@ static void __init setup_IO_APIC_irq(int apic, int pin, int idx, int irq) | |||
828 | 813 | ||
829 | entry.delivery_mode = INT_DELIVERY_MODE; | 814 | entry.delivery_mode = INT_DELIVERY_MODE; |
830 | entry.dest_mode = INT_DEST_MODE; | 815 | entry.dest_mode = INT_DEST_MODE; |
816 | entry.dest = cpu_mask_to_apicid(mask); | ||
831 | entry.mask = 0; /* enable IRQ */ | 817 | entry.mask = 0; /* enable IRQ */ |
832 | entry.dest = cpu_mask_to_apicid(TARGET_CPUS); | 818 | entry.trigger = trigger; |
833 | 819 | entry.polarity = polarity; | |
834 | entry.trigger = irq_trigger(idx); | 820 | entry.vector = cfg->vector; |
835 | entry.polarity = irq_polarity(idx); | ||
836 | 821 | ||
837 | if (irq_trigger(idx)) { | 822 | /* Mask level triggered irqs. |
838 | entry.trigger = 1; | 823 | * Use IRQ_DELAYED_DISABLE for edge triggered irqs. |
824 | */ | ||
825 | if (trigger) | ||
839 | entry.mask = 1; | 826 | entry.mask = 1; |
840 | entry.dest = cpu_mask_to_apicid(TARGET_CPUS); | ||
841 | } | ||
842 | |||
843 | if (!apic && !IO_APIC_IRQ(irq)) | ||
844 | return; | ||
845 | |||
846 | if (IO_APIC_IRQ(irq)) { | ||
847 | cpumask_t mask; | ||
848 | vector = assign_irq_vector(irq, TARGET_CPUS, &mask); | ||
849 | if (vector < 0) | ||
850 | return; | ||
851 | |||
852 | entry.dest = cpu_mask_to_apicid(mask); | ||
853 | entry.vector = vector; | ||
854 | 827 | ||
855 | ioapic_register_intr(irq, vector, IOAPIC_AUTO); | 828 | ioapic_register_intr(irq, trigger); |
856 | if (!apic && (irq < 16)) | 829 | if (irq < 16) |
857 | disable_8259A_irq(irq); | 830 | disable_8259A_irq(irq); |
858 | } | ||
859 | 831 | ||
860 | ioapic_write_entry(apic, pin, entry); | 832 | ioapic_write_entry(apic, pin, entry); |
861 | 833 | ||
862 | spin_lock_irqsave(&ioapic_lock, flags); | 834 | spin_lock_irqsave(&ioapic_lock, flags); |
863 | set_native_irq_info(irq, TARGET_CPUS); | 835 | irq_desc[irq].affinity = TARGET_CPUS; |
864 | spin_unlock_irqrestore(&ioapic_lock, flags); | 836 | spin_unlock_irqrestore(&ioapic_lock, flags); |
865 | |||
866 | } | 837 | } |
867 | 838 | ||
868 | static void __init setup_IO_APIC_irqs(void) | 839 | static void __init setup_IO_APIC_irqs(void) |
@@ -887,8 +858,8 @@ static void __init setup_IO_APIC_irqs(void) | |||
887 | irq = pin_2_irq(idx, apic, pin); | 858 | irq = pin_2_irq(idx, apic, pin); |
888 | add_pin_to_irq(irq, apic, pin); | 859 | add_pin_to_irq(irq, apic, pin); |
889 | 860 | ||
890 | setup_IO_APIC_irq(apic, pin, idx, irq); | 861 | setup_IO_APIC_irq(apic, pin, irq, |
891 | 862 | irq_trigger(idx), irq_polarity(idx)); | |
892 | } | 863 | } |
893 | } | 864 | } |
894 | 865 | ||
@@ -1373,16 +1344,15 @@ static unsigned int startup_ioapic_irq(unsigned int irq) | |||
1373 | 1344 | ||
1374 | static int ioapic_retrigger_irq(unsigned int irq) | 1345 | static int ioapic_retrigger_irq(unsigned int irq) |
1375 | { | 1346 | { |
1347 | struct irq_cfg *cfg = &irq_cfg[irq]; | ||
1376 | cpumask_t mask; | 1348 | cpumask_t mask; |
1377 | unsigned vector; | ||
1378 | unsigned long flags; | 1349 | unsigned long flags; |
1379 | 1350 | ||
1380 | spin_lock_irqsave(&vector_lock, flags); | 1351 | spin_lock_irqsave(&vector_lock, flags); |
1381 | vector = irq_vector[irq]; | ||
1382 | cpus_clear(mask); | 1352 | cpus_clear(mask); |
1383 | cpu_set(first_cpu(irq_domain[irq]), mask); | 1353 | cpu_set(first_cpu(cfg->domain), mask); |
1384 | 1354 | ||
1385 | send_IPI_mask(mask, vector); | 1355 | send_IPI_mask(mask, cfg->vector); |
1386 | spin_unlock_irqrestore(&vector_lock, flags); | 1356 | spin_unlock_irqrestore(&vector_lock, flags); |
1387 | 1357 | ||
1388 | return 1; | 1358 | return 1; |
@@ -1397,8 +1367,68 @@ static int ioapic_retrigger_irq(unsigned int irq) | |||
1397 | * races. | 1367 | * races. |
1398 | */ | 1368 | */ |
1399 | 1369 | ||
1370 | #ifdef CONFIG_SMP | ||
1371 | asmlinkage void smp_irq_move_cleanup_interrupt(void) | ||
1372 | { | ||
1373 | unsigned vector, me; | ||
1374 | ack_APIC_irq(); | ||
1375 | exit_idle(); | ||
1376 | irq_enter(); | ||
1377 | |||
1378 | me = smp_processor_id(); | ||
1379 | for (vector = FIRST_EXTERNAL_VECTOR; vector < NR_VECTORS; vector++) { | ||
1380 | unsigned int irq; | ||
1381 | struct irq_desc *desc; | ||
1382 | struct irq_cfg *cfg; | ||
1383 | irq = __get_cpu_var(vector_irq)[vector]; | ||
1384 | if (irq >= NR_IRQS) | ||
1385 | continue; | ||
1386 | |||
1387 | desc = irq_desc + irq; | ||
1388 | cfg = irq_cfg + irq; | ||
1389 | spin_lock(&desc->lock); | ||
1390 | if (!cfg->move_cleanup_count) | ||
1391 | goto unlock; | ||
1392 | |||
1393 | if ((vector == cfg->vector) && cpu_isset(me, cfg->domain)) | ||
1394 | goto unlock; | ||
1395 | |||
1396 | __get_cpu_var(vector_irq)[vector] = -1; | ||
1397 | cfg->move_cleanup_count--; | ||
1398 | unlock: | ||
1399 | spin_unlock(&desc->lock); | ||
1400 | } | ||
1401 | |||
1402 | irq_exit(); | ||
1403 | } | ||
1404 | |||
1405 | static void irq_complete_move(unsigned int irq) | ||
1406 | { | ||
1407 | struct irq_cfg *cfg = irq_cfg + irq; | ||
1408 | unsigned vector, me; | ||
1409 | |||
1410 | if (likely(!cfg->move_in_progress)) | ||
1411 | return; | ||
1412 | |||
1413 | vector = ~get_irq_regs()->orig_rax; | ||
1414 | me = smp_processor_id(); | ||
1415 | if ((vector == cfg->vector) && | ||
1416 | cpu_isset(smp_processor_id(), cfg->domain)) { | ||
1417 | cpumask_t cleanup_mask; | ||
1418 | |||
1419 | cpus_and(cleanup_mask, cfg->old_domain, cpu_online_map); | ||
1420 | cfg->move_cleanup_count = cpus_weight(cleanup_mask); | ||
1421 | send_IPI_mask(cleanup_mask, IRQ_MOVE_CLEANUP_VECTOR); | ||
1422 | cfg->move_in_progress = 0; | ||
1423 | } | ||
1424 | } | ||
1425 | #else | ||
1426 | static inline void irq_complete_move(unsigned int irq) {} | ||
1427 | #endif | ||
1428 | |||
1400 | static void ack_apic_edge(unsigned int irq) | 1429 | static void ack_apic_edge(unsigned int irq) |
1401 | { | 1430 | { |
1431 | irq_complete_move(irq); | ||
1402 | move_native_irq(irq); | 1432 | move_native_irq(irq); |
1403 | ack_APIC_irq(); | 1433 | ack_APIC_irq(); |
1404 | } | 1434 | } |
@@ -1407,6 +1437,7 @@ static void ack_apic_level(unsigned int irq) | |||
1407 | { | 1437 | { |
1408 | int do_unmask_irq = 0; | 1438 | int do_unmask_irq = 0; |
1409 | 1439 | ||
1440 | irq_complete_move(irq); | ||
1410 | #if defined(CONFIG_GENERIC_PENDING_IRQ) || defined(CONFIG_IRQBALANCE) | 1441 | #if defined(CONFIG_GENERIC_PENDING_IRQ) || defined(CONFIG_IRQBALANCE) |
1411 | /* If we are moving the irq we need to mask it */ | 1442 | /* If we are moving the irq we need to mask it */ |
1412 | if (unlikely(irq_desc[irq].status & IRQ_MOVE_PENDING)) { | 1443 | if (unlikely(irq_desc[irq].status & IRQ_MOVE_PENDING)) { |
@@ -1457,7 +1488,7 @@ static inline void init_IO_APIC_traps(void) | |||
1457 | */ | 1488 | */ |
1458 | for (irq = 0; irq < NR_IRQS ; irq++) { | 1489 | for (irq = 0; irq < NR_IRQS ; irq++) { |
1459 | int tmp = irq; | 1490 | int tmp = irq; |
1460 | if (IO_APIC_IRQ(tmp) && !irq_vector[tmp]) { | 1491 | if (IO_APIC_IRQ(tmp) && !irq_cfg[tmp].vector) { |
1461 | /* | 1492 | /* |
1462 | * Hmm.. We don't have an entry for this, | 1493 | * Hmm.. We don't have an entry for this, |
1463 | * so default to an old-fashioned 8259 | 1494 | * so default to an old-fashioned 8259 |
@@ -1596,15 +1627,14 @@ static inline void unlock_ExtINT_logic(void) | |||
1596 | */ | 1627 | */ |
1597 | static inline void check_timer(void) | 1628 | static inline void check_timer(void) |
1598 | { | 1629 | { |
1630 | struct irq_cfg *cfg = irq_cfg + 0; | ||
1599 | int apic1, pin1, apic2, pin2; | 1631 | int apic1, pin1, apic2, pin2; |
1600 | int vector; | ||
1601 | cpumask_t mask; | ||
1602 | 1632 | ||
1603 | /* | 1633 | /* |
1604 | * get/set the timer IRQ vector: | 1634 | * get/set the timer IRQ vector: |
1605 | */ | 1635 | */ |
1606 | disable_8259A_irq(0); | 1636 | disable_8259A_irq(0); |
1607 | vector = assign_irq_vector(0, TARGET_CPUS, &mask); | 1637 | assign_irq_vector(0, TARGET_CPUS); |
1608 | 1638 | ||
1609 | /* | 1639 | /* |
1610 | * Subtle, code in do_timer_interrupt() expects an AEOI | 1640 | * Subtle, code in do_timer_interrupt() expects an AEOI |
@@ -1624,7 +1654,7 @@ static inline void check_timer(void) | |||
1624 | apic2 = ioapic_i8259.apic; | 1654 | apic2 = ioapic_i8259.apic; |
1625 | 1655 | ||
1626 | apic_printk(APIC_VERBOSE,KERN_INFO "..TIMER: vector=0x%02X apic1=%d pin1=%d apic2=%d pin2=%d\n", | 1656 | apic_printk(APIC_VERBOSE,KERN_INFO "..TIMER: vector=0x%02X apic1=%d pin1=%d apic2=%d pin2=%d\n", |
1627 | vector, apic1, pin1, apic2, pin2); | 1657 | cfg->vector, apic1, pin1, apic2, pin2); |
1628 | 1658 | ||
1629 | if (pin1 != -1) { | 1659 | if (pin1 != -1) { |
1630 | /* | 1660 | /* |
@@ -1655,7 +1685,7 @@ static inline void check_timer(void) | |||
1655 | /* | 1685 | /* |
1656 | * legacy devices should be connected to IO APIC #0 | 1686 | * legacy devices should be connected to IO APIC #0 |
1657 | */ | 1687 | */ |
1658 | setup_ExtINT_IRQ0_pin(apic2, pin2, vector); | 1688 | setup_ExtINT_IRQ0_pin(apic2, pin2, cfg->vector); |
1659 | if (timer_irq_works()) { | 1689 | if (timer_irq_works()) { |
1660 | apic_printk(APIC_VERBOSE," works.\n"); | 1690 | apic_printk(APIC_VERBOSE," works.\n"); |
1661 | nmi_watchdog_default(); | 1691 | nmi_watchdog_default(); |
@@ -1680,14 +1710,14 @@ static inline void check_timer(void) | |||
1680 | 1710 | ||
1681 | disable_8259A_irq(0); | 1711 | disable_8259A_irq(0); |
1682 | irq_desc[0].chip = &lapic_irq_type; | 1712 | irq_desc[0].chip = &lapic_irq_type; |
1683 | apic_write(APIC_LVT0, APIC_DM_FIXED | vector); /* Fixed mode */ | 1713 | apic_write(APIC_LVT0, APIC_DM_FIXED | cfg->vector); /* Fixed mode */ |
1684 | enable_8259A_irq(0); | 1714 | enable_8259A_irq(0); |
1685 | 1715 | ||
1686 | if (timer_irq_works()) { | 1716 | if (timer_irq_works()) { |
1687 | apic_printk(APIC_VERBOSE," works.\n"); | 1717 | apic_printk(APIC_VERBOSE," works.\n"); |
1688 | return; | 1718 | return; |
1689 | } | 1719 | } |
1690 | apic_write(APIC_LVT0, APIC_LVT_MASKED | APIC_DM_FIXED | vector); | 1720 | apic_write(APIC_LVT0, APIC_LVT_MASKED | APIC_DM_FIXED | cfg->vector); |
1691 | apic_printk(APIC_VERBOSE," failed.\n"); | 1721 | apic_printk(APIC_VERBOSE," failed.\n"); |
1692 | 1722 | ||
1693 | apic_printk(APIC_VERBOSE, KERN_INFO "...trying to set up timer as ExtINT IRQ..."); | 1723 | apic_printk(APIC_VERBOSE, KERN_INFO "...trying to set up timer as ExtINT IRQ..."); |
@@ -1834,19 +1864,16 @@ int create_irq(void) | |||
1834 | /* Allocate an unused irq */ | 1864 | /* Allocate an unused irq */ |
1835 | int irq; | 1865 | int irq; |
1836 | int new; | 1866 | int new; |
1837 | int vector = 0; | ||
1838 | unsigned long flags; | 1867 | unsigned long flags; |
1839 | cpumask_t mask; | ||
1840 | 1868 | ||
1841 | irq = -ENOSPC; | 1869 | irq = -ENOSPC; |
1842 | spin_lock_irqsave(&vector_lock, flags); | 1870 | spin_lock_irqsave(&vector_lock, flags); |
1843 | for (new = (NR_IRQS - 1); new >= 0; new--) { | 1871 | for (new = (NR_IRQS - 1); new >= 0; new--) { |
1844 | if (platform_legacy_irq(new)) | 1872 | if (platform_legacy_irq(new)) |
1845 | continue; | 1873 | continue; |
1846 | if (irq_vector[new] != 0) | 1874 | if (irq_cfg[new].vector != 0) |
1847 | continue; | 1875 | continue; |
1848 | vector = __assign_irq_vector(new, TARGET_CPUS, &mask); | 1876 | if (__assign_irq_vector(new, TARGET_CPUS) == 0) |
1849 | if (likely(vector > 0)) | ||
1850 | irq = new; | 1877 | irq = new; |
1851 | break; | 1878 | break; |
1852 | } | 1879 | } |
@@ -1875,12 +1902,15 @@ void destroy_irq(unsigned int irq) | |||
1875 | #ifdef CONFIG_PCI_MSI | 1902 | #ifdef CONFIG_PCI_MSI |
1876 | static int msi_compose_msg(struct pci_dev *pdev, unsigned int irq, struct msi_msg *msg) | 1903 | static int msi_compose_msg(struct pci_dev *pdev, unsigned int irq, struct msi_msg *msg) |
1877 | { | 1904 | { |
1878 | int vector; | 1905 | struct irq_cfg *cfg = irq_cfg + irq; |
1906 | int err; | ||
1879 | unsigned dest; | 1907 | unsigned dest; |
1880 | cpumask_t tmp; | 1908 | cpumask_t tmp; |
1881 | 1909 | ||
1882 | vector = assign_irq_vector(irq, TARGET_CPUS, &tmp); | 1910 | tmp = TARGET_CPUS; |
1883 | if (vector >= 0) { | 1911 | err = assign_irq_vector(irq, tmp); |
1912 | if (!err) { | ||
1913 | cpus_and(tmp, cfg->domain, tmp); | ||
1884 | dest = cpu_mask_to_apicid(tmp); | 1914 | dest = cpu_mask_to_apicid(tmp); |
1885 | 1915 | ||
1886 | msg->address_hi = MSI_ADDR_BASE_HI; | 1916 | msg->address_hi = MSI_ADDR_BASE_HI; |
@@ -1900,40 +1930,38 @@ static int msi_compose_msg(struct pci_dev *pdev, unsigned int irq, struct msi_ms | |||
1900 | ((INT_DELIVERY_MODE != dest_LowestPrio) ? | 1930 | ((INT_DELIVERY_MODE != dest_LowestPrio) ? |
1901 | MSI_DATA_DELIVERY_FIXED: | 1931 | MSI_DATA_DELIVERY_FIXED: |
1902 | MSI_DATA_DELIVERY_LOWPRI) | | 1932 | MSI_DATA_DELIVERY_LOWPRI) | |
1903 | MSI_DATA_VECTOR(vector); | 1933 | MSI_DATA_VECTOR(cfg->vector); |
1904 | } | 1934 | } |
1905 | return vector; | 1935 | return err; |
1906 | } | 1936 | } |
1907 | 1937 | ||
1908 | #ifdef CONFIG_SMP | 1938 | #ifdef CONFIG_SMP |
1909 | static void set_msi_irq_affinity(unsigned int irq, cpumask_t mask) | 1939 | static void set_msi_irq_affinity(unsigned int irq, cpumask_t mask) |
1910 | { | 1940 | { |
1941 | struct irq_cfg *cfg = irq_cfg + irq; | ||
1911 | struct msi_msg msg; | 1942 | struct msi_msg msg; |
1912 | unsigned int dest; | 1943 | unsigned int dest; |
1913 | cpumask_t tmp; | 1944 | cpumask_t tmp; |
1914 | int vector; | ||
1915 | 1945 | ||
1916 | cpus_and(tmp, mask, cpu_online_map); | 1946 | cpus_and(tmp, mask, cpu_online_map); |
1917 | if (cpus_empty(tmp)) | 1947 | if (cpus_empty(tmp)) |
1918 | tmp = TARGET_CPUS; | 1948 | return; |
1919 | |||
1920 | cpus_and(mask, tmp, CPU_MASK_ALL); | ||
1921 | 1949 | ||
1922 | vector = assign_irq_vector(irq, mask, &tmp); | 1950 | if (assign_irq_vector(irq, mask)) |
1923 | if (vector < 0) | ||
1924 | return; | 1951 | return; |
1925 | 1952 | ||
1953 | cpus_and(tmp, cfg->domain, mask); | ||
1926 | dest = cpu_mask_to_apicid(tmp); | 1954 | dest = cpu_mask_to_apicid(tmp); |
1927 | 1955 | ||
1928 | read_msi_msg(irq, &msg); | 1956 | read_msi_msg(irq, &msg); |
1929 | 1957 | ||
1930 | msg.data &= ~MSI_DATA_VECTOR_MASK; | 1958 | msg.data &= ~MSI_DATA_VECTOR_MASK; |
1931 | msg.data |= MSI_DATA_VECTOR(vector); | 1959 | msg.data |= MSI_DATA_VECTOR(cfg->vector); |
1932 | msg.address_lo &= ~MSI_ADDR_DEST_ID_MASK; | 1960 | msg.address_lo &= ~MSI_ADDR_DEST_ID_MASK; |
1933 | msg.address_lo |= MSI_ADDR_DEST_ID(dest); | 1961 | msg.address_lo |= MSI_ADDR_DEST_ID(dest); |
1934 | 1962 | ||
1935 | write_msi_msg(irq, &msg); | 1963 | write_msi_msg(irq, &msg); |
1936 | set_native_irq_info(irq, mask); | 1964 | irq_desc[irq].affinity = mask; |
1937 | } | 1965 | } |
1938 | #endif /* CONFIG_SMP */ | 1966 | #endif /* CONFIG_SMP */ |
1939 | 1967 | ||
@@ -2004,24 +2032,22 @@ static void target_ht_irq(unsigned int irq, unsigned int dest, u8 vector) | |||
2004 | 2032 | ||
2005 | static void set_ht_irq_affinity(unsigned int irq, cpumask_t mask) | 2033 | static void set_ht_irq_affinity(unsigned int irq, cpumask_t mask) |
2006 | { | 2034 | { |
2035 | struct irq_cfg *cfg = irq_cfg + irq; | ||
2007 | unsigned int dest; | 2036 | unsigned int dest; |
2008 | cpumask_t tmp; | 2037 | cpumask_t tmp; |
2009 | int vector; | ||
2010 | 2038 | ||
2011 | cpus_and(tmp, mask, cpu_online_map); | 2039 | cpus_and(tmp, mask, cpu_online_map); |
2012 | if (cpus_empty(tmp)) | 2040 | if (cpus_empty(tmp)) |
2013 | tmp = TARGET_CPUS; | 2041 | return; |
2014 | |||
2015 | cpus_and(mask, tmp, CPU_MASK_ALL); | ||
2016 | 2042 | ||
2017 | vector = assign_irq_vector(irq, mask, &tmp); | 2043 | if (assign_irq_vector(irq, mask)) |
2018 | if (vector < 0) | ||
2019 | return; | 2044 | return; |
2020 | 2045 | ||
2046 | cpus_and(tmp, cfg->domain, mask); | ||
2021 | dest = cpu_mask_to_apicid(tmp); | 2047 | dest = cpu_mask_to_apicid(tmp); |
2022 | 2048 | ||
2023 | target_ht_irq(irq, dest, vector); | 2049 | target_ht_irq(irq, dest, cfg->vector); |
2024 | set_native_irq_info(irq, mask); | 2050 | irq_desc[irq].affinity = mask; |
2025 | } | 2051 | } |
2026 | #endif | 2052 | #endif |
2027 | 2053 | ||
@@ -2038,14 +2064,17 @@ static struct irq_chip ht_irq_chip = { | |||
2038 | 2064 | ||
2039 | int arch_setup_ht_irq(unsigned int irq, struct pci_dev *dev) | 2065 | int arch_setup_ht_irq(unsigned int irq, struct pci_dev *dev) |
2040 | { | 2066 | { |
2041 | int vector; | 2067 | struct irq_cfg *cfg = irq_cfg + irq; |
2068 | int err; | ||
2042 | cpumask_t tmp; | 2069 | cpumask_t tmp; |
2043 | 2070 | ||
2044 | vector = assign_irq_vector(irq, TARGET_CPUS, &tmp); | 2071 | tmp = TARGET_CPUS; |
2045 | if (vector >= 0) { | 2072 | err = assign_irq_vector(irq, tmp); |
2073 | if (!err) { | ||
2046 | struct ht_irq_msg msg; | 2074 | struct ht_irq_msg msg; |
2047 | unsigned dest; | 2075 | unsigned dest; |
2048 | 2076 | ||
2077 | cpus_and(tmp, cfg->domain, tmp); | ||
2049 | dest = cpu_mask_to_apicid(tmp); | 2078 | dest = cpu_mask_to_apicid(tmp); |
2050 | 2079 | ||
2051 | msg.address_hi = HT_IRQ_HIGH_DEST_ID(dest); | 2080 | msg.address_hi = HT_IRQ_HIGH_DEST_ID(dest); |
@@ -2053,7 +2082,7 @@ int arch_setup_ht_irq(unsigned int irq, struct pci_dev *dev) | |||
2053 | msg.address_lo = | 2082 | msg.address_lo = |
2054 | HT_IRQ_LOW_BASE | | 2083 | HT_IRQ_LOW_BASE | |
2055 | HT_IRQ_LOW_DEST_ID(dest) | | 2084 | HT_IRQ_LOW_DEST_ID(dest) | |
2056 | HT_IRQ_LOW_VECTOR(vector) | | 2085 | HT_IRQ_LOW_VECTOR(cfg->vector) | |
2057 | ((INT_DEST_MODE == 0) ? | 2086 | ((INT_DEST_MODE == 0) ? |
2058 | HT_IRQ_LOW_DM_PHYSICAL : | 2087 | HT_IRQ_LOW_DM_PHYSICAL : |
2059 | HT_IRQ_LOW_DM_LOGICAL) | | 2088 | HT_IRQ_LOW_DM_LOGICAL) | |
@@ -2068,7 +2097,7 @@ int arch_setup_ht_irq(unsigned int irq, struct pci_dev *dev) | |||
2068 | set_irq_chip_and_handler_name(irq, &ht_irq_chip, | 2097 | set_irq_chip_and_handler_name(irq, &ht_irq_chip, |
2069 | handle_edge_irq, "edge"); | 2098 | handle_edge_irq, "edge"); |
2070 | } | 2099 | } |
2071 | return vector; | 2100 | return err; |
2072 | } | 2101 | } |
2073 | #endif /* CONFIG_HT_IRQ */ | 2102 | #endif /* CONFIG_HT_IRQ */ |
2074 | 2103 | ||
@@ -2095,11 +2124,6 @@ int __init io_apic_get_redir_entries (int ioapic) | |||
2095 | 2124 | ||
2096 | int io_apic_set_pci_routing (int ioapic, int pin, int irq, int triggering, int polarity) | 2125 | int io_apic_set_pci_routing (int ioapic, int pin, int irq, int triggering, int polarity) |
2097 | { | 2126 | { |
2098 | struct IO_APIC_route_entry entry; | ||
2099 | unsigned long flags; | ||
2100 | int vector; | ||
2101 | cpumask_t mask; | ||
2102 | |||
2103 | if (!IO_APIC_IRQ(irq)) { | 2127 | if (!IO_APIC_IRQ(irq)) { |
2104 | apic_printk(APIC_QUIET,KERN_ERR "IOAPIC[%d]: Invalid reference to IRQ 0\n", | 2128 | apic_printk(APIC_QUIET,KERN_ERR "IOAPIC[%d]: Invalid reference to IRQ 0\n", |
2105 | ioapic); | 2129 | ioapic); |
@@ -2112,42 +2136,7 @@ int io_apic_set_pci_routing (int ioapic, int pin, int irq, int triggering, int p | |||
2112 | if (irq >= 16) | 2136 | if (irq >= 16) |
2113 | add_pin_to_irq(irq, ioapic, pin); | 2137 | add_pin_to_irq(irq, ioapic, pin); |
2114 | 2138 | ||
2115 | 2139 | setup_IO_APIC_irq(ioapic, pin, irq, triggering, polarity); | |
2116 | vector = assign_irq_vector(irq, TARGET_CPUS, &mask); | ||
2117 | if (vector < 0) | ||
2118 | return vector; | ||
2119 | |||
2120 | /* | ||
2121 | * Generate a PCI IRQ routing entry and program the IOAPIC accordingly. | ||
2122 | * Note that we mask (disable) IRQs now -- these get enabled when the | ||
2123 | * corresponding device driver registers for this IRQ. | ||
2124 | */ | ||
2125 | |||
2126 | memset(&entry,0,sizeof(entry)); | ||
2127 | |||
2128 | entry.delivery_mode = INT_DELIVERY_MODE; | ||
2129 | entry.dest_mode = INT_DEST_MODE; | ||
2130 | entry.dest = cpu_mask_to_apicid(mask); | ||
2131 | entry.trigger = triggering; | ||
2132 | entry.polarity = polarity; | ||
2133 | entry.mask = 1; /* Disabled (masked) */ | ||
2134 | entry.vector = vector & 0xff; | ||
2135 | |||
2136 | apic_printk(APIC_VERBOSE,KERN_DEBUG "IOAPIC[%d]: Set PCI routing entry (%d-%d -> 0x%x -> " | ||
2137 | "IRQ %d Mode:%i Active:%i)\n", ioapic, | ||
2138 | mp_ioapics[ioapic].mpc_apicid, pin, entry.vector, irq, | ||
2139 | triggering, polarity); | ||
2140 | |||
2141 | ioapic_register_intr(irq, entry.vector, triggering); | ||
2142 | |||
2143 | if (!ioapic && (irq < 16)) | ||
2144 | disable_8259A_irq(irq); | ||
2145 | |||
2146 | ioapic_write_entry(ioapic, pin, entry); | ||
2147 | |||
2148 | spin_lock_irqsave(&ioapic_lock, flags); | ||
2149 | set_native_irq_info(irq, TARGET_CPUS); | ||
2150 | spin_unlock_irqrestore(&ioapic_lock, flags); | ||
2151 | 2140 | ||
2152 | return 0; | 2141 | return 0; |
2153 | } | 2142 | } |
@@ -2179,8 +2168,10 @@ void __init setup_ioapic_dest(void) | |||
2179 | * when you have too many devices, because at that time only boot | 2168 | * when you have too many devices, because at that time only boot |
2180 | * cpu is online. | 2169 | * cpu is online. |
2181 | */ | 2170 | */ |
2182 | if(!irq_vector[irq]) | 2171 | if (!irq_cfg[irq].vector) |
2183 | setup_IO_APIC_irq(ioapic, pin, irq_entry, irq); | 2172 | setup_IO_APIC_irq(ioapic, pin, irq, |
2173 | irq_trigger(irq_entry), | ||
2174 | irq_polarity(irq_entry)); | ||
2184 | else | 2175 | else |
2185 | set_ioapic_affinity_irq(irq, TARGET_CPUS); | 2176 | set_ioapic_affinity_irq(irq, TARGET_CPUS); |
2186 | } | 2177 | } |