Re: [PATCH v2] powerpc/64s: Fix __pte_needs_flush() false positive warning

2023-04-05 Thread Michael Ellerman
On Fri, 03 Mar 2023 09:59:47 +1100, Benjamin Gray wrote: > Userspace PROT_NONE ptes set _PAGE_PRIVILEGED, triggering a false > positive debug assertion that __pte_flags_need_flush() is not called > on a kernel mapping. > > Detect when it is a userspace PROT_NONE page by checking the required >

[PATCH v2] powerpc/64s: Fix __pte_needs_flush() false positive warning

2023-03-02 Thread Benjamin Gray
Userspace PROT_NONE ptes set _PAGE_PRIVILEGED, triggering a false positive debug assertion that __pte_flags_need_flush() is not called on a kernel mapping. Detect when it is a userspace PROT_NONE page by checking the required bits of PAGE_NONE are set, and none of the RWX bits are set.