From dbebb4cbe02dc811e21bd3bc40a252490e46b949 Mon Sep 17 00:00:00 2001 From: Russell King Date: Tue, 8 Nov 2005 10:40:10 +0000 Subject: [ARM SMP] Add missing SMP timer handling for realview Until we have local timer support, we need to broadcast the timer interrupt to the other CPUs. Also, add the missing smp_send_timer() prototype to asm/smp.h Signed-off-by: Russell King --- include/asm-arm/smp.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include') diff --git a/include/asm-arm/smp.h b/include/asm-arm/smp.h index 551cd3c3093c..21d1723c03e1 100644 --- a/include/asm-arm/smp.h +++ b/include/asm-arm/smp.h @@ -46,6 +46,11 @@ extern void smp_store_cpu_info(unsigned int cpuid); */ extern void smp_cross_call(cpumask_t callmap); +/* + * Broadcast a timer interrupt to the other CPUs. + */ +extern void smp_send_timer(void); + /* * Boot a secondary CPU, and assign it the specified idle task. * This also gives us the initial stack to use for this CPU. -- cgit v1.2.2 From 3b6353fae0d7ba772d7eb2651727332c9e9c74ac Mon Sep 17 00:00:00 2001 From: Russell King Date: Tue, 8 Nov 2005 15:35:23 +0000 Subject: [ARM] Declare asm entry points in asm/smp.h Signed-off-by: Russell King --- include/asm-arm/smp.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'include') diff --git a/include/asm-arm/smp.h b/include/asm-arm/smp.h index 21d1723c03e1..52e7c8d830b2 100644 --- a/include/asm-arm/smp.h +++ b/include/asm-arm/smp.h @@ -36,6 +36,11 @@ struct seq_file; */ extern void show_ipi_list(struct seq_file *p); +/* + * Called from assembly code, this handles an IPI. + */ +asmlinkage void do_IPI(struct pt_regs *regs); + /* * Move global data into per-processor storage. */ @@ -57,6 +62,12 @@ extern void smp_send_timer(void); */ extern int boot_secondary(unsigned int cpu, struct task_struct *); +/* + * Called from platform specific assembly code, this is the + * secondary CPU entry point. + */ +asmlinkage void secondary_start_kernel(void); + /* * Perform platform specific initialisation of the specified CPU. */ -- cgit v1.2.2 From 37ee16ae93a3e4ae7dd51beb81d249f5f12a55c2 Mon Sep 17 00:00:00 2001 From: Russell King Date: Tue, 8 Nov 2005 19:08:05 +0000 Subject: [ARM SMP] Add core ARM support for local timers Add infrastructure for supporting per-cpu local timers to update the profiling information and update system time accounting. Signed-off-by: Russell King --- include/asm-arm/hardirq.h | 1 + include/asm-arm/smp.h | 38 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+) (limited to 'include') diff --git a/include/asm-arm/hardirq.h b/include/asm-arm/hardirq.h index e5ccb6b8ff83..1cbb173bf5b1 100644 --- a/include/asm-arm/hardirq.h +++ b/include/asm-arm/hardirq.h @@ -8,6 +8,7 @@ typedef struct { unsigned int __softirq_pending; + unsigned int local_timer_irqs; } ____cacheline_aligned irq_cpustat_t; #include /* Standard mappings for irq_cpustat_t above */ diff --git a/include/asm-arm/smp.h b/include/asm-arm/smp.h index 52e7c8d830b2..5a72e50ca9fc 100644 --- a/include/asm-arm/smp.h +++ b/include/asm-arm/smp.h @@ -92,4 +92,42 @@ extern void platform_cpu_die(unsigned int cpu); extern int platform_cpu_kill(unsigned int cpu); extern void platform_cpu_enable(unsigned int cpu); +#ifdef CONFIG_LOCAL_TIMERS +/* + * Setup a local timer interrupt for a CPU. + */ +extern void local_timer_setup(unsigned int cpu); + +/* + * Stop a local timer interrupt. + */ +extern void local_timer_stop(unsigned int cpu); + +/* + * Platform provides this to acknowledge a local timer IRQ + */ +extern int local_timer_ack(void); + +#else + +static inline void local_timer_setup(unsigned int cpu) +{ +} + +static inline void local_timer_stop(unsigned int cpu) +{ +} + +#endif + +/* + * show local interrupt info + */ +extern void show_local_irqs(struct seq_file *); + +/* + * Called from assembly, this is the local timer IRQ handler + */ +asmlinkage void do_local_timer(struct pt_regs *); + #endif /* ifndef __ASM_ARM_SMP_H */ -- cgit v1.2.2 From a63ae4427c6af66d6eda26e5da8fed53f8fbede3 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Tue, 8 Nov 2005 19:15:43 +0000 Subject: [ARM] 3093/1: SharpSL PCMCIA Updates for Cxx00 models Patch from Richard Purdie The Sharp SL-Cxx00 models have a combined power control for the SD and CF slot 0. This patch adds hooks to the scoop driver to allow machines to provide a custom control function for this and such a function is added for spitz/akita/borzoi. It also moves the gpio init code into the machine files as this is machine dependent and differs between some models. A couple of warnings when compiling for collie are also fixed. Signed-off-by: Richard Purdie Signed-off-by: Russell King --- include/asm-arm/hardware/scoop.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/asm-arm/hardware/scoop.h b/include/asm-arm/hardware/scoop.h index a8f1013930e3..d37bf7443264 100644 --- a/include/asm-arm/hardware/scoop.h +++ b/include/asm-arm/hardware/scoop.h @@ -52,8 +52,14 @@ struct scoop_pcmcia_dev { unsigned char keep_rd; }; -extern int scoop_num; -extern struct scoop_pcmcia_dev *scoop_devs; +struct scoop_pcmcia_config { + struct scoop_pcmcia_dev *devs; + int num_devs; + void (*pcmcia_init)(void); + void (*power_ctrl)(struct device *scoop, unsigned short cpr, int nr); +}; + +extern struct scoop_pcmcia_config *platform_scoop_config; void reset_scoop(struct device *dev); unsigned short set_scoop_gpio(struct device *dev, unsigned short bit); -- cgit v1.2.2 From f8c905d368c757e2c96db293a472a31abcf4b147 Mon Sep 17 00:00:00 2001 From: Ben Dooks Date: Tue, 8 Nov 2005 22:43:05 +0000 Subject: [ARM] 3132/1: S3C2410 - reset on decompression error Patch from Ben Dooks Force a watchdog reset if the system fails to decompress properly. Signed-off-by: Ben Dooks Signed-off-by: Russell King --- include/asm-arm/arch-s3c2410/uncompress.h | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/asm-arm/arch-s3c2410/uncompress.h b/include/asm-arm/arch-s3c2410/uncompress.h index d7a4a8354fa9..ddd1578a7ee0 100644 --- a/include/asm-arm/arch-s3c2410/uncompress.h +++ b/include/asm-arm/arch-s3c2410/uncompress.h @@ -116,6 +116,8 @@ putstr(const char *ptr) } } +#define __raw_writel(d,ad) do { *((volatile unsigned int *)(ad)) = (d); } while(0) + /* CONFIG_S3C2410_BOOT_WATCHDOG * * Simple boot-time watchdog setup, to reboot the system if there is @@ -126,8 +128,6 @@ putstr(const char *ptr) #define WDOG_COUNT (0xff00) -#define __raw_writel(d,ad) do { *((volatile unsigned int *)(ad)) = (d); } while(0) - static inline void arch_decomp_wdog(void) { __raw_writel(WDOG_COUNT, S3C2410_WTCNT); @@ -145,6 +145,24 @@ static void arch_decomp_wdog_start(void) #define arch_decomp_wdog() #endif +#ifdef CONFIG_S3C2410_BOOT_ERROR_RESET + +static void arch_decomp_error(const char *x) +{ + putstr("\n\n"); + putstr(x); + putstr("\n\n -- System resetting\n"); + + __raw_writel(0x4000, S3C2410_WTDAT); + __raw_writel(0x4000, S3C2410_WTCNT); + __raw_writel(S3C2410_WTCON_ENABLE | S3C2410_WTCON_DIV128 | S3C2410_WTCON_RSTEN | S3C2410_WTCON_PRESCALE(0x40), S3C2410_WTCON); + + while(1); +} + +#define arch_error arch_decomp_error +#endif + static void error(char *err); static void -- cgit v1.2.2