aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/kernel (follow)
AgeCommit message (Collapse)AuthorFilesLines
2007-09-21sh: Kill off volatile silliness in sq_flush_range().Paul Mundt1-2/+2
CC arch/sh/kernel/cpu/sh4/sq.o arch/sh/kernel/cpu/sh4/sq.c: In function 'sq_flush_range': arch/sh/kernel/cpu/sh4/sq.c:65: warning: passing argument 1 of 'prefetch' discards qualifiers from pointer target type This didn't actually need to be volatile in the first place, so just kill off the qualifier entirely. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add support for sh7206Magnus Damm1-51/+158
This patch converts the cpu specific interrupt setup code for sh7206 from ipr to intc. New vectors are also added to match the information provided by the datasheet. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add support for sh7619Magnus Damm1-37/+56
This patch converts the cpu specific interrupt setup code for sh7619 from ipr to intc. New vectors are also added to match the information provided by the datasheet. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: fix irqs for the second serial port on sh7206Magnus Damm1-4/+4
This patch makes sure the serial port interrupt irqs matches the datasheet. Only irqs for SCIF1 are changed. While at some cosmetic spaces are added. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - primary priority masking fixesMagnus Damm1-5/+28
This patch contains various intc fixes for problems reported by Markus Brunner on the linuxsh-dev mailing list: http://marc.info/?l=linuxsh-dev&m=118701948224991&w=1 Apart from added comments, the fixes are: - add intc_set_priority() function prototype to hw_irq.h - fix off-by-one error in intc_set_priority() - make sure _INTC_WIDTH() is set for primary priority masking Big thanks to Markus for finding these problems. Version two fixes a compile error and an inverted primary check. Signed-off-by: Magnus Damm <damm@igel.co.jp> Acked-by: Markus Brunner <super.firetwister@gmail.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - mark data structures as __initdataMagnus Damm9-71/+70
With the intc core improved it is now possible to put the intc data structures in the initdata section. Version two of this patch puts the __initdata inside DECLARE_INTC_DESC() and removes the __initdata included in the board specific r2d code. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: x3 - add ipi vectorsMagnus Damm1-0/+9
With the intc dual prio register support in place it is now possible to add the ipi vectors to x3. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - rework core codeMagnus Damm1-211/+327
This patch reworks the intc core, implementing the following features: - Support dual priority registers - one set and one clear register - All 8/16/32 bit register combinations are now supported - Both single mask and single enable bitmap register are supported - Add code to set interrupt priority - Speedup sense and priority configuration code - Allocate data using bootmem, allows intc data structures to be __initdata - Save memory - allocated memory footprint is smaller than intc structures Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add a clear register to struct intc_prio_regMagnus Damm10-96/+104
We need a secondary register member in struct intc_prio_reg to support dual priority registers used by ipi on x3. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: x3 - fix setup_bootmem_node() compile error with shx3_defconfigMagnus Damm1-0/+1
This makes sure the function prototype for setup_bootmem_node() gets included. The file setup-shx3.c does not compile otherwise for CONFIG_NUMA=n. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: Add SH7720 CPU support.Markus Brunner6-6/+252
This adds support for the SH7720 (SH3-DSP) CPU. Signed-off by: Markus Brunner <super.firetwister@gmail.com> Signed-off by: Mark Jonas <toertel@gmail.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: Kill off duplicate symbol exports on SMP.Paul Mundt1-6/+1
synchronize_irq() was being exported twice, kill off the duplicate export. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: Wire up CSM node for SH-X3.Paul Mundt1-5/+8
Now that NODES_SHIFT is bumped up, we can plug in the CSM block as a separate node, too. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc: Fix sense regs oops for IRL IRQs.Paul Mundt1-1/+1
IRL doesn't always define sense registers, so don't bother trying to iterate through the table. This ended up causing an oops on SH-X3 when using IRL mode. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: remove intc2 codeMagnus Damm2-87/+0
There is no point in keeping around the now unused intc2 code. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add single bitmap register supportMagnus Damm1-11/+62
This patch adds single bitmap register support to intc. The current code only handles 16 and 32 bit registers where a set bit means interrupt enabled, but this is easy to extend in the future. The INTC_IRQ() macro is also added to provide a way to hook in interrupt controllers for FPGAs in boards or companion chips. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - remove redundant irq code for shminMagnus Damm1-0/+4
This patch removes redundant interrupt code for the shmin board which is using a sh770x processor and 4 IRQ lines as individual interrupts (IRQ-mode). Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - remove redundant irq code for sh03, snapgear and titanMagnus Damm1-4/+10
This patch removes redundant board specific interrupt code for boards using sh775x processors and 4 IRQ lines in "Individual Interrupt Mode" aka IRLM. Three boards are affected: sh03, snapgear and titan. The right way to do this is to use cpu specific code provided by intc. A nice side effect is that sh03 now compiles, board not BROKEN any more. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21rtc: rtc-sh: Support 4-digit year on SH7705/SH7710/SH7712.Paul Mundt2-3/+19
All SH-4 parts have a 4-digit year, while the SH-3 parts typically only use a 2-digit one. The SH7705, SH7710, and SH7712 SH-3 parts however opted to extend it to 4-digit and still look and act like an SH-3 RTC in all other ways. This adds a capability flag (RTC_CAP_4_DIGIT_YEAR) that these corner-case CPU subtypes can set in their platform data and cleans up some of the ifdef mess in the driver as a result. Reported-by: Markus Brunner <super.firetwister@gmail.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: Initial multiple-node support for SH-X3.Paul Mundt1-0/+14
Wire up CPU#0 URAM as node 1 on SH-X3. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add support for x3Magnus Damm1-16/+188
This patch converts the cpu specific interrupt setup code for x3 from intc2 to intc. New vectors are also added to match the preliminary information. Use plat_irq_setup_pins() to select between IRQ and IRL mode for IRQ0-3. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - fix IRQ4 and IRQ5 typo on sh3Magnus Damm3-3/+3
The intc tables for sh3 currently contain a typo where the bit fields in IPRD are mixed up for IRQ4 and IRQ5. This patch makes sure the correct bit fields are used - all according to the datasheets. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add support for SH7760Magnus Damm1-107/+146
This patch converts the cpu specific interrupt setup code for sh7760 from ipr + intc2 to intc. New vectors are also added to match the information provided by the datasheet. Vectors for IRQ4-IRQ7 are enabled by default. Use plat_irq_setup_pins() if pins IRL0-3 should be used in IRLM mode. The patch also adds the SIM block to the serial port platform data. Version two of this patch fixes MMCIF problems reported by Manuel Lauss. Signed-off-by: Magnus Damm <damm@igel.co.jp> Acked-by: Manuel Lauss <mano@roarinelk.homelinux.net> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add support for SH7785Magnus Damm1-33/+222
This patch converts the cpu specific interrupt setup code for sh7785 from intc2 to intc. New vectors are also added to match the information provided by the datasheet. No IRQ/IRL pin vectors are enabled by default. Use plat_irq_setup_pins() to select between IRL and IRQ mode. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: Support explicit L1 cache disabling.Paul Mundt2-7/+11
This reworks the cache mode configuration in Kconfig, and allows for explicit selection of write-back/write-through/off configurations. All of the cache flushing routines are optimized away for the off case. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - avoid SH7710 specific vector on SH7712Magnus Damm1-2/+7
This patch makes sure that the sh7710 specific ipsec vector is missing if building for a sh7712. All according to the datasheet. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add missing vectors for SH7707Magnus Damm1-0/+8
This patch adds a few missing vectors for sh7707. The only interrupt controller differences between sh7707 and sh7709 seem to be added vectors for one LCD controller and two PCMCIA slots. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add support for SH7706, SH7707, SH7708, SH7709Magnus Damm4-192/+216
This patch unifies the cpu specific interrupt setup code for sh7706, sh7707, sh7708 and sh7709 and moves the code into a new file called setup-sh770x.c. It makes sense to share the setup code between these processors because most hardware blocks are identical from a software point of view. With this patch the sh770x processors now have a complete set of vectors that match with the information provided by the data sheets. This is a big improvement for sh7708. Vectors for IRQ4 and IRQ5 are enabled by default. Use plat_irq_setup_pins() if pins IRQ0-3 should be used in IRQ mode. This patch also unifies the platform device setup code which means that the rtc driver now has platform data for all sh770x processors. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add support for SH7710Magnus Damm1-53/+130
This patch converts the cpu specific interrupt setup code for sh7710 from ipr to intc. While at it new vectors are added to match the information provided by the datasheet. Version two simplifies the Kconfig part. Vectors for IRQ4 and IRQ5 are enabled by default. Use plat_irq_setup_pins() if pins IRQ0-3 should be used in IRQ mode. This patch also adds sh7710 specific platform data for the rtc driver. The base address of SCIF1 is adjusted to match the datasheet. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-09-21sh: intc - add support for SH7705Magnus Damm1-44/+118
This patch converts the cpu specific interrupt setup code for sh7705 from ipr to intc. While at it new vectors are added to match the information provided by the datasheet. Vectors for IRQ4 and IRQ5 are enabled by default. Use plat_irq_setup_pins() if pins IRQ0-3 should be used in IRQ mode. This patch also adds sh7705 specific platform data for the rtc driver. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-08-22sh: missing symbol fix for sh4-202Magnus Damm1-0/+5
This patch adds a plat_irq_setup() symbol for sh4-202. Without this fix it is impossible to build a working kernel using the microdev_defconfig. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-08-17sh: remove extraneous ; on scif_sercon_putc wait loopAndy Whitcroft1-1/+1
It seems we have gained an extraneous trailing ';' on one of the wait loops in scif_sercon_putc(). Although this is completely benign as the apparent payload is also the empty statement, it invites error in the future. Clean it up now. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-08-07sh: panic on machvec section misalignment.Paul Mundt1-0/+7
Now that __initmv references the machvec section unconditionally there have been cases where folks have been mistakenly flagging non-machvec structures with the machvec section attribute (presumably to shut up modpost). This leads to obscure breakage in earlyprintk amongst other places and is rather non-obvious. Add a simple sanity check to try and catch __initmv misuse and panic early. Reported-by: Markus Brunner <super.firetwister@gmail.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-08-04sh: Fix PTRACE_PEEKTEXT/PEEKDATA fallout from generic_ptrace_peekdata().Paul Mundt1-0/+1
When generic_ptrace_peekdata() was merged, the break for these cases ended up getting dropped, which lead to each PEEKTEXT/PEEKDATA op leaking in to PEEKUSR and get_user_pages() always -EFAULTing. Add the break back in. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-08-01sh: Fix SH-X3 FPU exception handling.Paul Mundt1-0/+5
SH-X3 has the FPU exceptions on different vectors completely, patch in do_fpu_state_restore() to the proper vectors. Results in a much happier userspace. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-08-01sh: Fix lockdep debugging oops on SH-3/4.Paul Mundt1-2/+1
In the SH-3/4 TLB access violation path we were enabling IRQs before the call in to trace_hardirqs_on(), which ended up triggering: if (DEBUG_LOCKS_WARN_ON(!irqs_disabled())) return; in kernel/lockdep.c:2031. Fix this up by removing the early re-enable, we were already re-enabling IRQs post-trace_hardirqs_on() already, so the semantics are now as was initially intended. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-31sh: Fix fs.h removal from mm.h regressions.Paul Mundt4-1/+4
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-26sh: fix get_wchan() for SH kernels without framepointersDavid McCullough1-2/+4
Do not follow the frame pointers (/proc/X/task/1/stat) unless we were compiled with them. Signed-off-by: David McCullough <david_mccullough@au.securecomputing.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-26sh: remove support for sh7300 and solution engine 7300Magnus Damm6-63/+16
This patch removes old dead code: - kill off sh7300 cpu support - get rid of broken solution engine 7300 board support Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-26sh: Silence sq compile warning on sh4 nommu.Paul Mundt1-6/+12
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-25sh: remove support for sh73180 and solution engine 73180Magnus Damm5-133/+1
This patch removes old dead code: - kill off sh73180 cpu support - get rid of broken solution engine 73180 board support Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-25sh: remove old broken pint codeMagnus Damm2-221/+0
The code in arch/sh/kernel/cpu/irq/pint.c doesn't compile, so let's get rid of it to make space for a future pint implementation on top of intc. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-21clockevents: fix resume logicThomas Gleixner1-0/+1
We need to make sure, that the clockevent devices are resumed, before the tick is resumed. The current resume logic does not guarantee this. Add CLOCK_EVT_MODE_RESUME and call the set mode functions of the clock event devices before resuming the tick / oneshot functionality. Fixup the existing users. Thanks to Nigel Cunningham for tracking down a long standing thinko, which affected the jinxed VAIO. [akpm@linux-foundation.org: xen build fix] Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: john stultz <johnstul@us.ibm.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-20sh: intc - add support for SH7750 and its variantsMagnus Damm1-64/+189
This patch converts the cpu specific 7750 setup code to use the new intc controller. Many new vectors are added and multiple processor variants including 7091, 7750, 7750s, 7750r, 7751 and 7751r should all have the correct vectors hooked up. IRLM interrupts can be enabled using ipr_irq_enable_irlm() which now is marked as __init. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-20sh: Move entry point code to .text.head.Paul Mundt2-1/+3
Follow Al Viro's m68k change from l-k: i.e. tell modpost that entry point code (that has to be outside of .init.text for external reasons) is OK to refer to .init.* Shuts up some section mismatch warnings from modpost. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-20sh: Many symbol exports for nommu allmodconfig.Paul Mundt3-2/+43
allmodconfig generates a lot of interesting code, a lot of the generated symbols we've never exported before, so this fixes those up. Verified with both GCC3 and GCC4 toolchains. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-20sh: cpufreq: Fix up the build for SH-2.Paul Mundt1-5/+0
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-20Merge branch 'clkfwk'Paul Mundt3-134/+111
2007-07-20sh: cpufreq: clock framework support.Paul Mundt1-134/+80
This gets the SH cpufreq working again. We follow the changes in the AVR32 implementation for wrapping in to the clock framework. CPUs that wish to use this are required to define rate rounding primitives in order to satisfy clk_round_rate(). This works well enough for the common case, though we should look at unifying this driver across all of the platforms that implement clock framework support in one capacity or another. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-07-20sh: Support rate rounding for SH7722 FRQCR clocks.Paul Mundt1-0/+15
Now that the round_rate() op is supported, hook it up on SH7722 for the FRQCR (CPU, PCLK, etc.) clocks. Signed-off-by: Paul Mundt <lethal@linux-sh.org>