summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* ARM: 7139/1: fix compilation with CONFIG_ARM_ATAG_DTB_COMPAT and large ↵Nicolas Pitre2011-10-241-1/+2
| | | | | | | | | | | | TEXT_OFFSET If TEXT_OFFSET is too large (e.g. like on MSM) the resulting immediate argument gets wider than 8 bits. Noticed by David Brown <davidb@codeaurora.org> Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* Merge branch 'ppi-irq-core-for-rmk' of ↵Russell King2011-10-2346-307/+829
|\ | | | | | | git://github.com/mzyngier/arm-platforms into devel-stable
| * ARM: gic, local timers: use the request_percpu_irq() interfaceMarc Zyngier2011-10-238-111/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch remove the hardcoded link between local timers and PPIs, and convert the PPI users (TWD, MCT and MSM timers) to the new *_percpu_irq interface. Also some collateral cleanup (local_timer_ack() is gone, and the interrupt handler is strictly private to each driver). PPIs are now useable for more than just the local timers. Additional testing by David Brown (msm8250 and msm8660) and Shawn Guo (imx6q). Cc: David Brown <davidb@codeaurora.org> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Brown <davidb@codeaurora.org> Tested-by: David Brown <davidb@codeaurora.org> Tested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
| * ARM: gic: consolidate PPI handlingMarc Zyngier2011-10-2314-178/+88
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PPI handling is a bit of an odd beast. It uses its own low level handling code and is hardwired to the local timers (hence lacking a registration interface). Instead, switch the low handling to the normal SPI handling code. PPIs are handled by the handle_percpu_devid_irq flow. This also allows the removal of some duplicated code. Cc: Kukjin Kim <kgene.kim@samsung.com> Cc: David Brown <davidb@codeaurora.org> Cc: Bryan Huntsman <bryanh@codeaurora.org> Cc: Tony Lindgren <tony@atomide.com> Cc: Paul Mundt <lethal@linux-sh.org> Cc: Magnus Damm <magnus.damm@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Brown <davidb@codeaurora.org> Tested-by: David Brown <davidb@codeaurora.org> Tested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
| * Merge commit '32cffdd' into ppi-irq-core-for-rmkMarc Zyngier2011-10-238-35/+364
| |\
| | * genirq: Fix fatfinered fixup reallyThomas Gleixner2011-10-041-1/+1
| | | | | | | | | | | | | | | | | | Putting the argument inside the quote does not really help. Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| | * genirq: percpu: allow interrupt type to be set at enable timeMarc Zyngier2011-10-032-2/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As request_percpu_irq() doesn't allow for a percpu interrupt to have its type configured (it is generally impossible to configure it on all CPUs at once), add a 'type' argument to enable_percpu_irq(). This allows some low-level, board specific init code to be switched to a generic API. [ tglx: Added WARN_ON argument ] Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Cc: Abhijeet Dharmapurikar <adharmap@codeaurora.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| | * genirq: Add support for per-cpu dev_id interruptsMarc Zyngier2011-10-038-34/+345
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The ARM GIC interrupt controller offers per CPU interrupts (PPIs), which are usually used to connect local timers to each core. Each CPU has its own private interface to the GIC, and only sees the PPIs that are directly connect to it. While these timers are separate devices and have a separate interrupt line to a core, they all use the same IRQ number. For these devices, request_irq() is not the right API as it assumes that an IRQ number is visible by a number of CPUs (through the affinity setting), but makes it very awkward to express that an IRQ number can be handled by all CPUs, and yet be a different interrupt line on each CPU, requiring a different dev_id cookie to be passed back to the handler. The *_percpu_irq() functions is designed to overcome these limitations, by providing a per-cpu dev_id vector: int request_percpu_irq(unsigned int irq, irq_handler_t handler, const char *devname, void __percpu *percpu_dev_id); void free_percpu_irq(unsigned int, void __percpu *); int setup_percpu_irq(unsigned int irq, struct irqaction *new); void remove_percpu_irq(unsigned int irq, struct irqaction *act); void enable_percpu_irq(unsigned int irq); void disable_percpu_irq(unsigned int irq); The API has a number of limitations: - no interrupt sharing - no threading - common handler across all the CPUs Once the interrupt is requested using setup_percpu_irq() or request_percpu_irq(), it must be enabled by each core that wishes its local interrupt to be delivered. Based on an initial patch by Thomas Gleixner. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Cc: linux-arm-kernel@lists.infradead.org Link: http://lkml.kernel.org/r/1316793788-14500-2-git-send-email-marc.zyngier@arm.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| | * genirq: Add IRQCHIP_SKIP_SET_WAKE flagSantosh Shilimkar2011-09-122-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some irq chips need the irq_set_wake() functionality, but do not require a irq_set_wake() callback. Instead of forcing an empty callback to be implemented add a flag which notes this fact. Check for the flag in set_irq_wake_real() and return success when set. Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Cc: Thomas Gleixner <tglx@linutronix.de>
| | * genirq: Make irq_shutdown() symmetric vs. irq_startup againGeert Uytterhoeven2011-09-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If an irq_chip provides .irq_shutdown(), but neither of .irq_disable() or .irq_mask(), free_irq() crashes when jumping to NULL. Fix this by only trying .irq_disable() and .irq_mask() if there's no .irq_shutdown() provided. This revives the symmetry with irq_startup(), which tries .irq_startup(), .irq_enable(), and irq_unmask(), and makes it consistent with the comment for irq_chip.irq_shutdown() in <linux/irq.h>, which says: * @irq_shutdown: shut down the interrupt (defaults to ->disable if NULL) This is also how __free_irq() behaved before the big overhaul, cfr. e.g. 3b56f0585fd4c02d047dc406668cb40159b2d340 ("genirq: Remove bogus conditional"), where the core interrupt code always overrode .irq_shutdown() to .irq_disable() if .irq_shutdown() was NULL. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: linux-m68k@lists.linux-m68k.org Link: http://lkml.kernel.org/r/1315742394-16036-2-git-send-email-geert@linux-m68k.org Cc: stable@kernel.org Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * | ARM: smp: fix clipping of number of CPUsRussell King2011-10-208-28/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rather than clipping the number of CPUs using the compile-time NR_CPUS constant, use the runtime nr_cpu_ids value instead. This allows the nr_cpus command line option to work as expected. Cc: <stable@kernel.org> Reported-by: Mark Salter <msalter@redhat.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * | ARM: 7115/4: move __exception and friends to asm/exception.hJamie Iles2011-10-177-9/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The definition of __exception_irq_entry for CONFIG_FUNCTION_GRAPH_TRACER=y needs linux/ftrace.h, but this creates a circular dependency with it's current home in asm/system.h. Create asm/exception.h and update all current users. v4: - rebase to rmk/for-next v3: - remove redundant includes of linux/ftrace.h v2: - document the usage restricitions of __exception* Cc: Zoltan Devai <zdevai@gmail.com> Signed-off-by: Jamie Iles <jamie@jamieiles.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * | ARM: 7124/1: smp: Add a localtimer handler callable from C codeShawn Guo2011-10-172-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | In order to be able to handle localtimer directly from C code instead of assembly code, introduce handle_local_timer(), which is modeled after handle_IRQ(). Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * | ARM: 7123/1: smp: Add an IPI handler callable from C codeShawn Guo2011-10-172-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | In order to be able to handle IPI directly from C code instead of assembly code, introduce handle_IPI(), which is modeled after handle_IRQ(). Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * | ARM: 7100/1: smp_scu: remove __init annotation from scu_enable()Shawn Guo2011-10-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When Cortex-A9 MPCore resumes from Dormant or Shutdown modes, SCU needs to be re-enabled. This patch removes __init annotation from function scu_enable(), so that platform resume procedure can call it to re-enable SCU. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * | ARM: 7061/1: gic: convert logical CPU numbers into physical numbersWill Deacon2011-10-171-3/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The GIC driver must convert logical CPU numbers passed in from Linux into physical CPU numbers that are understood by the hardware. This patch uses the new cpu_logical_map macro for performing the conversion inside the GIC driver. Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * | ARM: 7060/1: smp: populate logical CPU mapping during bootWill Deacon2011-10-172-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To allow booting Linux on a CPU with physical ID != 0, we need to provide a mapping from the logical CPU number to the physical CPU number. This patch adds such a mapping and populates it during boot. Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * | ARM: 7011/1: Add ARM cpu topology definitionVincent Guittot2011-10-176-0/+218
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The affinity between ARM processors is defined in the MPIDR register. We can identify which processors are in the same cluster, and which ones have performance interdependency. We can define the cpu topology of ARM platform, that is then used by sched_mc and sched_smt. The default state of sched_mc and sched_smt config is disable. When enabled, the behavior of the scheduler can be modified with sched_mc_power_savings and sched_smt_power_savings sysfs interfaces. Changes since v4 : * Remove unnecessary parentheses and blank lines Changes since v3 : * Update the format of printk message * Remove blank line Changes since v2 : * Update the commit message and some comments Changes since v1 : * Update the commit message * Add read_cpuid_mpidr in arch/arm/include/asm/cputype.h * Modify header of arch/arm/kernel/topology.c * Modify tests and manipulation of MPIDR's bitfields * Modify the place and dependancy of the config * Modify Noop functions Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org> Reviewed-by: Amit Kucheria <amit.kucheria@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* | Merge branch 'mach_memory_h' of git://git.linaro.org/people/nico/linux into ↵Russell King2011-10-18117-1168/+347
|\ \ | | | | | | | | | devel-stable
| * | ARM: switch from NO_MACH_MEMORY_H to NEED_MACH_MEMORY_HNicolas Pitre2011-10-133-41/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Given that we want the default to not have any <mach/memory.h> and given that there are now fewer cases where it is still provided than the cases where it is not at this point, this makes sense to invert the logic and just identify the exception cases. The word "need" instead of "have" was chosen to construct the config symbol so not to suggest that having a mach/memory.h file is actually a feature that one should aim for. Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-s5p64x0: remove mach/memory.hNicolas Pitre2011-10-132-18/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-s3c64xx: remove mach/memory.hNicolas Pitre2011-10-132-18/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: plat-mxc: remove mach/memory.hNicolas Pitre2011-10-132-43/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-prima2: remove mach/memory.hNicolas Pitre2011-10-133-17/+3
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-zynq: remove mach/memory.hNicolas Pitre2011-10-132-22/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-bcmring: remove mach/memory.hNicolas Pitre2011-10-133-30/+2
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-davinci: remove mach/memory.hNicolas Pitre2011-10-135-41/+7
| | | | | | | | | | | | | | | | | | Move some DDR2 related defines into a private <mach/ddr2.h> beforehand. Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-pxa: remove mach/memory.hNicolas Pitre2011-10-133-21/+2
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-ixp4xx: remove mach/memory.hNicolas Pitre2011-10-132-17/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-h720x: remove mach/memory.hNicolas Pitre2011-10-132-11/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-vt8500: remove mach/memory.hNicolas Pitre2011-10-132-28/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-s5pc100: remove mach/memory.hNicolas Pitre2011-10-132-18/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-tegra: remove mach/memory.hNicolas Pitre2011-10-132-28/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: plat-tcc: remove mach/memory.hNicolas Pitre2011-10-132-18/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-mmp: remove mach/memory.hNicolas Pitre2011-10-132-14/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-cns3xxx: remove mach/memory.hNicolas Pitre2011-10-132-26/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-nuc93x: remove mach/memory.hNicolas Pitre2011-10-132-21/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-mxs: remove mach/memory.hNicolas Pitre2011-10-132-24/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: spear: remove mach/memory.h and plat/memory.hNicolas Pitre2011-10-134-58/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-msm: remove mach/memory.hNicolas Pitre2011-10-132-35/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-gemini: remove mach/memory.hNicolas Pitre2011-10-132-19/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-lpc32xx: remove mach/memory.hNicolas Pitre2011-10-132-27/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-netx: remove mach/memory.hNicolas Pitre2011-10-132-26/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-versatile: remove mach/memory.hNicolas Pitre2011-10-132-28/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-ux500: remove mach/memory.hNicolas Pitre2011-10-132-18/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-nomadik: remove mach/memory.hNicolas Pitre2011-10-132-28/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-iop32x: remove mach/memory.hNicolas Pitre2011-10-132-13/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-pnx4008: remove mach/memory.hNicolas Pitre2011-10-132-21/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-w90x900: remove mach/memory.hNicolas Pitre2011-10-132-23/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
| * | ARM: mach-vexpress: remove mach/memory.hNicolas Pitre2011-10-132-25/+1
| | | | | | | | | | | | Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>