2013-06-17 07:45:36

by Stephen Rothwell

[permalink] [raw]
Subject: linux-next: manual merge of the arm64-hugepages tree with the arm64 tree

Hi Steve,

Today's linux-next merge of the arm64-hugepages tree got conflicts in
arch/arm64/include/asm/pgtable-hwdef.h and
arch/arm64/include/asm/pgtable.h between commit 363116073a26 ("arm64:
KVM: define HYP and Stage-2 translation page flags") from the arm64 tree
and commits 072b1b62a643 ("ARM64: mm: Make PAGE_NONE pages read only and
no-execute") and af07484863e0 ("ARM64: mm: THP support") from the
arm64-hugepages tree.

I fixed it up (see below) and can carry the fix as necessary (no action
is required).

Note that the arm64 tree version of PMD_SECT_USER used a pteval_t where I
would have expected a pmdval_t like the arm64-hugepages tree version.
--
Cheers,
Stephen Rothwell [email protected]

diff --cc arch/arm64/include/asm/pgtable.h
index 5588e8a,720fc4a..0000000
--- a/arch/arm64/include/asm/pgtable.h
+++ b/arch/arm64/include/asm/pgtable.h
@@@ -76,13 -76,7 +76,13 @@@ extern pgprot_t pgprot_default
#define PAGE_KERNEL _MOD_PROT(pgprot_default, PTE_PXN | PTE_UXN | PTE_DIRTY)
#define PAGE_KERNEL_EXEC _MOD_PROT(pgprot_default, PTE_UXN | PTE_DIRTY)

+#define PAGE_HYP _MOD_PROT(pgprot_default, PTE_HYP)
+#define PAGE_HYP_DEVICE __pgprot(PROT_DEVICE_nGnRE | PTE_HYP)
+
+#define PAGE_S2 __pgprot_modify(pgprot_default, PTE_S2_MEMATTR_MASK, PTE_S2_MEMATTR(MT_S2_NORMAL) | PTE_S2_RDONLY)
+#define PAGE_S2_DEVICE __pgprot(PROT_DEFAULT | PTE_S2_MEMATTR(MT_S2_DEVICE_nGnRE) | PTE_S2_RDWR | PTE_UXN)
+
- #define __PAGE_NONE __pgprot(((_PAGE_DEFAULT) & ~PTE_TYPE_MASK) | PTE_PROT_NONE)
+ #define __PAGE_NONE __pgprot(((_PAGE_DEFAULT) & ~PTE_TYPE_MASK) | PTE_PROT_NONE | PTE_RDONLY | PTE_PXN | PTE_UXN)
#define __PAGE_SHARED __pgprot(_PAGE_DEFAULT | PTE_USER | PTE_NG | PTE_PXN | PTE_UXN)
#define __PAGE_SHARED_EXEC __pgprot(_PAGE_DEFAULT | PTE_USER | PTE_NG | PTE_PXN)
#define __PAGE_COPY __pgprot(_PAGE_DEFAULT | PTE_USER | PTE_NG | PTE_PXN | PTE_UXN | PTE_RDONLY)


Attachments:
(No filename) (1.88 kB)
(No filename) (836.00 B)
Download all attachments

2013-06-17 08:42:31

by Steve Capper

[permalink] [raw]
Subject: Re: linux-next: manual merge of the arm64-hugepages tree with the arm64 tree

On Mon, Jun 17, 2013 at 05:45:28PM +1000, Stephen Rothwell wrote:
> Hi Steve,

Hi Stephen,

>
> Today's linux-next merge of the arm64-hugepages tree got conflicts in
> arch/arm64/include/asm/pgtable-hwdef.h and
> arch/arm64/include/asm/pgtable.h between commit 363116073a26 ("arm64:
> KVM: define HYP and Stage-2 translation page flags") from the arm64 tree
> and commits 072b1b62a643 ("ARM64: mm: Make PAGE_NONE pages read only and
> no-execute") and af07484863e0 ("ARM64: mm: THP support") from the
> arm64-hugepages tree.
>
> I fixed it up (see below) and can carry the fix as necessary (no action
> is required).
>

Thanks, the fixup looks good to me.

> Note that the arm64 tree version of PMD_SECT_USER used a pteval_t where I
> would have expected a pmdval_t like the arm64-hugepages tree version.

Yes I think it should be a pmdval_t too, I will follow this up.

Cheers,
--
Steve

2013-06-17 09:01:10

by Marc Zyngier

[permalink] [raw]
Subject: Re: linux-next: manual merge of the arm64-hugepages tree with the arm64 tree

On 17/06/13 09:42, Steve Capper wrote:
> On Mon, Jun 17, 2013 at 05:45:28PM +1000, Stephen Rothwell wrote:
>> Hi Steve,
>
> Hi Stephen,
>
>>
>> Today's linux-next merge of the arm64-hugepages tree got conflicts in
>> arch/arm64/include/asm/pgtable-hwdef.h and
>> arch/arm64/include/asm/pgtable.h between commit 363116073a26 ("arm64:
>> KVM: define HYP and Stage-2 translation page flags") from the arm64 tree
>> and commits 072b1b62a643 ("ARM64: mm: Make PAGE_NONE pages read only and
>> no-execute") and af07484863e0 ("ARM64: mm: THP support") from the
>> arm64-hugepages tree.
>>
>> I fixed it up (see below) and can carry the fix as necessary (no action
>> is required).
>>
>
> Thanks, the fixup looks good to me.
>
>> Note that the arm64 tree version of PMD_SECT_USER used a pteval_t where I
>> would have expected a pmdval_t like the arm64-hugepages tree version.
>
> Yes I think it should be a pmdval_t too, I will follow this up.

Indeed, my bad. I'll fix this ASAP.

Thanks,

M.
--
Jazz is not dead. It just smells funny...