diff mbox

ARM: mm: Fix missing XN flag for for MT_MEMORY_SO

Message ID 1358347762-14682-1-git-send-email-santosh.shilimkar@ti.com (mailing list archive)
State New, archived
Headers show

Commit Message

Santosh Shilimkar Jan. 16, 2013, 2:49 p.m. UTC
Commit 8fb54284ba6a {ARM: mm: Add strongly ordered descriptor support}
added XN flag at section level but missed it at PTE level.

Fix it by adding the L_PTE_XN to MT_MEMORY_SO PET descriptor.

Cc: Russell King <linux@arm.linux.org.uk>

Reported-by: Richard Woodruff <r-woodruff2@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
---
 arch/arm/mm/mmu.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Russell King - ARM Linux Jan. 16, 2013, 11:16 p.m. UTC | #1
On Wed, Jan 16, 2013 at 08:19:22PM +0530, Santosh Shilimkar wrote:
> Commit 8fb54284ba6a {ARM: mm: Add strongly ordered descriptor support}
> added XN flag at section level but missed it at PTE level.
> 
> Fix it by adding the L_PTE_XN to MT_MEMORY_SO PET descriptor.
> 
> Cc: Russell King <linux@arm.linux.org.uk>
> 
> Reported-by: Richard Woodruff <r-woodruff2@ti.com>
> Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
> ---

Hmm, yes. => patch system please.

>  arch/arm/mm/mmu.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/arm/mm/mmu.c b/arch/arm/mm/mmu.c
> index 9f06102..ce328c7 100644
> --- a/arch/arm/mm/mmu.c
> +++ b/arch/arm/mm/mmu.c
> @@ -283,7 +283,7 @@ static struct mem_type mem_types[] = {
>  	},
>  	[MT_MEMORY_SO] = {
>  		.prot_pte  = L_PTE_PRESENT | L_PTE_YOUNG | L_PTE_DIRTY |
> -				L_PTE_MT_UNCACHED,
> +				L_PTE_MT_UNCACHED | L_PTE_XN,
>  		.prot_l1   = PMD_TYPE_TABLE,
>  		.prot_sect = PMD_TYPE_SECT | PMD_SECT_AP_WRITE | PMD_SECT_S |
>  				PMD_SECT_UNCACHED | PMD_SECT_XN,
> -- 
> 1.7.9.5
>
Santosh Shilimkar Jan. 17, 2013, 6:20 a.m. UTC | #2
On Thursday 17 January 2013 04:46 AM, Russell King - ARM Linux wrote:
> On Wed, Jan 16, 2013 at 08:19:22PM +0530, Santosh Shilimkar wrote:
>> Commit 8fb54284ba6a {ARM: mm: Add strongly ordered descriptor support}
>> added XN flag at section level but missed it at PTE level.
>>
>> Fix it by adding the L_PTE_XN to MT_MEMORY_SO PET descriptor.
>>
>> Cc: Russell King <linux@arm.linux.org.uk>
>>
>> Reported-by: Richard Woodruff <r-woodruff2@ti.com>
>> Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
>> ---
>
> Hmm, yes. => patch system please.
>
7629/1 in patch system.

Regards,
Santosh
diff mbox

Patch

diff --git a/arch/arm/mm/mmu.c b/arch/arm/mm/mmu.c
index 9f06102..ce328c7 100644
--- a/arch/arm/mm/mmu.c
+++ b/arch/arm/mm/mmu.c
@@ -283,7 +283,7 @@  static struct mem_type mem_types[] = {
 	},
 	[MT_MEMORY_SO] = {
 		.prot_pte  = L_PTE_PRESENT | L_PTE_YOUNG | L_PTE_DIRTY |
-				L_PTE_MT_UNCACHED,
+				L_PTE_MT_UNCACHED | L_PTE_XN,
 		.prot_l1   = PMD_TYPE_TABLE,
 		.prot_sect = PMD_TYPE_SECT | PMD_SECT_AP_WRITE | PMD_SECT_S |
 				PMD_SECT_UNCACHED | PMD_SECT_XN,