aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/kernel
Commit message (Collapse)AuthorAge
* sh: Add SH7785 Highlander board support (R7785RP).Paul Mundt2007-05-06
| | | | | | | | | | | This adds preliminary support for the SH7785-based Highlander board. Some of the Highlander support code is reordered so that most of it can be reused directly. This also plugs in missing SH7785 checks in the places that need it, as this is the first board to support the CPU. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: NR_IRQS consolidation.Paul Mundt2007-05-06
| | | | | | | | | | Each board sets the total number of IRQs that it's interested in via the machvec. Previously we cared about the off vs on-chip IRQ range, but any code relying on that is long dead. Set NR_IRQS to something sensible given the vector range, and allow boards to cap it if they really care. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: generic BUG() support.Paul Mundt2007-05-06
| | | | | | | | | Wire up GENERIC_BUG for SH. This moves off of the special bug frame and on to the generic struct bug_entry. Roughly the same semantics are retained, and we can kill off some of the verbose BUG() reporting code. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: speculative execution support for SH7780.Paul Mundt2007-05-06
| | | | | | | | | | SH7780 has a speculative execution mode where it can speculatively perform an instruction fetch for subroutine returns, this allows it to be enabled. There are some various pitfalls associated with this mode, so it's left as depending on CONFIG_EXPERIMENTAL and not enabled by default. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Rip out broken kgdb thread support.Paul Mundt2007-05-06
| | | | | | | | | | | | The kgdb thread support is woefully out of date (it predates the pidhash), and needs a complete rewrite before it's useful again. Just rip it out entirely. Updating the unified kgdb stub is a more worthwhile endeavour for anyone that happens to be interested in this, at present it's just limping along. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Bring kgdb back from the dead.Paul Mundt2007-05-06
| | | | | | | | This code has suffered quite a bit of bitrot, do some basic tidying to get it to a reasonably functional state again. This gets the basic support and the console working again. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* [PATCH] x86: Allow percpu variables to be page-alignedJeremy Fitzhardinge2007-05-02
| | | | | | | | | | | | | | | Let's allow page-alignment in general for per-cpu data (wanted by Xen, and Ingo suggested KVM as well). Because larger alignments can use more room, we increase the max per-cpu memory to 64k rather than 32k: it's getting a little tight. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com> Signed-off-by: Andi Kleen <ak@suse.de> Acked-by: Ingo Molnar <mingo@elte.hu> Cc: Andi Kleen <ak@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
* sh: Kill bogus GCC4 symbol exports.Paul Mundt2007-03-28
| | | | | | | | | __sdivsi3_i4i, __udiv_qrnnd_16, and __udivsi3_i4i don't exist outside of the ST compiler, so kill them off. This causes compile failures with other GCC4 compilers. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fix bogus regs pointer in do_IRQ().Paul Mundt2007-03-14
| | | | | | | | SH-3 and SH-4 were trampling the register, and SH-2 wasn't even setting it in the first place. This ended up with some rather broken behaviour in the sysrq show_regs(). Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fix SH-3 cache entry_mask and way_size calculation.Paul Mundt2007-03-12
| | | | | | | | The code for performing the calculation was only in the SH-4 probe path, move it out to the common path so the other parts get this right too. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Revert lazy dcache writeback changes.Paul Mundt2007-03-05
| | | | | | | These ended up causing too many problems on older parts, revert for now.. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Use L1_CACHE_BYTES for .data.cacheline_aligned.Paul Mundt2007-03-05
| | | | | | | Previously this was using a hardcoded 32, use L1_CACHE_BYTES for cacheline alignment instead. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fix kernel thread stack corruption with preempt.Hideo Saito2007-03-05
| | | | | | | | | | | When I run a preemptive kernel-2.6.20 for SH7780, a created kthread(pdflush) can not exit by do_exit() in kernel_thread_helper. I think that the created kthread should have a room for 'struct pt_regs' space on the stack top, because __switch_to() will refer to the space as follows using 'regs = task_pt_regs(prev)' and next condition may be true. Signed-off-by: Hideo Saito <saito@densan.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fix sigmask trampling in signal delivery.Ryusuke Sakato2007-03-05
| | | | | | | | | There was a missing return in do_signal() that caused the saved sigmask to be written back after having successfully delivered the signal. Signed-off-by: Ryusuke Sakato <sakato@hsdv.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Clear UBC when not in use.Stuart Menefy2007-03-05
| | | | | | | | | This takes care of tearing down the UBC so it's not inadvertently left configured at the next context switch time. Failure to do this results in spurious SIGTRAPs in certain debug sequences. Signed-off-by: Stuart Menefy <stuart.menefy@st.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* Storage class should be before const qualifierTobias Klauser2007-02-17
| | | | | | | | | | | The C99 specification states in section 6.11.5: The placement of a storage-class specifier other than at the beginning of the declaration specifiers in a declaration is an obsolescent feature. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: Adrian Bunk <bunk@stusta.de>
* sh: rts7751r2d board updates.Paul Mundt2007-02-15
| | | | | | | | This tidies up some of the rts7751r2d mess and gets it booting again. Update the defconfig, too. Signed-off-by: Masayuki Hosokawa <hosokawa@ace-jp.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Revert TLB miss fast-path changes that broke PTEA parts.Paul Mundt2007-02-14
| | | | | | | | This ended up causing problems for older parts (particularly ones using PTEA). Revert this for now, it can be added back in once it's had some more testing. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fix syscall numbering breakage.Paul Mundt2007-02-12
| | | | | | We accidentally broke the inotify syscalls, fix those up again. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Local TLB flushing variants for SMP prep.Paul Mundt2007-02-12
| | | | | | | Rename the existing flush routines to local_ variants for use by the IPI-backed global flush routines on SMP. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fixup cpu_data references for the non-boot CPUs.Paul Mundt2007-02-12
| | | | | | | There are a lot of bogus cpu_data-> references that only end up working for the boot CPU, convert these to current_cpu_data to fixup SMP. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Use a per-cpu ASID cache.Paul Mundt2007-02-12
| | | | | | | | Previously this was implemented using a global cache, cache this per-CPU instead and bump up the number of context IDs to match NR_CPUS. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: SH-DMAC compile fixesManuel Lauss2007-02-12
| | | | | | | | | | | | | | | | | This patch does the following: - remove the make_ipr_irq stuff from dma-sh.c and replace it with a simple channel<->irq mapping table. - add DMTEx_IRQ constants for sh4 cpus - fix sh7751 DMAE irq number The SH7780 uses the same IRQs for DMA as other SH4 types, so I put the constants on top of the dma.h file. Other CPU types need to #define their own DMTEx_IRQ contants in their appropriate header. Signed-off-by: Manuel Lauss <mano@roarinelk.homelinux.net> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: add SH7760 IPR IRQ dataManuel Lauss2007-02-12
| | | | | | | Add SH7760 IPR IRQ data; makes 2.6.20-rc bootable again. Signed-off-by: Manuel Lauss <mano@roarinelk.homelinux.net> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fix handle_BUG() compile error.Nobuhiro Iwamatsu2007-02-12
| | | | | | | | handle_BUG() uses TRAPA_BUG_OPCODE which is only defined for CONFIG_BUG, make sure it's not built when CONFIG_BUG=n. Signed-off-by: Nobuhiro Iwamatsu <hemamu@t-base.ne.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Lazy dcache writeback optimizations.Paul Mundt2007-02-12
| | | | | | | | | | | | | | | This converts the lazy dcache handling to the model described in Documentation/cachetlb.txt and drops the ptep_get_and_clear() hacks used for the aliasing dcaches on SH-4 and SH7705 in 32kB mode. As a bonus, this slightly cuts down on the cache flushing frequency. With that and the PTEA handling out of the way, the update_mmu_cache() implementations can be consolidated, and we no longer have to worry about which configuration the cache is in for the SH7705 case. And finally, explicitly disable the lazy writeback on SMP (SH-4A). Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: More tidying for large base pages.Paul Mundt2007-02-12
| | | | | | | | There were a few more things that needed fixing up, namely THREAD_SIZE and the TLB miss handler where certain PTRS_PER_PGD == PTRS_PER_PTE assumptions were being made. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: shmin updates.Takashi YOSHII2007-02-12
| | | | | | | | This fixes up shmin (and SH7706/SH7708) IPR support for some of the recent API changes. Signed-off-by: Takashi YOSHII <takasi-y@ops.dti.ne.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: allow earlyprintk baud rate to be set via command lineJamie Lenehan2007-02-12
| | | | | | | | | | | | | | | | This allows the baud rate for earlyprintk for sh4 without the standard BIOS to be set via the command line. This uses the same format as i386 and x86_64, which is: earlyprintk=serial,ttySC1,38400 The second parameter (ttySC1 above) is usually the console device name or the io address of the serial port. I allow that to be specified but ignore it in order to keep the format the same as i386/x86_64. Signed-off-by: Jamie Lenehan <lenehan@twibble.org> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: sh7619 / sh7206 IPR initialize updateYoshinori Sato2007-02-12
| | | | | | | IPR initialize proceduere update. Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Update SH-2 to use the debug trap jump table.Yoshinori Sato2007-02-12
| | | | | Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Use a jump call table for debug trap handlers.Paul Mundt2007-02-12
| | | | | | | | | | | | | | | | | This rips out most of the needlessly complicated sh_bios and kgdb trap handling, and forces it all through a common fast dispatch path. As more debug traps are inserted, it's important to keep them in sync for all of the parts, not just SH-3/4. As the SH-2 parts are unable to do traps in the >= 0x40 range, we restrict the debug traps to the 0x30-0x3f range on all parts, and also bump the kgdb breakpoint trap down in to this range (from 0xff to 0x3c) so it's possible to use for nommu. Optionally, this table can be padded out to catch spurious traps for SH-3/4, but we don't do that yet.. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* [PATCH] Dynamic kernel command-line: shAlon Bar-Lev2007-02-12
| | | | | | | | | | 1. Rename saved_command_line into boot_command_line. 2. Set command_line as __initdata. Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* [PATCH] Consolidate default sched_clock()Alexey Dobriyan2007-02-11
| | | | | | | | | Use attribute(weak). Signed-off-by: Alexey Dobriyan <adobriyan@openvz.org> Acked-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* [PATCH] disable init/initramfs.c: architecturesJean-Paul Saman2007-02-11
| | | | | | | | | | | | Update all arch/*/kernel/vmlinux.lds.S to not include space for initramfs when CONFIG_BLK_DEV_INITRAMFS is not selected. This saves another 4 kbytes on most platfoms (some reserve PAGE_SIZE for initramfs). Signed-off-by: Jean-Paul Saman <jean-paul.saman@nxp.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: <linux-arch@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-apmLinus Torvalds2007-02-09
|\ | | | | | | | | | | | | | | * 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-apm: [APM] SH: Convert to use shared APM emulation. [APM] MIPS: Convert to use shared APM emulation. [APM] ARM: Convert to use shared APM emulation. [APM] Add shared version of APM emulation
| * [APM] SH: Convert to use shared APM emulation.Paul Mundt2007-02-09
| | | | | | | | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* | [PATCH] SH vdso: use install_special_mapping()Paul Mundt2007-02-09
|/ | | | | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org> Cc: Roland McGrath <roland@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* sh: Fixup SH-2 BUG() trap handling.Yoshinori Sato2006-12-11
| | | | | | | This adds in support for the BUG() trap on SH-2. Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Use early_param() for earlyprintk parsing.Paul Mundt2006-12-11
| | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fix .empty_zero_page alignment for PAGE_SIZE > 4096.Paul Mundt2006-12-11
| | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fixup .data.page_aligned.Paul Mundt2006-12-11
| | | | | | This had a bogus .data.idt reference, fix it up.. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Hook up SH7722 scif ipr interrupts.Paul Mundt2006-12-11
| | | | | | Add the SCIF IRQs to the IPR table for SH7722. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fixup sh_bios() trap handling.Paul Mundt2006-12-11
| | | | | | | | | This was inadvertently broken when the entry.S code split up, restore the missing branch and get subsequent traps working under debug again. This manifested itself as a lockup when attempting to reload the VBR base. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: SH-MobileR SH7722 CPU support.Paul Mundt2006-12-11
| | | | | | This adds CPU support for the SH7722. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Convert remaining remap_area_pages() users to ioremap_page_range().Paul Mundt2006-12-11
| | | | | | A couple of these were missed. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fixup kernel_execve() for syscall cleanups.Paul Mundt2006-12-11
| | | | | | | | SH-2 and SH-2A need to use a different syscall base for the trapa vector than the other parts, so fixup the logic in the kernel_execve() case. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Fix get_wchan().Paul Mundt2006-12-11
| | | | | | | | | Some time ago the schedule frame size changed and we failed to reflect this in get_wchan() at the time. This first popped up as a problem on SH7751R where schedule_frame ended up being unaligned and generating an unaligned trap. This fixes it up again.. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: BUG() handling through trapa vector.Paul Mundt2006-12-11
| | | | | | | | | | | | | Previously we haven't been doing anything with verbose BUG() reporting, and we've been relying on the oops path for handling BUG()'s, which is rather sub-optimal. This switches BUG handling to use a fixed trapa vector (#0x3e) where we construct a small bug frame post trapa instruction to get the context right. This also makes it trivial to wire up a DIE_BUG for the atomic die chain, which we couldn't really do before. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
* sh: Trivial build fixes for SH-2 support.Yoshinori Sato2006-12-11
| | | | | Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>