summaryrefslogtreecommitdiff
path: root/arch/openrisc/kernel/setup.c
AgeCommit message (Collapse)Author
2017-02-06openrisc: add cache way information to cpuinfoStefan Kristiansson
Motivation for this is to be able to print the way information properly in print_cpuinfo(), instead of hardcoding it to one. Signed-off-by: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi> Signed-off-by: Jonas Bonn <jonas@southpole.se> [shorne@gmail.com fixed conflict with show_cpuinfo change] Signed-off-by: Stafford Horne <shorne@gmail.com>
2016-12-12openrisc: Updates after openrisc.net has been lostStafford Horne
The openrisc.net domain expired and was taken over by squatters. These updates point documentation to the new domain, mailing lists and git repos. Also, Jonas is not the main maintainer anylonger, he reviews changes but does not maintain a repo or sent pull requests. Updating this to add Stafford and Stefan who are the active maintainers. Acked-by: Olof Kindgren <olof.kindgren@gmail.com> Signed-off-by: Stafford Horne <shorne@gmail.com>
2016-12-12openrisc: Consolidate setup to use memblock instead of bootmemStafford Horne
Clearing out one todo item. Use the memblock boot time memory which is the current standard. Tested-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Jonas <jonas@southpole.se> Signed-off-by: Stafford Horne <shorne@gmail.com>
2016-12-12openrisc: remove the redundant of_platform_populateRob Herring
The of_platform_populate call in the openrisc arch code is now redundant as the DT core provides a default call. Openrisc has a NULL match table which means only top level nodes with compatible strings will have devices creates. The default version will also descend nodes in the match table such as "simple-bus" which should be fine as openrisc doesn't have any of these (though it is preferred that memory-mapped peripherals be grouped under a bus node(s)). Signed-off-by: Rob Herring <robh@kernel.org> Cc: Jonas Bonn <jonas@southpole.se> Tested-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Stafford Horne <shorne@gmail.com>
2015-04-15openrisc: remove use of seq_printf return valueJoe Perches
The seq_printf return value, because it's frequently misused, will eventually be converted to void. See: commit 1f33c41c03da ("seq_file: Rename seq_overflow() to seq_has_overflowed() and make public") Signed-off-by: Joe Perches <joe@perches.com> Cc: Jonas Bonn <jonas@southpole.se> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-11-15Merge tag 'for-3.13' of git://git.openrisc.net/~jonas/linuxLinus Torvalds
Pull OpenRISC updates from Jonas Bonn: - small cleanups to make allmodconfig pass - defconfig refresh - a handful of code sanitization patches * tag 'for-3.13' of git://git.openrisc.net/~jonas/linux: openrisc: Refactor or32_early_setup() openrisc: Remove unused declaration of __initramfs_start openrisc: Use the declarations provided by <asm/sections.h> openrisc: Refresh or1ksim_defconfig for v3.12 openrisc: Refactor 16-bit constant relocation openrisc: include: asm: Kbuild: add default "vga.h" openrisc: Makefile: append "-D__linux__" to KBUILD_CFLAGS
2013-11-15openrisc: Refactor or32_early_setup()Geert Uytterhoeven
- Change fdt pointer (passed from head.S) from unsigned int to void *, which allows to kill a cast, and makes it compatible with __dtb_start. - Use pr_info(), - Extract common part. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: linux@lists.openrisc.net Signed-off-by: Jonas Bonn <jonas@southpole.se>
2013-11-15openrisc: Use the declarations provided by <asm/sections.h>Geert Uytterhoeven
Openrisc's private vmlinux.h duplicates a few definitions that are already provided by asm-generic/sections.h. The former is used by setup.c only, while the latter is already used everywhere else. Convert setup.c to use the generic version: - Include <asm/sections.h>, - Remove the (slightly different) extern declarations, - Remove the no longer needed address-of ('&') operators. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Jonas Bonn <jonas@southpole.se>
2013-10-09openrisc: use unflatten_and_copy_device_treeRob Herring
Use the common unflatten_and_copy_device_tree to copy the built-in FDT out of init section. This moves the copy later in the boot, but there do not appear to be any references to strings in the FDT before the copy. Signed-off-by: Rob Herring <rob.herring@calxeda.com> Cc: Jonas Bonn <jonas@southpole.se> Cc: linux@lists.openrisc.net
2013-10-09openrisc: use boot_command_line instead of private cmd_lineRob Herring
Save some pointless copying of the kernel command line and just use boot_command_line instead. The DT code already handles CONFIG_CMDLINE, so a separate copy is not needed. Signed-off-by: Rob Herring <rob.herring@calxeda.com> Cc: Jonas Bonn <jonas@southpole.se> Cc: linux@lists.openrisc.net Reviewed-by: Grant Likely <grant.likely@linaro.org>
2013-07-14openrisc: delete __cpuinit usage from all openrisc filesPaul Gortmaker
The __cpuinit type of throwaway sections might have made sense some time ago when RAM was more constrained, but now the savings do not offset the cost and complications. For example, the fix in commit 5e427ec2d0 ("x86: Fix bit corruption at CPU resume time") is a good example of the nasty type of bugs that can be created with improper use of the various __init prefixes. After a discussion on LKML[1] it was decided that cpuinit should go the way of devinit and be phased out. Once all the users are gone, we can then finally remove the macros themselves from linux/init.h. Note that some harmless section mismatch warnings may result, since notify_cpu_starting() and cpu_up() are arch independent (kernel/cpu.c) are flagged as __cpuinit -- so if we remove the __cpuinit from arch specific callers, we will also get section mismatch warnings. As an intermediate step, we intend to turn the linux/init.h cpuinit content into no-ops as early as possible, since that will get rid of these warnings. In any case, they are temporary and harmless. This removes all the arch/openrisc uses of the __cpuinit macros from all C files. Currently openrisc does not have any __CPUINIT used in assembly files. [1] https://lkml.org/lkml/2013/5/20/589 Cc: Jonas Bonn <jonas@southpole.se> Cc: linux@lists.openrisc.net Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
2012-03-28Merge tag 'split-asm_system_h-for-linus-20120328' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-asm_system Pull "Disintegrate and delete asm/system.h" from David Howells: "Here are a bunch of patches to disintegrate asm/system.h into a set of separate bits to relieve the problem of circular inclusion dependencies. I've built all the working defconfigs from all the arches that I can and made sure that they don't break. The reason for these patches is that I recently encountered a circular dependency problem that came about when I produced some patches to optimise get_order() by rewriting it to use ilog2(). This uses bitops - and on the SH arch asm/bitops.h drags in asm-generic/get_order.h by a circuituous route involving asm/system.h. The main difficulty seems to be asm/system.h. It holds a number of low level bits with no/few dependencies that are commonly used (eg. memory barriers) and a number of bits with more dependencies that aren't used in many places (eg. switch_to()). These patches break asm/system.h up into the following core pieces: (1) asm/barrier.h Move memory barriers here. This already done for MIPS and Alpha. (2) asm/switch_to.h Move switch_to() and related stuff here. (3) asm/exec.h Move arch_align_stack() here. Other process execution related bits could perhaps go here from asm/processor.h. (4) asm/cmpxchg.h Move xchg() and cmpxchg() here as they're full word atomic ops and frequently used by atomic_xchg() and atomic_cmpxchg(). (5) asm/bug.h Move die() and related bits. (6) asm/auxvec.h Move AT_VECTOR_SIZE_ARCH here. Other arch headers are created as needed on a per-arch basis." Fixed up some conflicts from other header file cleanups and moving code around that has happened in the meantime, so David's testing is somewhat weakened by that. We'll find out anything that got broken and fix it.. * tag 'split-asm_system_h-for-linus-20120328' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-asm_system: (38 commits) Delete all instances of asm/system.h Remove all #inclusions of asm/system.h Add #includes needed to permit the removal of asm/system.h Move all declarations of free_initmem() to linux/mm.h Disintegrate asm/system.h for OpenRISC Split arch_align_stack() out from asm-generic/system.h Split the switch_to() wrapper out of asm-generic/system.h Move the asm-generic/system.h xchg() implementation to asm-generic/cmpxchg.h Create asm-generic/barrier.h Make asm-generic/cmpxchg.h #include asm-generic/cmpxchg-local.h Disintegrate asm/system.h for Xtensa Disintegrate asm/system.h for Unicore32 [based on ver #3, changed by gxt] Disintegrate asm/system.h for Tile Disintegrate asm/system.h for Sparc Disintegrate asm/system.h for SH Disintegrate asm/system.h for Score Disintegrate asm/system.h for S390 Disintegrate asm/system.h for PowerPC Disintegrate asm/system.h for PA-RISC Disintegrate asm/system.h for MN10300 ...
2012-03-28Disintegrate asm/system.h for OpenRISCDavid Howells
Disintegrate asm/system.h for OpenRISC. Not compiled. Signed-off-by: David Howells <dhowells@redhat.com> Acked-by: Arnd Bergmann <arnd@arndb.de> cc: linux@lists.openrisc.net
2012-02-17openrisc: enable passing of flattened device tree pointerStefan Kristiansson
This patch enables passing a fdt pointer to the kernel. This makes for the kernel parameter API: void kernel(unsigned int fdt); which, in accordance with the OpenRISC ABI results in: r3 = pointer to fdt Signed-off-by: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi> Signed-off-by: Jonas Bonn <jonas@southpole.se>
2011-07-22OpenRISC: Boot codeJonas Bonn
Architecture code and early setup routines for booting Linux. Signed-off-by: Jonas Bonn <jonas@southpole.se> Reviewed-by: Arnd Bergmann <arnd@arndb.de>