Commit c7f7ff17 authored by Russell King's avatar Russell King Committed by Russell King
Browse files

Merge branch 'smp' into devel

parents a22f277b e03cdade
Loading
Loading
Loading
Loading
+15 −0
Original line number Diff line number Diff line
@@ -844,7 +844,9 @@ source "kernel/time/Kconfig"
config SMP
	bool "Symmetric Multi-Processing (EXPERIMENTAL)"
	depends on EXPERIMENTAL && (REALVIEW_EB_ARM11MP || MACH_REALVIEW_PB11MP)
	depends on GENERIC_CLOCKEVENTS
	select USE_GENERIC_SMP_HELPERS
	select HAVE_ARM_SCU if ARCH_REALVIEW
	help
	  This enables support for systems with more than one CPU. If you have
	  a system with only one CPU, like most personal computers, say N. If
@@ -862,6 +864,18 @@ config SMP

	  If you don't know what to do here, say N.

config HAVE_ARM_SCU
	bool
	depends on SMP
	help
	  This option enables support for the ARM system coherency unit

config HAVE_ARM_TWD
	bool
	depends on SMP
	help
	  This options enables support for the ARM timer and watchdog unit

choice
	prompt "Memory split"
	default VMSPLIT_3G
@@ -902,6 +916,7 @@ config LOCAL_TIMERS
	bool "Use local timer interrupts"
	depends on SMP && (REALVIEW_EB_ARM11MP || MACH_REALVIEW_PB11MP || REALVIEW_EB_A9MP)
	default y
	select HAVE_ARM_TWD if ARCH_REALVIEW
	help
	  Enable support for local timers on SMP platforms, rather then the
	  legacy IPI broadcast method.  Local timers allows the system
+0 −21
Original line number Diff line number Diff line
#ifndef __ASM_HARDWARE_TWD_H
#define __ASM_HARDWARE_TWD_H

#define TWD_TIMER_LOAD 			0x00
#define TWD_TIMER_COUNTER		0x04
#define TWD_TIMER_CONTROL		0x08
#define TWD_TIMER_INTSTAT		0x0C

#define TWD_WDOG_LOAD			0x20
#define TWD_WDOG_COUNTER		0x24
#define TWD_WDOG_CONTROL		0x28
#define TWD_WDOG_INTSTAT		0x2C
#define TWD_WDOG_RESETSTAT		0x30
#define TWD_WDOG_DISABLE		0x34

#define TWD_TIMER_CONTROL_ENABLE	(1 << 0)
#define TWD_TIMER_CONTROL_ONESHOT	(0 << 1)
#define TWD_TIMER_CONTROL_PERIODIC	(1 << 1)
#define TWD_TIMER_CONTROL_IT_ENABLE	(1 << 2)

#endif
+63 −0
Original line number Diff line number Diff line
/*
 *  arch/arm/include/asm/localtimer.h
 *
 *  Copyright (C) 2004-2005 ARM Ltd.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation.
 */
#ifndef __ASM_ARM_LOCALTIMER_H
#define __ASM_ARM_LOCALTIMER_H

struct clock_event_device;

/*
 * Setup a per-cpu timer, whether it be a local timer or dummy broadcast
 */
void percpu_timer_setup(void);

/*
 * Called from assembly, this is the local timer IRQ handler
 */
asmlinkage void do_local_timer(struct pt_regs *);


#ifdef CONFIG_LOCAL_TIMERS

#ifdef CONFIG_HAVE_ARM_TWD

#include "smp_twd.h"

#define local_timer_ack()	twd_timer_ack()
#define local_timer_stop()	twd_timer_stop()

#else

/*
 * Platform provides this to acknowledge a local timer IRQ.
 * Returns true if the local timer IRQ is to be processed.
 */
int local_timer_ack(void);

/*
 * Stop a local timer interrupt.
 */
void local_timer_stop(void);

#endif

/*
 * Setup a local timer interrupt for a CPU.
 */
void local_timer_setup(struct clock_event_device *);

#else

static inline void local_timer_stop(void)
{
}

#endif

#endif
+1 −41
Original line number Diff line number Diff line
@@ -41,7 +41,7 @@ extern void show_ipi_list(struct seq_file *p);
asmlinkage void do_IPI(struct pt_regs *regs);

/*
 * Setup the SMP cpu_possible_map
 * Setup the set of possible CPUs (via set_cpu_possible)
 */
extern void smp_init_cpus(void);

@@ -55,11 +55,6 @@ extern void smp_store_cpu_info(unsigned int cpuid);
 */
extern void smp_cross_call(const struct cpumask *mask);

/*
 * Broadcast a clock event to other CPUs.
 */
extern void smp_timer_broadcast(const struct cpumask *mask);

/*
 * Boot a secondary CPU, and assign it the specified idle task.
 * This also gives us the initial stack to use for this CPU.
@@ -100,44 +95,9 @@ extern void arch_send_call_function_single_ipi(int cpu);
extern void arch_send_call_function_ipi_mask(const struct cpumask *mask);
#define arch_send_call_function_ipi_mask arch_send_call_function_ipi_mask

/*
 * Local timer interrupt handling function (can be IPI'ed).
 */
extern void local_timer_interrupt(void);

#ifdef CONFIG_LOCAL_TIMERS

/*
 * Stop a local timer interrupt.
 */
extern void local_timer_stop(void);

/*
 * Platform provides this to acknowledge a local timer IRQ
 */
extern int local_timer_ack(void);

#else

static inline void local_timer_stop(void)
{
}

#endif

/*
 * Setup a local timer interrupt for a CPU.
 */
extern void local_timer_setup(void);

/*
 * 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 */
+7 −0
Original line number Diff line number Diff line
#ifndef __ASMARM_ARCH_SCU_H
#define __ASMARM_ARCH_SCU_H

unsigned int scu_get_core_count(void __iomem *);
void scu_enable(void __iomem *);

#endif
Loading