lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20101122131114.GE31227@n2100.arm.linux.org.uk>
Date:	Mon, 22 Nov 2010 13:11:14 +0000
From:	Russell King - ARM Linux <linux@....linux.org.uk>
To:	Catalin Marinas <catalin.marinas@....com>
Cc:	linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 09/20] ARM: LPAE: Change setup_mm_for_reboot() to
	work with LPAE

On Fri, Nov 12, 2010 at 06:00:29PM +0000, Catalin Marinas wrote:
> diff --git a/arch/arm/mm/mmu.c b/arch/arm/mm/mmu.c
> index 4147cc6..3784acc 100644
> --- a/arch/arm/mm/mmu.c
> +++ b/arch/arm/mm/mmu.c
> @@ -1098,13 +1098,16 @@ void setup_mm_for_reboot(char mode)
>  	if (cpu_architecture() <= CPU_ARCH_ARMv5TEJ && !cpu_is_xscale())
>  		base_pmdval |= PMD_BIT4;
>  
> -	for (i = 0; i < FIRST_USER_PGD_NR + USER_PTRS_PER_PGD; i++, pgd++) {
> +	for (i = 0; i < TASK_SIZE >> PMD_SHIFT; i++) {
>  		unsigned long pmdval = (i << PMD_SHIFT) | base_pmdval;
>  		pmd_t *pmd;
> +		unsigned long addr = i << PMD_SHIFT;
>  
> -		pmd = pmd_off(pgd, i << PMD_SHIFT);
> +		pmd = pmd_off(pgd + pgd_index(addr), addr);
>  		pmd[0] = __pmd(pmdval);
> +#ifndef CONFIG_ARM_LPAE
>  		pmd[1] = __pmd(pmdval + (1 << (PMD_SHIFT - 1)));
> +#endif
>  		flush_pmd_entry(pmd);
>  	}

The same is required for the identity mapping code.  If this uses that
code, the problem becomes localized there.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ