summaryrefslogtreecommitdiff
path: root/kexec/arch/sh/kexec-sh.c
AgeCommit message (Collapse)Author
2015-02-25kexec: iomem: fix callbacks params for sh and x86 archsRoman Pen
Commit 4362bfac changes params for kexec_iomem_for_each_line from 'unsigned long' to 'unsigned long long'. This patch fixes forgotten changes for sh and x86 archs. Bug causes incorrect parsing of memory ranges. Signed-off-by: Roman Pen <r.peniaev@gmail.com> Cc: kexec@lists.infradead.org Signed-off-by: Simon Horman <horms@verge.net.au>
2013-10-03kexec: Remove unused -? option handlingGeoff Levand
The main kexec option code handles the -? option. Remove all the duplicate -? handlers in the arch code which are never used. Signed-off-by: Geoff Levand <geoff@infradead.org> for Huawei, Linaro Signed-off-by: Simon Horman <horms@verge.net.au>
2013-03-27kexec: Use die() to simplify codeZhang Yanfei
Use die() to simplify code. Signed-off-by: Zhang Yanfei <zhangyanfei@cn.fujitsu.com> Signed-off-by: Simon Horman <horms@verge.net.au>
2011-10-11sh: On 32bit segments may not be in P2Simon Horman
Cc: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2011-10-11sh: Correct logic errors in is_32bit()Simon Horman
This corrects logic errors so that is_32bit() can actually detect that it is running on a 32 bit system - something the original version I wrote failed at woefully. Signed-off-by: Simon Horman <horms@verge.net.au>
2011-10-05sh: Take into account the base of System RAM in virt_to_phys()Simon Horman
Previously virt_to_phys() assumed that physical memory always started at address 0. This is not always the case. Tested on an sh7757lcr (32bit system) whose only System RAM region is 40000000-4effffff and an ecovec24 (29bit system). Signed-off-by: Simon Horman <horms@verge.net.au>
2010-05-19kexec-tools: Fix option/argument parsingMatt Evans
The argument parsing is currently a bit broken as main()'s getopt_long() knows nothing about either the architecture-specific options or, even more specifically, the architecture-and-loader-specific options. This patch introduces new #defines for all architectures, KEXEC_ALL_OPTIONS and KEXEC_ALL_OPT_STR. These contain all possible options for a given build, and the getopt_long() passes in main() and arch_process_options() will now recognise arch- and loader-specific options; these will not be re-ordered in argv[], there is no confusion over which argv[] entry is the kernel filename, and using '--opt=foo' and '--opt foo' both work. All architectures have command line options (and #define OPT_BLAHs) consolidated into their include/arch/option.h files. x86_64 builds parts of i386/ as well, so now both share a single option.h file (with a symlink). Signed-off-by: Matt Evans <matt@ozlabs.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2010-02-02sh: Use size_t for zero_page_size parameter of kexec_sh_setup_zero_page()Simon Horman
This avoids comparisons between signed and unsigned integers. Signed-off-by: Simon Horman <horms@verge.net.au>
2010-02-02Use C99 initialisersSimon Horman
Signed-off-by: Simon Horman <horms@verge.net.au>
2010-02-02Mark unused parametersSimon Horman
Signed-off-by: Simon Horman <horms@verge.net.au>
2009-12-16kexec-sh: uImage support.Paul Mundt
This follows the ARM change, and wires up uImage support on SH, with all of the same caveats. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2008-09-05sh: Add vmlinux crash dump supportMagnus Damm
This patch adds SuperH crash dump support. The vmlinux loader is modified with crash dump hooks as on other architectures. SuperH does not need any backup region, so only the elf header is allocated from the top of the reserved memory window. The actual size of the memory window is passed to the secondary kernel on the command line using "mem=". The secondary kernel must be configured to match the reserved memory window, change kernel parameters CONFIG_MEMORY_START and CONFIG_MEMORY_SIZE. Linux-2.6.27 should be usable as primary kernel on SuperH, later kernel versions are needed to fully support secondary kernel /proc/vmcore. Signed-off-by: Magnus Damm <damm@igel.co.jp> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2008-09-05sh: Fix help text spellingMagnus Damm
Fix SuperH help text spelling. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Simon Horman <horms@verge.net.au>
2008-08-27sh: Add vmlinux supportMagnus Damm
Add SuperH vmlinux support through a zero-page aware elf loader. Only for kexec at this point, in the future kdump support will be added. Signed-off-by: Magnus Damm <damm@igel.co.jp> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2008-08-27sh: Autodetect zImage zero page addressMagnus Damm
Autodetect the zero page base address for zImages on SuperH. Signed-off-by: Magnus Damm <damm@igel.co.jp> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2008-08-27sh: Add virtual addresses supportMagnus Damm
Implement virtual-to-physical address conversion functions for SuperH. Signed-off-by: Magnus Damm <damm@igel.co.jp> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2008-08-27sh: Get system memory ranges from /proc/iomemMagnus Damm
Parse contents of /proc/iomem instead of hardcoding RAM ranges. Signed-off-by: Magnus Damm <damm@igel.co.jp> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2008-08-27sh: Add support for sh4al-dsp processorsMagnus Damm
Add support for sh4al-dsp processors such as sh7722. Signed-off-by: Magnus Damm <damm@igel.co.jp> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2008-05-21Factor uname-based native architecture detection into a common function.Jamey Sharp
This code was copy-pasted into every architecture and was basically identical. Besides producing a nice net reduction in code, this factors a portability challenge into a single function that can be easily replaced at build-time. Signed-off-by: Jamey Sharp <jamey@thetovacompany.com> Signed-off-by: Simon Horman <horms@verge.net.au>
2007-03-16kexec-tools: arch_options seems to be unused on shHorms
arch_options, declared in kexec/arch/sh/kexec-sh.c seems to be unused, so remove it. Signed-off-by: Simon Horman <horms@verge.net.au> Acked-by: Paul Mundt <lethal@linux-sh.org>
2007-03-16Remove duplicate MAX_LINEMagnus Damm
Remove duplicate MAX_LINE MAX_LINE is already defined in kexec/kexec.h Signed-off-by: Magnus Damm <magnus@valinux.co.jp> Signed-off-by: Simon Horman <horms@verge.net.au>
2007-03-16Kdump is not supported on ppc, s390, shMagnus Damm
Kdump is not supported on ppc, s390, sh So let's return that no crash kernel memory is found. Signed-off-by: Magnus Damm <magnus@valinux.co.jp> Signed-off-by: Simon Horman <horms@verge.net.au>
2007-02-08Trivial change adding sh4a to the sh targets.Paul Mundt
Trivial change adding sh4a to the sh targets. Signed-off-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2007-02-01kexec-tools: Upport for sh supportSimon Horman
Some minor changes needed for sh support to compile Signed-off-by: Simon Horman <horms@verge.net.au>
2007-02-01kexec-tools: Remove trailing whitespace in sh codeSimon Horman
Signed-off-by: Simon Horman <horms@verge.net.au>
2007-02-01kexec-tools: Add sh supportSimon Horman
Patch found on http://eggplant.ddo.jp/www/download/debian26/source/kexec-tools/kexec-tools_1.101-2sh.diff.gz According to Paul Mundt <lethal@linux-sh.org> it was originally by kogiidena <kogiidena@eggplant.ddo.jp> Signed-off-by: Simon Horman <horms@verge.net.au> Acked-by: Magnus Damm <magnus.damm@gmail.com>