summaryrefslogtreecommitdiffstats
path: root/arch/sparc
Commit message (Collapse)AuthorAgeFilesLines
* new helper: sigsuspend()Al Viro2012-05-222-23/+2Star
| | | | | | | | | guts of saved_sigmask-based sigsuspend/rt_sigsuspend. Takes kernel sigset_t *. Open-coded instances replaced with calling it. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* Merge branch 'smp-hotplug-for-linus' of ↵Linus Torvalds2012-05-2212-83/+23Star
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull smp hotplug cleanups from Thomas Gleixner: "This series is merily a cleanup of code copied around in arch/* and not changing any of the real cpu hotplug horrors yet. I wish I'd had something more substantial for 3.5, but I underestimated the lurking horror..." Fix up trivial conflicts in arch/{arm,sparc,x86}/Kconfig and arch/sparc/include/asm/thread_info_32.h * 'smp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (79 commits) um: Remove leftover declaration of alloc_task_struct_node() task_allocator: Use config switches instead of magic defines sparc: Use common threadinfo allocator score: Use common threadinfo allocator sh-use-common-threadinfo-allocator mn10300: Use common threadinfo allocator powerpc: Use common threadinfo allocator mips: Use common threadinfo allocator hexagon: Use common threadinfo allocator m32r: Use common threadinfo allocator frv: Use common threadinfo allocator cris: Use common threadinfo allocator x86: Use common threadinfo allocator c6x: Use common threadinfo allocator fork: Provide kmemcache based thread_info allocator tile: Use common threadinfo allocator fork: Provide weak arch_release_[task_struct|thread_info] functions fork: Move thread info gfp flags to header fork: Remove the weak insanity sh: Remove cpu_idle_wait() ...
| * task_allocator: Use config switches instead of magic definesThomas Gleixner2012-05-082-2/+1Star
| | | | | | | | | | | | | | | | | | | | Replace __HAVE_ARCH_TASK_ALLOCATOR and __HAVE_ARCH_THREAD_ALLOCATOR with proper config switches. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Sam Ravnborg <sam@ravnborg.org> Cc: Tony Luck <tony.luck@intel.com> Link: http://lkml.kernel.org/r/20120505150142.371309416@linutronix.de
| * sparc: Use common threadinfo allocatorThomas Gleixner2012-05-081-23/+2Star
| | | | | | | | | | | | | | | | Exaclty the same as the core code. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: David S. Miller <davem@davemloft.net> Link: http://lkml.kernel.org/r/20120505150142.252861878@linutronix.de
| * init_task: Replace CONFIG_HAVE_GENERIC_INIT_TASKThomas Gleixner2012-05-051-1/+0Star
| | | | | | | | | | | | | | | | | | Now that all archs except ia64 are converted, replace the config and let the ia64 select CONFIG_ARCH_INIT_TASK Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20120503085035.867948914@linutronix.de
| * sparc: Use generic init_taskThomas Gleixner2012-05-054-24/+1Star
| | | | | | | | | | | | | | | | | | | | Same code. Use the generic version. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: "David S. Miller" <davem@davemloft.net> Acked-by: Sam Ravnborg <sam@ravnborg.org> Link: http://lkml.kernel.org/r/20120503085035.463573011@linutronix.de
| * sparc: Use generic idle thread allocationThomas Gleixner2012-04-267-32/+18Star
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com> Tested-by: David S. Miller <davem@davemloft.net> Link: http://lkml.kernel.org/r/20120420124558.055198736@linutronix.de
| * smp: Add task_struct argument to __cpu_up()Thomas Gleixner2012-04-262-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Preparatory patch to make the idle thread allocation for secondary cpus generic. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com> Cc: Matt Turner <mattst88@gmail.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: Mike Frysinger <vapier@gentoo.org> Cc: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Richard Kuo <rkuo@codeaurora.org> Cc: Tony Luck <tony.luck@intel.com> Cc: Hirokazu Takata <takata@linux-m32r.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: David Howells <dhowells@redhat.com> Cc: James E.J. Bottomley <jejb@parisc-linux.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Paul Mundt <lethal@linux-sh.org> Cc: David S. Miller <davem@davemloft.net> Cc: Chris Metcalf <cmetcalf@tilera.com> Cc: Richard Weinberger <richard@nod.at> Cc: x86@kernel.org Link: http://lkml.kernel.org/r/20120420124556.964170564@linutronix.de
* | net: drop NET dependency from HAVE_BPF_JITSam Ravnborg2012-05-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is no point having the NET dependency on the select target, as it forces all users to depend on NET to tell they support BPF_JIT. Move the config option to the bottom of the file - this could be a nice place also for future "selectable" config symbols. Fix up all users to drop the dependency on NET now that it is not required to supress warnings for non-NET builds. Reported-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: David Miller <davem@davemloft.net> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-nextLinus Torvalds2012-05-21136-10726/+2242Star
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Pull sparc updates from David Miller: 1) Kill off support for sun4c and Cypress sun4m chips. And as a result we were able to also kill off that ugly btfixup thing that required multi-stage links of the final vmlinux image in the Kbuild system. This should make the kbuild maintainers really happy. Thanks a lot to Sam Ravnborg for his tireless efforts to get this going. 2) Convert sparc64 to nobootmem. I suspect now with sparc32 being a lot cleaner, it should be able to fall in line and modernize in this area too. 3) Make sparc32 use generic clockevents, from Tkhai Kirill. [ I fixed up the BPF rules, and tried to clean up the build rules too. But I don't have - or want - a sparc cross-build environment, so the BPF rule bug and the related build cleanup was all done with just a bare "make -n" pseudo-test. - Linus ] * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-next: (110 commits) sparc32: use flushi when run-time patching in per_cpu_patch sparc32: fix cpuid_patch run-time patching sparc32: drop unused inline functions in srmmu.c sparc32: drop unused functions in pgtsrmmu.h sparc32,leon: move leon mmu functions to leon_mm.c sparc32,leon: remove duplicate definitions in leon.h sparc32,leon: remove duplicate UART register definitions sparc32,leon: move leon ASI definitions to asi.h sparc32: move trap table to a separate file sparc64: renamed ttable.S to ttable_64.S sparc32: Remove asm/sysen.h header. sparc32: Delete asm/smpprim.h sparc32: Remove unused empty_bad_page{,_table} declarations. sparc32: Kill boot_cpu_id4 sparc32: Move GET_PROCESSOR*_ID() out of asm/asmmacro.h sparc32: Remove completely unused code from asm/cache.h sparc32: Add ucmpdi2.o to obj-y instead of lib-y. sparc32: add ucmpdi2 sparc: introduce arch/sparc/Kbuild sparc: remove obsolete documentation ...
| * | sparc32: use flushi when run-time patching in per_cpu_patchSam Ravnborg2012-05-203-13/+10Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Davis S. Miller wrote: " The way we do that now is overkill. We only needed to use the MMU cache ops when we had sun4c around because sun4c lacked support for the "flush" instruction. But all sun4m and later chips have it so we can use it unconditionally. So in the per_cpu_patch() code, get rid of the cache ops invocation, and instead execute a "flush %reg" after each of the instruction patch assignments, where %reg is set to the address of the instruction that was stored into. Perhaps take the flushi() definition from asm/cacheflush_64.h and place it into asm/cacheflush.h, then you can simply use that. " Implemented as per suggestion. Moved run-time patching before we call paging_init(), so helper methods in paging_init() may utilise run-time patching too. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: fix cpuid_patch run-time patchingSam Ravnborg2012-05-201-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | We hang forever when trying to do run-time patching of instructions identified by the cpuid_patch section Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: drop unused inline functions in srmmu.cSam Ravnborg2012-05-201-26/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | When decelared inline the compiler does not warn about unused functions. But they are not used so drop them. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: drop unused functions in pgtsrmmu.hSam Ravnborg2012-05-202-52/+14Star
| | | | | | | | | | | | | | | | | | | | | One function was only used by leon - move it to a leon specific file. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32,leon: move leon mmu functions to leon_mm.cSam Ravnborg2012-05-203-81/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | We already have a leaon specific file - so keep all the laon stuff in one place. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Konrad Eisele <konrad@gaisler.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32,leon: remove duplicate definitions in leon.hSam Ravnborg2012-05-201-15/+2Star
| | | | | | | | | | | | | | | | | | Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Konrad Eisele <konrad@gaisler.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32,leon: remove duplicate UART register definitionsSam Ravnborg2012-05-201-25/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | The registers are defined in leon_amba too. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Konrad Eisele <konrad@gaisler.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32,leon: move leon ASI definitions to asi.hSam Ravnborg2012-05-202-13/+14
| | | | | | | | | | | | | | | | | | Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Konrad Eisele <konrad@gaisler.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: move trap table to a separate fileSam Ravnborg2012-05-202-324/+419
| | | | | | | | | | | | | | | Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc64: renamed ttable.S to ttable_64.SSam Ravnborg2012-05-202-1/+1
| | | | | | | | | | | | | | | | | | | | | To allow us to add ttable_32.S Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Remove asm/sysen.h header.David S. Miller2012-05-201-15/+0Star
| | | | | | | | | | | | | | | | | | Defines a sun4c register, thus completely unused. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Delete asm/smpprim.hDavid S. Miller2012-05-201-54/+0Star
| | | | | | | | | | | | | | | | | | Completely unused. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Remove unused empty_bad_page{,_table} declarations.David S. Miller2012-05-201-2/+0Star
| | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Kill boot_cpu_id4David S. Miller2012-05-203-6/+1Star
| | | | | | | | | | | | | | | | | | It is written, but never actually read. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Move GET_PROCESSOR*_ID() out of asm/asmmacro.hDavid S. Miller2012-05-202-10/+5Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GET_PROCESSOR4D_ID is completely unused, so delete it. Move GET_PROCESSOR4M_ID to the sun4m specific trap code which uses it. We now no longer need to include asm/asi.h Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Remove completely unused code from asm/cache.hDavid S. Miller2012-05-201-114/+0Star
| | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Add ucmpdi2.o to obj-y instead of lib-y.David S. Miller2012-05-201-2/+2
| | | | | | | | | | | | | | | | | | | | | Otherwise if no references exist in the static kernel image, we won't export the symbol properly to modules. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: add ucmpdi2Sam Ravnborg2012-05-202-1/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Based on copy from microblaze add ucmpdi2 implementation. This fixes build of niu driver which failed with: drivers/built-in.o: In function `niu_get_nfc': niu.c:(.text+0x91494): undefined reference to `__ucmpdi2' This driver will never be used on a sparc32 system, but patch added to fix build breakage with all*config builds. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc: introduce arch/sparc/KbuildSam Ravnborg2012-05-152-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows us to do: make arch/sparc/ to build the core part of the sparc kernel. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc: clean up MakefileSam Ravnborg2012-05-151-21/+10Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - delete unused variables - align assignments - drop stale comments - kill use of "\" for line continuation Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: delete muldiv.o from MakefileSam Ravnborg2012-05-151-1/+0Star
| | | | | | | | | | | | | | | | | | | | | The source file is no more.. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Kill off software 32-bit multiply/divide routines.David S. Miller2012-05-1517-2129/+24Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For the explicit calls to .udiv/.umul in assembler, I made a mechanical (read as: safe) transformation. I didn't attempt to make any simplifications. In particular, __ndelay and __udelay can be simplified significantly. Some of the %y reads are unnecessary and these routines have no need any longer for allocating a register window, they can be leaf functions. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Build kernel with -mcpu=v8David S. Miller2012-05-151-1/+1
| | | | | | | | | | | | | | | | | | | | | With Cypress gone we can generate real hardware integer multiply and divide instructions at will. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: cleanup mm/fault_32.cSam Ravnborg2012-05-152-52/+44Star
| | | | | | | | | | | | | | | | | | | | | | | | - remove unused variables - fix coding style issues that hurts my eyes Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Remove cypress cpu support.David S. Miller2012-05-156-449/+5Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | It's the one aberration in v8, the only cpu that didn't actually have hardware multiply and divide instructions. Signed-off-by: David S. Miller <davem@davemloft.net> Acked-by: Sam Ravnborg <sam@ravnborg.org>
| * | sparc64: Remove pointless assignment in floppy support.David S. Miller2012-05-151-1/+0Star
| | | | | | | | | | | | | | | Reported-by: Josip Rodin <joy@entuzijast.net> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Kill unused hard_smp{4m,4d,leon}_processor_id() inlined.David S. Miller2012-05-141-29/+0Star
| | | | | | | | | | | | | | | Reported-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: drop build time btfixup patchingSam Ravnborg2012-05-143-449/+10Star
| | | | | | | | | | | | | | | Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: remove runtime btfix supportSam Ravnborg2012-05-1420-547/+1Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | - remove all uses of btfixup header - remove the btfixup header - remove the btfixup code Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: remove remaining users of btfixupSam Ravnborg2012-05-148-49/+23Star
| | | | | | | | | | | | | | | | | | | | | | | | Use sparc_config to hold the last two function pointers. There was no point generating dedicated _ops structures only for these. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: move smp ipi to method opsSam Ravnborg2012-05-1410-105/+107
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I ended up renaming set_cpu_int to send_ipi to be consistent all way around. send_ipi was moved to the *_smp.c files so we could call the relevant method direct, without any _ops indirection. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Implement hard_smp_processor_id() via instruction patching.David S. Miller2012-05-1410-175/+99Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the last non-trivial user of btfixup. Like sparc64, use a special patch section to resolve the various implementations of how to read the current CPU's ID when we don't have current_thread_info()->cpu necessarily available. Signed-off-by: David S. Miller <davem@davemloft.net> Tested-by: Sam Ravnborg <sam@ravnborg.org>
| * | sparc32: Move cache and TLB flushes over to method ops.David S. Miller2012-05-1413-478/+466Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This eliminated most of the remaining users of btfixup. There are some complications because of the special cases we have for sun4d, leon, and some flavors of viking. It was found that there are no cases where a flush_page_for_dma method was not hooked up to something, so the "noflush" iommu methods were removed. Add some documentation to the viking_sun4d_smp_ops to describe exactly the hardware bug which causes us to need special TLB flushing on sun4d. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Remove unused declarations in srmmu.cDavid S. Miller2012-05-141-6/+0Star
| | | | | | | | | | | | | | | | | | Uses of these went away with the sun4c removal. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Convert mmu_* interfaces from btfixup to method ops.David S. Miller2012-05-135-44/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This set of changes displays one major danger of btfixup, interface signatures are not always type checked fully. As seen here the iounit variant of the map_dma_area routine had an incorrect type for one of it's arguments. It turns out to be harmless in this case, but just imagine trying to debug something involving this kind of problem. No thanks. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc: Kill mmu_{un,}lockarea().David S. Miller2012-05-137-47/+3Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These were used on sun4c during floppy data transfers since on that chip we had to lock the cpu mappings into the TLB because we cannot take a TLB miss during the assembler floppy interrupt handler that does the data transfer. That is no longer necessary since we've removed sun4c support, thus this stuff can disappear completely. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Un-btfixup update_mmu_cache().David S. Miller2012-05-132-43/+1Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The magic Swift SRMMU code in question has not been enabled for something on the order of a decade, and it as well as it's comment is there in the history in case we ever need it again. Therefore all implementations are NOPs and we can kill this stuff off. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Kill btfixup for xchg()'s 'swap' instruction.David S. Miller2012-05-136-61/+2Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We always have this instruction available, so no need to use btfixup for it any more. This also eradicates the whole of atomic_32.S and thus the __atomic_begin and __atomic_end symbols completely. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: drop unused clear_cpu_intSam Ravnborg2012-05-134-21/+0Star
| | | | | | | | | | | | | | | Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: drop unused set_irq_udtSam Ravnborg2012-05-134-18/+0Star
| | | | | | | | | | | | | | | Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>