[PATCH 2/4] ARM: suspend: use idmap_pgd instead of suspend_pgd
catalin.marinas at arm.com
Fri Nov 18 11:43:55 EST 2011
On 16 November 2011 16:48, Will Deacon <will.deacon at arm.com> wrote:
> The ARM CPU suspend code requires cpu_resume_mmu to be identity mapped
> in order to re-enable the MMU when coming out of suspend. Currently,
> this is accomplished by maintaining a suspend_pgd with the relevant
> mapping put in place at init time.
> This patch replaces the use of suspend_pgd with the new idmap_pgd.
> cpu_resume_mmu is placed in the .idmap.text section so that it is
> included in the identity map.
> Tested-by: Lorenzo Pieralisi <Lorenzo.Pieralisi at arm.com>
> Signed-off-by: Will Deacon <will.deacon at arm.com>
> diff --git a/arch/arm/kernel/suspend.c b/arch/arm/kernel/suspend.c
> index 93a22d2..8880f94 100644
> --- a/arch/arm/kernel/suspend.c
> +++ b/arch/arm/kernel/suspend.c
> @@ -6,7 +6,7 @@
> #include <asm/suspend.h>
> #include <asm/tlbflush.h>
> -static pgd_t *suspend_pgd;
> +extern pgd_t *idmap_pgd;
We should move the extern declaration to pgtable.h where we have the
identity_mapping_*() function prototypes (we may need this in the
future for other things).
Reviewed-by: Catalin Marinas <catalin.marinas at arm.com>
More information about the linux-arm-kernel