[PATCH v2] sh: Take into account the base of System RAM in virt_to_phys()

Magnus Damm magnus.damm at gmail.com
Wed Oct 12 04:24:23 EDT 2011


On Mon, Oct 3, 2011 at 10:05 AM, Simon Horman <horms at verge.net.au> wrote:
> 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 at verge.net.au>
>
> ---
>  kexec/arch/sh/kexec-sh.c |   45 ++++++++++++++++++++++++++++++++++++++++++++-
>  1 files changed, 44 insertions(+), 1 deletions(-)
>
> v2
> * Only use the base of System RAM as an offset into physical memory
>  if 32bit addressing is in use.

This version looks much better, thanks!

/ magnus



More information about the kexec mailing list