summaryrefslogtreecommitdiffstats
path: root/arch/sparc/kernel (follow)
Commit message (Collapse)AuthorAgeFilesLines
* sparc: Mark prom_early_alloc non-static.David S. Miller2008-12-063-2/+4
| | | | | | A subsequent changeset will use this. Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: Create common area for OF device layer code.David S. Miller2008-12-064-188/+122
| | | | | | | This is where common code implementations will go as we unify 32-bit and 64-bit OF device tree code. Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: Create common header file for prom_{32,64}.cDavid S. Miller2008-12-063-6/+12
| | | | | | | This is where common declarations will go as we unify these files as much as possible into common code. Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: unify kernel/init_taskSam Ravnborg2008-12-043-36/+1
| | | | | | | | | | A closer inspection revealed that these two files had identical functionality - but the implementation of it differed slightly. Base it on the sparc version as it was the best. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: drop CONFIG_SUN_AUXIOSam Ravnborg2008-12-044-8/+0
| | | | | | | It is always equals y so no need to test for it Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: Add missing of_node_putNicolas Palix2008-12-043-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of_node_put is needed before discarding a value received from of_find_node_by_name, eg in error handling code or when the device node is no longer used. The semantic match that catches the bug is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @r exists@ local idexpression struct device_node *n; position p1, p2; struct device_node *n1; statement S; identifier f; expression E; expression *ptr != NULL; @@ n@p1 = of_find_node_by_name(...) ... if (!n) S ... when != of_node_put(n) when != n1 = f(n,...) when != E = n when any when strict ( return \(0\|<+...n...+>\|ptr\); | return@p2 ...; | of_node_put(n); | n1 = f(n,...) | E = n ) @script:python@ p1 << r.p1; p2 << r.p2; @@ print "* file: %s of_find_node_by_name %s return %s" % (p1[0].file,p1[0].line,p2[0].line) // </smpl> Signed-off-by: Nicolas Palix <npalix@diku.dk> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc,sparc64: unify kernel/Sam Ravnborg2008-12-0490-0/+43306
| | | | | | | | | | | | | | | | o Move all files from sparc64/kernel/ to sparc/kernel - rename as appropriate o Update sparc/Makefile to the changes o Update sparc/kernel/Makefile to include the sparc64 files NOTE: This commit changes link order on sparc64! Link order had to change for either of sparc32 and sparc64. And assuming sparc64 see more testing than sparc32 change link order on sparc64 where issues will be caught faster. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: prepare kernel/ for unificationSam Ravnborg2008-12-0426-22/+54
| | | | | | | | | | | | | | | o sparc32 files with identical names to sparc64 renamed to <name>_32.S o introduced a few Kconfig helpers to simplify Makefile logic o refactored Makefile to prepare for unification - use obj-$(CONFIG_SPARC32) for sparc32 specific files - use <name>_$(BITS) for files where sparc64 has a _64 variant - sparc64 directly include a few files where sparc32 builds them, refer to these files directly (no BITS) - sneaked in -Werror as used by sparc64 o modified sparc/Makefile to use the new names for head/init_task Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: gitignore a few filesSam Ravnborg2008-12-041-0/+1
| | | | | | | | With this 'git status' no longer reports any new files At least not for a sparc allnoconfig build Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc,sparc64: unify asm-offsets.cSam Ravnborg2008-12-041-3/+16
| | | | | | | | | sparc64 does not use constants generated from asm-offsets but to prepare it to do so the parts that could be shared do now generate constants for sparc64 too. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc,sparc64: prepare vmlinux.lds.S for unificationSam Ravnborg2008-12-041-20/+79
| | | | | | | | | | | | | This patch makes the two vmlinux.lds.S files identical and serve as documentation for the changes in each file. This mainly add stuffs to sparc32 that is otherwise only used by sparc64 and thus it should have no effect. Build tested only. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc32: pdev_to_pnode() is used from __devinitAl Viro2008-12-041-1/+1
| | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
* fix the section noise in sparc head.SAl Viro2008-11-302-1/+2
| | | | | | | usual .text.head trick Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* sparc32 cpuinit flase positivesAl Viro2008-11-305-8/+8
| | | | | | | | | | | All noise since we don't have CPU hotplug there. However, they did expose something very odd-looking in there - poke_viking() does a bunch of identical btfixup each time it's called (i.e. for each CPU). That one is left alone for now; just the trivial misannotation fixes. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* sparc64: wire up accept4()David Miller2008-11-201-1/+1
| | | | | | | | | | This adds the sparc syscall hookups. Signed-off-by: David S. Miller <davem@davemloft.net> Cc: Ulrich Drepper <drepper@redhat.com> Cc: Michael Kerrisk <mtk.manpages@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* sparc: struct device - replace bus_id with dev_name(), dev_set_name()Kay Sievers2008-11-131-2/+2
| | | | | | Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* Revert "sparc: correct section of current_pc()"David S. Miller2008-11-101-1/+0
| | | | | | | | | This reverts commit 8dd9453737822469837d48d5da3785ce70fb2118. This fixes a boot failure reported by Robert Reif. The code above the section change expects to fallthrough, so we can't make such a section change here.
* rtc-m48t59: shift zero year to 1968 on sparc (rev 2)Krzysztof Helt2008-10-291-23/+4
| | | | | | | | | | | Shift the first year to 1968 for Sun SPARC machines. Move this logic from platform specific files to rtc driver as this fixes problems with calculating a century bit. Signed-off-by: Krzysztof Helt <krzysztof.h1@wp.pl> Tested-by: Alexander Beregalov Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: correct section of current_pc()Frederic Weisbecker2008-10-231-0/+1
| | | | | | | | | | | | | | | Latest mainline gives this section mismatch on sparc: The function current_pc() references the variable __init no_sun4u_here. This is often because current_pc lacks a __init annotation or the annotation of no_sun4u_here is wrong. Since current_pc() is used only in early time, it is correct to put it in .init section. Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc: correct section of apc_no_idleFrederic Weisbecker2008-10-231-1/+1
| | | | | | | | | | | | | | | | The latest mainline gives this section mismatch on sparc: The function __devinit apc_probe() references a variable __initdata apc_no_idle. If apc_no_idle is only used by apc_probe then annotate apc_no_idle with a matching annotation. Since the commit 7e7e2f035663c5ceb029bfb9d91e75099b0a5625, apc_probe() is on __devinit so we have to correct apc_no_idle which is referenced by this function. Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* sparc32: fix build errorsRobert Reif2008-10-132-0/+2
| | | | | | | | | | arch/sparc/kernel/sun4d_smp.c: In function ‘smp4d_callin’: arch/sparc/kernel/sun4d_smp.c:101: error: implicit declaration of function ‘notify_cpu_starting’ arch/sparc/kernel/sun4m_smp.c: In function ‘smp4m_callin’: arch/sparc/kernel/sun4m_smp.c:74: error: implicit declaration of function ‘notify_cpu_starting’ Signed-off-by: Robert Reif <reif@earthlink.net> Signed-off-by: David S. Miller <davem@davemloft.net>
* Merge branch 'master' of ↵David S. Miller2008-10-112-0/+3
|\ | | | | | | | | | | | | | | master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6 Conflicts: sound/core/memalloc.c
| * Merge branches 'sched/devel', 'sched/cpu-hotplug', 'sched/cpusets' and ↵Ingo Molnar2008-10-082-0/+3
| |\ | | | | | | | | | 'sched/urgent' into sched/core
| | * kernel/cpu.c: create a CPU_STARTING cpu_chain notifierManfred Spraul2008-09-082-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Right now, there is no notifier that is called on a new cpu, before the new cpu begins processing interrupts/softirqs. Various kernel function would need that notification, e.g. kvm works around by calling smp_call_function_single(), rcu polls cpu_online_map. The patch adds a CPU_STARTING notification. It also adds a helper function that sends the message to all cpu_chain handlers. Tested on x86-64. All other archs are untested. Especially on sparc, I'm not sure if I got it right. Signed-off-by: Manfred Spraul <manfred@colorfullife.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
* | | sparc32: sun4m interrupt mask cleanupRobert Reif2008-10-082-71/+91
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Here is an updated version of a patch I wrote 6 years ago http://marc.info/?l=linux-sparc&m=103939103607617&w=2 that simplifies interrupt mask lookup. It's main purpose is to add VME bus support but it's really a cleanup of the mask code. Signed-off-by: Robert Reif <reif@earthlink.net> Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc: arch/sparc/kernel/pmc.c -- extra #include?David Brownell2008-09-211-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | I have no SPARC compiler handy to verify, but it looks like this is another file that doesn't need <linux/miscdevices.h> ... Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Add more extensive documentation of sun4m interrupts.David S. Miller2008-09-201-0/+53
| | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Kill irq_rcvreg from sun4m_irq.cDavid S. Miller2008-09-201-6/+2
| | | | | | | | | | | | | | | | | | Unused. Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Delete master_l10_limit.David S. Miller2008-09-204-4/+0
| | | | | | | | | | | | | | | | | | It is only set, never used. Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Use PROM device probing for sun4c timers.David S. Miller2008-09-201-20/+39
| | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Use PROM device probing for sun4c interrupt register.David S. Miller2008-09-201-26/+21
| | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Delete claim_ticker14().David S. Miller2008-09-201-46/+0
| | | | | | | | | | | | | | | | | | No more users. Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Stop calling claim_ticker14() from sun4c_irq.cDavid S. Miller2008-09-201-1/+1
| | | | | | | | | | | | | | | | | | | | | Since the first argument is always NULL, the only side effect is to disable the PROFILE_IRQ, so just do that directly. Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Kill clear_profile_irq btfixup entry.David S. Miller2008-09-205-25/+0
| | | | | | | | | | | | | | | | | | Unused. Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Call sun4m_clear_profile_irq() directly from sun4m_smp.cDavid S. Miller2008-09-202-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the only use of the clear_profile_irq() btfixup entry, which just eats up lots of dead space on other platform types. A subsequent commit will delete the other implementations and the btfixup entry as well. Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Remove #if 0'd code from sun4c_irq.cDavid S. Miller2008-09-201-9/+0
| | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Remove some SMP ifdefs in sun4d_irq.cDavid S. Miller2008-09-201-26/+16
| | | | | | | | | | | | | | | | | | Always do the sbus_tid[] handling. Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Use PROM infrastructure for probing and mapping sun4d timers.David S. Miller2008-09-201-56/+83
| | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
* | | sparc32: Use PROM device probing for sun4m irq registers.David S. Miller2008-09-202-129/+74
| | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
* | | Merge branch 'master' of ↵David S. Miller2008-09-161-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 Conflicts: arch/sparc64/kernel/pci_psycho.c
| * | sparc: Fix user_regset 'n' field values.David S. Miller2008-09-131-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As noticed by Russell King, we were not setting this properly to the number of entries, but rather the total size. This results in the core dumping code allocating waayyyy too much memory. Signed-off-by: David S. Miller <davem@davemloft.net>
| * | sparc32: Fix function signature of of_bus_sbus_get_flags().David S. Miller2008-09-111-1/+1
| |/ | | | | | | | | | | | | This doesn't match the function pointer type it gets assigned to. Luckily, this was harmless. Signed-off-by: David S. Miller <davem@davemloft.net>
* | sparc32: Use PROM device probing for sun4m timer registers.David S. Miller2008-09-141-64/+57
| | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
* | sparc: Fix user_regset 'n' field values.David S. Miller2008-09-131-2/+2
| | | | | | | | | | | | | | | | | | | | As noticed by Russell King, we were not setting this properly to the number of entries, but rather the total size. This results in the core dumping code allocating waayyyy too much memory. Signed-off-by: David S. Miller <davem@davemloft.net>
* | sparc32: Call parse_early_param() in setup_arch().David S. Miller2008-09-111-0/+1
| | | | | | | | | | | | | | Mirror sparc64. This will allow us to use early_param() on sparc32 too. Signed-off-by: David S. Miller <davem@davemloft.net>
* | sparc32: Need to close openned RTC device just like sparc64.David S. Miller2008-09-101-3/+6
| | | | | | | | | | | | Otherwise we get refcount problems. Signed-off-by: David S. Miller <davem@davemloft.net>
* | sparc32: Move sun4d show_leds() out of asm/obio.hDavid S. Miller2008-09-092-1/+11
| | | | | | | | | | | | Put it, as well as cpu_leds[] array, into sun4d_irq.c Signed-off-by: David S. Miller <davem@davemloft.net>
* | sparc32: Fix coding style of sparc_cpu_model setting code.David S. Miller2008-09-091-7/+14
| | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
* | Merge branch 'master' of ↵David S. Miller2008-09-093-15/+32
|\| | | | | | | | | | | | | | | master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 Conflicts: arch/sparc/kernel/of_device.c
| * sparc: Fix resource flags for PCI children in OF device tree.David S. Miller2008-08-291-5/+14
| | | | | | | | | | | | | | | | | | | | | | | | When a device is under an EBUS or ISA bus, the resource flags don't get set properly. Fix this by re-evaluating the resource flags at each level of bus as we apply ranges on the way to the root. And let PCI override any existing flags setting, but don't let the default flags calculator make such overrides. Signed-off-by: David S. Miller <davem@davemloft.net>