Re: [PATCH RFC v3 1/2] mm: Add personality flag to limit address to 47 bits

2024-09-10 Thread Christophe Leroy
diff --git a/include/uapi/linux/personality.h b/include/uapi/linux/personality.h index 49796b7756af..cd3b8c154d9b 100644 --- a/include/uapi/linux/personality.h +++ b/include/uapi/linux/personality.h @@ -22,6 +22,7 @@ enum { WHOLE_SECONDS = 0x200, STICKY_TIMEOUTS =

Re: [PATCH v2 7/8] execmem: add support for cache of large ROX pages

2024-09-06 Thread Christophe Leroy
Le 26/08/2024 à 08:55, Mike Rapoport a écrit : From: "Mike Rapoport (Microsoft)" Using large pages to map text areas reduces iTLB pressure and improves performance. Extend execmem_alloc() with an ability to use PMD_SIZE'ed pages with ROX permissions as a cache for smaller allocations. Why

Re: [PATCH RFC v2 2/4] mm: Add hint and mmap_flags to struct vm_unmapped_area_info

2024-09-03 Thread Christophe Leroy
Hi Charlie, Le 29/08/2024 à 09:15, Charlie Jenkins a écrit : The hint address and mmap_flags are necessary to determine if MAP_BELOW_HINT requirements are satisfied. Signed-off-by: Charlie Jenkins --- arch/alpha/kernel/osf_sys.c | 2 ++ arch/arc/mm/mmap.c | 3 +++ arch/a

Re: [PATCH v2 5/9] mm: Initialize struct vm_unmapped_area_info

2024-03-04 Thread Christophe Leroy
Le 02/03/2024 à 02:51, Kees Cook a écrit : > On Sat, Mar 02, 2024 at 12:47:08AM +, Edgecombe, Rick P wrote: >> On Wed, 2024-02-28 at 09:21 -0800, Kees Cook wrote: >>> I totally understand. If the "uninitialized" warnings were actually >>> reliable, I would agree. I look at it this way: >>> >>

Re: [PATCH v2 5/9] mm: Initialize struct vm_unmapped_area_info

2024-02-28 Thread Christophe Leroy
Le 28/02/2024 à 18:01, Edgecombe, Rick P a écrit : > On Wed, 2024-02-28 at 13:22 +0000, Christophe Leroy wrote: >>> Any preference? Or maybe am I missing your point and talking >>> nonsense? >>> >> >> So my preference would go to the addition of: &g

Re: [PATCH v2 5/9] mm: Initialize struct vm_unmapped_area_info

2024-02-28 Thread Christophe Leroy
Le 27/02/2024 à 21:25, Edgecombe, Rick P a écrit : > On Tue, 2024-02-27 at 18:16 +0000, Christophe Leroy wrote: >>>> Why doing a full init of the struct when all fields are re- >>>> written a few >>>> lines after ? >>> >>> It'

Re: [PATCH v2 5/9] mm: Initialize struct vm_unmapped_area_info

2024-02-27 Thread Christophe Leroy
Le 27/02/2024 à 19:07, Kees Cook a écrit : > On Tue, Feb 27, 2024 at 07:02:59AM +0000, Christophe Leroy wrote: >> >> >> Le 26/02/2024 à 20:09, Rick Edgecombe a écrit : >>> Future changes will need to add a field to struct vm_unmapped_area_info. >>> This

Re: [PATCH 1/4] arch: consolidate existing CONFIG_PAGE_SIZE_*KB definitions

2024-02-27 Thread Christophe Leroy
Le 27/02/2024 à 16:40, Arnd Bergmann a écrit : > On Mon, Feb 26, 2024, at 17:55, Samuel Holland wrote: >> On 2024-02-26 10:14 AM, Arnd Bergmann wrote: >>> >>> +config HAVE_PAGE_SIZE_4KB >>> + bool >>> + >>> +config HAVE_PAGE_SIZE_8KB >>> + bool >>> + >>> +config HAVE_PAGE_SIZE_16KB >>> +

Re: [PATCH v2 5/9] mm: Initialize struct vm_unmapped_area_info

2024-02-26 Thread Christophe Leroy
Le 26/02/2024 à 20:09, Rick Edgecombe a écrit : > Future changes will need to add a field to struct vm_unmapped_area_info. > This would cause trouble for any archs that don't initialize the > struct. Currently every user sets each field, so if new fields are > added, the core code parsing the str

Re: [PATCH 2/4] arch: simplify architecture specific page size configuration

2024-02-26 Thread Christophe Leroy
e > leaving the arhcitecture specific ones as the user visible > place for configuring it, to avoid breaking user configs. > > Signed-off-by: Arnd Bergmann Reviewed-by: Christophe Leroy (powerpc32) > --- > arch/arc/Kconfig | 3 +++ > arch/arc/include/uapi/as

Re: [PATCH 1/4] arch: consolidate existing CONFIG_PAGE_SIZE_*KB definitions

2024-02-26 Thread Christophe Leroy
Le 26/02/2024 à 17:14, Arnd Bergmann a écrit : > From: Arnd Bergmann > > These four architectures define the same Kconfig symbols for configuring > the page size. Move the logic into a common place where it can be shared > with all other architectures. > > Signed-off-by: Arnd Bergmann > --- >

Re: [PATCH 4/4] vdso: avoid including asm/page.h

2024-02-26 Thread Christophe Leroy
Le 26/02/2024 à 17:14, Arnd Bergmann a écrit : > From: Arnd Bergmann > > The recent change to the vdso_data_store broke building compat VDSO > on at least arm64 because it includes headers outside of the include/vdso/ > namespace: I understand that powerpc64 also has an issue, see https://pat

Re: [PATCH 15/22] arch: vdso: consolidate gettime prototypes

2023-11-09 Thread Christophe Leroy
Le 09/11/2023 à 11:18, Michael Ellerman a écrit : > "Arnd Bergmann" writes: >> On Wed, Nov 8, 2023, at 19:31, Christophe Leroy wrote: >>> Le 08/11/2023 à 13:58, Arnd Bergmann a écrit : >> >>> powerpc has functions doing more or less the same, they ar

Re: [PATCH 15/22] arch: vdso: consolidate gettime prototypes

2023-11-08 Thread Christophe Leroy
Le 08/11/2023 à 20:37, Arnd Bergmann a écrit : > On Wed, Nov 8, 2023, at 19:31, Christophe Leroy wrote: >> Le 08/11/2023 à 13:58, Arnd Bergmann a écrit : > >> powerpc has functions doing more or less the same, they are called >> __c_kernel_clock_gettime() and alike with

Re: [PATCH 15/22] arch: vdso: consolidate gettime prototypes

2023-11-08 Thread Christophe Leroy
Hi Arnd, Le 08/11/2023 à 13:58, Arnd Bergmann a écrit : > From: Arnd Bergmann > > The VDSO functions are defined as globals in the kernel sources but intended > to be called from userspace, so there is no need to declare them in a kernel > side header. > > Without a prototype, this now causes w

Re: [PATCH] treewide: drop CONFIG_EMBEDDED

2023-08-19 Thread Christophe Leroy
Hi, Le 19/08/2023 à 05:33, Jesse T a écrit : >>> Should there be a warning here to update change it instead of removal? >>> >>> kconfig doesn't have a warning mechanism AFAIK. >>> Do you have an idea of how this would work? > > No, unfortunately. As you said without a warning it would be ove

Re: [PATCH 16/17] [RFC] arch: turn -Wmissing-prototypes off conditionally

2023-08-10 Thread Christophe Leroy
Le 10/08/2023 à 16:19, Arnd Bergmann a écrit : > From: Arnd Bergmann > > I have cleaned up the -Wmissing-prototypes warnings for most of the major > architectures > as well as all drivers that get enabled for CONFIG_COMPILE_TEST, so now these > should be > close to fixed on x86, arm, arm64, p

Re: [PATCH 06/21] powerpc: dma-mapping: minimize for_cpu flushing

2023-03-27 Thread Christophe Leroy
Le 27/03/2023 à 14:13, Arnd Bergmann a écrit : > From: Arnd Bergmann > > The powerpc dma_sync_*_for_cpu() variants do more flushes than on other > architectures. Reduce it to what everyone else does: > > - No flush is needed after data has been sent to a device > > - When data has been re

Re: [PATCH v7 13/41] mm: Make pte_mkwrite() take a VMA

2023-02-28 Thread Christophe Leroy
Le 27/02/2023 à 23:29, Rick Edgecombe a écrit : > The x86 Control-flow Enforcement Technology (CET) feature includes a new > type of memory called shadow stack. This shadow stack memory has some > unusual properties, which requires some core mm changes to function > properly. > > One of these un

Re: [PATCH mm-unstable RFC 17/26] powerpc/mm: support __HAVE_ARCH_PTE_SWP_EXCLUSIVE on 32bit book3s

2022-12-07 Thread Christophe Leroy
ng yet > unused LSB 2 / MSB 29. There seems to be no real reason why that bit cannot > be used, and reusing it avoids having to steal one bit from the swap > offset. > > While at it, mask the type in __swp_entry(). > > Cc: Michael Ellerman > Cc: Nicholas Piggin > Cc

Re: [PATCH v3 05/11] arc: mm: Convert to GENERIC_IOREMAP

2022-10-12 Thread Christophe Leroy
Le 09/10/2022 à 12:31, Baoquan He a écrit : > By taking GENERIC_IOREMAP method, the generic ioremap_prot() and > iounmap() are visible and available to arch. Arch only needs to > provide implementation of arch_ioremap() or arch_iounmap() if there's > arch specific handling needed in its ioremap()

[RFC PATCH 5/8] arc: mm: Convert to GENERIC_IOREMAP

2022-10-12 Thread Christophe Leroy
7;s own ioremap() because arc has some special handling in ioremap() than standard ioremap(). Signed-off-by: Baoquan He Cc: Vineet Gupta Cc: linux-snps-arc@lists.infradead.org Signed-off-by: Christophe Leroy --- arch/arc/Kconfig | 1 + arch/arc/include/asm/io.h | 7 +++--- arch/a

Re: [PATCH V6 00/26] mm/mmap: Drop __SXXX/__PXXX macros from across platforms

2022-07-05 Thread Christophe Leroy
Le 06/07/2022 à 07:57, Anshuman Khandual a écrit : > > > On 6/30/22 10:46, Anshuman Khandual wrote: >> __SXXX/__PXXX macros is an unnecessary abstraction layer in creating the >> generic protection_map[] array which is used for vm_get_page_prot(). This >> abstraction layer can be avoided, if th

Re: [PATCH V5 26/26] mm/mmap: Drop ARCH_HAS_VM_GET_PAGE_PROT

2022-06-26 Thread Christophe Leroy
t; Just drop this fallback and also ARCH_HAS_GET_PAGE_PROT mechanism. > > Cc: Andrew Morton > Cc: linux...@kvack.org > Cc: linux-ker...@vger.kernel.org > Reviewed-by: Christoph Hellwig > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- > arch/al

Re: [PATCH V5 07/26] mm/mmap: Build protect protection_map[] with ARCH_HAS_VM_GET_PAGE_PROT

2022-06-26 Thread Christophe Leroy
: Andrew Morton > Cc: linux...@kvack.org > Cc: linux-ker...@vger.kernel.org > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- > include/linux/mm.h | 2 +- > mm/mmap.c | 5 + > 2 files changed, 2 insertions(+), 5 deletions(-) > >

Re: [PATCH V5 03/26] powerpc/mm: Move protection_map[] inside the platform

2022-06-26 Thread Christophe Leroy
ul Mackerras > Cc: Nicholas Piggin > Cc: linuxppc-...@lists.ozlabs.org > Cc: linux-ker...@vger.kernel.org > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- > arch/powerpc/Kconfig | 2 +- > arch/powerpc/include/asm/pgtable.h | 20 +

Re: [PATCH V5 02/26] mm/mmap: Define DECLARE_VM_GET_PAGE_PROT

2022-06-26 Thread Christophe Leroy
reate any > functional change. > > Cc: Andrew Morton > Cc: linux...@kvack.org > Cc: linux-ker...@vger.kernel.org > Suggested-by: Christoph Hellwig > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- > include/linux/pgtable.h | 28 +

Re: [PATCH V5 01/26] mm/mmap: Build protect protection_map[] with __P000

2022-06-26 Thread Christophe Leroy
> be used for this purpose as only certain platforms enable this config now. > > Cc: Andrew Morton > Cc: linux...@kvack.org > Cc: linux-ker...@vger.kernel.org > Reviewed-by: Christoph Hellwig > Suggested-by: Christophe Leroy > Signed-off-by: Anshuman Khandua

Re: [PATCH V4 26/26] mm/mmap: Drop ARCH_HAS_VM_GET_PAGE_PROT

2022-06-26 Thread Christophe Leroy
t; Just drop this fallback and also ARCH_HAS_GET_PAGE_PROT mechanism. > > Cc: Andrew Morton > Cc: linux...@kvack.org > Cc: linux-ker...@vger.kernel.org > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- > arch/alpha/Kconfig | 1 - > arch/ar

Re: [PATCH V4 02/26] mm/mmap: Define DECLARE_VM_GET_PAGE_PROT

2022-06-26 Thread Christophe Leroy
reate any > functional change. > > Cc: Andrew Morton > Cc: linux...@kvack.org > Cc: linux-ker...@vger.kernel.org > Suggested-by: Christoph Hellwig > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- > include/linux/mm.h | 8 > mm/mmap.c

Re: [PATCH V4 07/26] mm/mmap: Build protect protection_map[] with ARCH_HAS_VM_GET_PAGE_PROT

2022-06-26 Thread Christophe Leroy
: Andrew Morton > Cc: linux...@kvack.org > Cc: linux-ker...@vger.kernel.org > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- > include/linux/mm.h | 2 +- > mm/mmap.c | 5 + > 2 files changed, 2 insertions(+), 5 deletions(-) > >

Re: [PATCH V4 03/26] powerpc/mm: Move protection_map[] inside the platform

2022-06-26 Thread Christophe Leroy
in > Cc: linuxppc-...@lists.ozlabs.org > Cc: linux-ker...@vger.kernel.org > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- > arch/powerpc/Kconfig | 2 +- > arch/powerpc/include/asm/pgtable.h | 20 +--- >

Re: [PATCH V4 01/26] mm/mmap: Build protect protection_map[] with __P000

2022-06-26 Thread Christophe Leroy
> be used for this purpose as only certain platforms enable this config now. > > Cc: Andrew Morton > Cc: linux...@kvack.org > Cc: linux-ker...@vger.kernel.org > Suggested-by: Christophe Leroy > Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy > --- >

Re: [PATCH V4 26/26] mm/mmap: Drop ARCH_HAS_VM_GET_PAGE_PROT

2022-06-23 Thread Christophe Leroy
Le 24/06/2022 à 06:43, Anshuman Khandual a écrit : > Now all the platforms enable ARCH_HAS_GET_PAGE_PROT. They define and export > own vm_get_page_prot() whether custom or standard DECLARE_VM_GET_PAGE_PROT. > Hence there is no need for default generic fallback for vm_get_page_prot(). > Just drop

Re: [PATCH V4 02/26] mm/mmap: Define DECLARE_VM_GET_PAGE_PROT

2022-06-23 Thread Christophe Leroy
Le 24/06/2022 à 06:43, Anshuman Khandual a écrit : > This just converts the generic vm_get_page_prot() implementation into a new > macro i.e DECLARE_VM_GET_PAGE_PROT which later can be used across platforms > when enabling them with ARCH_HAS_VM_GET_PAGE_PROT. This does not create any > functional

Re: [PATCH V4 08/26] microblaze/mm: Enable ARCH_HAS_VM_GET_PAGE_PROT

2022-06-23 Thread Christophe Leroy
Le 24/06/2022 à 06:43, Anshuman Khandual a écrit : > This enables ARCH_HAS_VM_GET_PAGE_PROT on the platform and exports standard > vm_get_page_prot() implementation via DECLARE_VM_GET_PAGE_PROT, which looks > up a private and static protection_map[] array. Subsequently all __SXXX and > __PXXX mac

Re: [PATCH V4 07/26] mm/mmap: Build protect protection_map[] with ARCH_HAS_VM_GET_PAGE_PROT

2022-06-23 Thread Christophe Leroy
Le 24/06/2022 à 06:43, Anshuman Khandual a écrit : > protection_map[] has already been moved inside those platforms which enable Usually "already" means before your series. Your series is the one that moves protection_map[] so I would have just said "Now that protection_map[] has been moved in

Re: [PATCH V4 03/26] powerpc/mm: Move protection_map[] inside the platform

2022-06-23 Thread Christophe Leroy
Le 24/06/2022 à 06:43, Anshuman Khandual a écrit : > This moves protection_map[] inside the platform and while here, also enable > ARCH_HAS_VM_GET_PAGE_PROT on 32 bit platforms via DECLARE_VM_GET_PAGE_PROT. Not only 32 bit platforms, also nohash 64 (aka book3e/64) > > Cc: Michael Ellerman > C

Re: [PATCH V3 09/30] arm/mm: Enable ARCH_HAS_VM_GET_PAGE_PROT

2022-03-01 Thread Christophe Leroy
Le 02/03/2022 à 04:22, Anshuman Khandual a écrit : > > > On 3/1/22 1:46 PM, Christophe Leroy wrote: >> >> >> Le 01/03/2022 à 01:31, Russell King (Oracle) a écrit : >>> On Tue, Mar 01, 2022 at 05:30:41AM +0530, Anshuman Khandual wrote: >>>>

Re: [PATCH V3 09/30] arm/mm: Enable ARCH_HAS_VM_GET_PAGE_PROT

2022-03-01 Thread Christophe Leroy
Le 01/03/2022 à 01:31, Russell King (Oracle) a écrit : > On Tue, Mar 01, 2022 at 05:30:41AM +0530, Anshuman Khandual wrote: >> On 2/28/22 4:27 PM, Russell King (Oracle) wrote: >>> On Mon, Feb 28, 2022 at 04:17:32PM +0530, Anshuman Khandual wrote: This defines and exports a platform specific

Re: [PATCH v2 00/18] clean up asm/uaccess.h, kill set_fs for good

2022-02-18 Thread Christophe Leroy
Le 18/02/2022 à 02:50, Al Viro a écrit : > On Thu, Feb 17, 2022 at 07:20:11AM +0000, Christophe Leroy wrote: > >> And we have also >> user_access_begin()/user_read_access_begin()/user_write_access_begin() >> which call access_ok() then do the real work. Could be made

Re: [PATCH v2 00/18] clean up asm/uaccess.h, kill set_fs for good

2022-02-16 Thread Christophe Leroy
Le 16/02/2022 à 14:13, Arnd Bergmann a écrit : > From: Arnd Bergmann > > Christoph Hellwig and a few others spent a huge effort on removing > set_fs() from most of the important architectures, but about half the > other architectures were never completed even though most of them don't > actuall

Re: [PATCH 08/14] arm64: simplify access_ok()

2022-02-16 Thread Christophe Leroy
Le 15/02/2022 à 10:12, Arnd Bergmann a écrit : > On Tue, Feb 15, 2022 at 9:17 AM Ard Biesheuvel wrote: >> On Mon, 14 Feb 2022 at 17:37, Arnd Bergmann wrote: >>> From: Arnd Bergmann >>> >> >> With set_fs() out of the picture, wouldn't it be sufficient to check >> that bit #55 is clear? (the bit

Re: [PATCH 3/3] memblock: cleanup memblock_free interface

2021-09-23 Thread Christophe Leroy
Le 23/09/2021 à 14:01, Mike Rapoport a écrit : On Thu, Sep 23, 2021 at 11:47:48AM +0200, Christophe Leroy wrote: Le 23/09/2021 à 09:43, Mike Rapoport a écrit : From: Mike Rapoport For ages memblock_free() interface dealt with physical addresses even despite the existence of

Re: [PATCH 3/3] memblock: cleanup memblock_free interface

2021-09-23 Thread Christophe Leroy
Le 23/09/2021 à 09:43, Mike Rapoport a écrit : From: Mike Rapoport For ages memblock_free() interface dealt with physical addresses even despite the existence of memblock_alloc_xx() functions that return a virtual pointer. Introduce memblock_phys_free() for freeing physical ranges and repurp

Re: [PATCH v3 resend 01/15] mm: add setup_initial_init_mm() helper

2021-06-08 Thread Christophe Leroy
Le 08/06/2021 à 16:53, Souptick Joarder a écrit : On Tue, Jun 8, 2021 at 1:56 PM Kefeng Wang wrote: Add setup_initial_init_mm() helper to setup kernel text, data and brk. Cc: linux-snps-arc@lists.infradead.org Cc: linux-arm-ker...@lists.infradead.org Cc: linux-c...@vger.kernel.org Cc: uclin

Re: [PATCH v2 00/15] init_mm: cleanup ARCH's text/data/brk setup code

2021-06-06 Thread Christophe Leroy
Hi Kefeng, Le 07/06/2021 à 02:55, Kefeng Wang a écrit : On 2021/6/7 5:29, Mike Rapoport wrote: Hello Kefeng, On Fri, Jun 04, 2021 at 03:06:18PM +0800, Kefeng Wang wrote: Add setup_initial_init_mm() helper, then use it to cleanup the text, data and brk setup code. v2: - change argument from

Re: [PATCH] init: consolidate trap_init()

2021-04-14 Thread Christophe Leroy
Le 14/04/2021 à 10:58, Jisheng Zhang a écrit : Many architectures implement the trap_init() as NOP, since there is no such default for trap_init(), this empty stub is duplicated among these architectures. Provide a generic but weak NOP implementation to drop the empty stubs of trap_init() in th

Re: [PATCH] mm: Define ARCH_HAS_FIRST_USER_ADDRESS

2021-04-13 Thread Christophe Leroy
Le 14/04/2021 à 07:59, Anshuman Khandual a écrit : On 4/14/21 10:52 AM, Christophe Leroy wrote: Le 14/04/2021 à 04:54, Anshuman Khandual a écrit : Currently most platforms define FIRST_USER_ADDRESS as 0UL duplicating the same code all over. Instead define a new option

Re: [PATCH] mm: Define ARCH_HAS_FIRST_USER_ADDRESS

2021-04-13 Thread Christophe Leroy
Le 14/04/2021 à 04:54, Anshuman Khandual a écrit : Currently most platforms define FIRST_USER_ADDRESS as 0UL duplicating the same code all over. Instead define a new option ARCH_HAS_FIRST_USER_ADDRESS for those platforms which would override generic default FIRST_USER_ADDRESS value 0UL. This ma

Re: [PATCH v2] mm: Move mem_init_print_info() into mm_init()

2021-03-16 Thread Christophe Leroy
xtern void mem_init_print_info(void); Sorry I didn't see that in previous patch. 'extern' keyword is pointless for function prototypes and is deprecated, you should remove it. That said, Reviewed-by: Christophe Leroy # focussed on powerpc extern void reserve_bootmem_region(phys_addr

Re: [PATCH RESEND] mm: Move mem_init_print_info() into mm_init()

2021-03-16 Thread Christophe Leroy
Le 16/03/2021 à 16:29, Kefeng Wang a écrit : mem_init_print_info() is called in mem_init() on each architecture, and pass NULL argument, so using void argument and move it into mm_init(). Signed-off-by: Kefeng Wang --- Resend with 'str' line cleanup, and only test on ARM64 qemu. arch/alph

Re: [PATCH] mm: Move mem_init_print_info() into mm_init()

2021-03-16 Thread Christophe Leroy
Le 16/03/2021 à 15:26, Kefeng Wang a écrit : mem_init_print_info() is called in mem_init() on each architecture, and pass NULL argument, cleanup it by using void argument and move it into mm_init(). Signed-off-by: Kefeng Wang --- arch/alpha/mm/init.c | 1 - arch/arc/mm/init.c

Re: [patch V2 00/18] mm/highmem: Preemptible variant of kmap_atomic & friends

2020-10-31 Thread Christophe Leroy
There are also some users on 10+ year old 32-bit netbooks or business laptops, both x86 and Apple G4. The longest-lived 32-bit embedded systems with large memory (other than Arm) are probably NXP QorIQ P20xx/P40xx used in military VME bus systems, and low-end embedded systems based on Vortex86.

Re: [PATCH v2 00/13] mm/debug_vm_pgtable fixes

2020-09-01 Thread Christophe Leroy
Leroy Please don't use anymore the above address. Only use the one below. + Christophe Leroy + Vineet Gupta + Mike Rapoport + Qian Cai Thanks Christophe ___ linux-snps-arc mailing list linux-snps-arc@lists.infradead.org

Re: [PATCH v3 12/13] mm/debug_vm_pgtable/hugetlb: Disable hugetlb test on ppc64

2020-09-01 Thread Christophe Leroy
Le 01/09/2020 à 08:30, Aneesh Kumar K.V a écrit : I actually wanted to add #ifdef BROKEN. That test is completely broken. Infact I would suggest to remove that test completely. #ifdef will not be required here as there would be a stub definition for hugetlb_advanced_tests() when CONFIG

Re: [PATCH v3 08/13] mm/debug_vm_pgtable/thp: Use page table depost/withdraw with THP

2020-09-01 Thread Christophe Leroy
Le 01/09/2020 à 09:40, Aneesh Kumar K.V a écrit : On 9/1/20 12:20 PM, Christophe Leroy wrote: Le 01/09/2020 à 08:25, Aneesh Kumar K.V a écrit : On 9/1/20 8:52 AM, Anshuman Khandual wrote: There is a checkpatch.pl warning here. WARNING: Possible unwrapped commit description (prefer a

Re: [PATCH v3 08/13] mm/debug_vm_pgtable/thp: Use page table depost/withdraw with THP

2020-08-31 Thread Christophe Leroy
Le 01/09/2020 à 08:25, Aneesh Kumar K.V a écrit : On 9/1/20 8:52 AM, Anshuman Khandual wrote: There is a checkpatch.pl warning here. WARNING: Possible unwrapped commit description (prefer a maximum 75 chars per line) #7: Architectures like ppc64 use deposited page table while updating th

Re: [PATCH V3 0/4] mm/debug_vm_pgtable: Add some more tests

2020-06-27 Thread Christophe Leroy
Le 24/06/2020 à 05:13, Anshuman Khandual a écrit : On 06/15/2020 09:07 AM, Anshuman Khandual wrote: This series adds some more arch page table helper validation tests which are related to core and advanced memory functions. This also creates a documentation, enlisting expected semantics for

Re: [PATCH V3 2/4] mm/debug_vm_pgtable: Add tests validating advanced arch page table helpers

2020-06-27 Thread Christophe Leroy
Le 15/06/2020 à 05:37, Anshuman Khandual a écrit : This adds new tests validating for these following arch advanced page table helpers. These tests create and test specific mapping types at various page table levels. 1. pxxp_set_wrprotect() 2. pxxp_get_and_clear() 3. pxxp_set_access_flags() 4.

Re: [PATCH V3 2/4] mm/debug_vm_pgtable: Add tests validating advanced arch page table helpers

2020-06-27 Thread Christophe Leroy
Le 15/06/2020 à 05:37, Anshuman Khandual a écrit : This adds new tests validating for these following arch advanced page table helpers. These tests create and test specific mapping types at various page table levels. 1. pxxp_set_wrprotect() 2. pxxp_get_and_clear() 3. pxxp_set_access_flags() 4.

Re: [PATCH V2 0/3] mm/debug: Add more arch page table helper tests

2020-03-27 Thread Christophe Leroy
On 03/27/2020 06:46 AM, Anshuman Khandual wrote: On 03/26/2020 08:53 PM, Christophe Leroy wrote: Le 26/03/2020 à 03:23, Anshuman Khandual a écrit : On 03/24/2020 10:52 AM, Anshuman Khandual wrote: This series adds more arch page table helper tests. The new tests here are either related

Re: [PATCH V2 0/3] mm/debug: Add more arch page table helper tests

2020-03-26 Thread Christophe Leroy
Le 26/03/2020 à 03:23, Anshuman Khandual a écrit : On 03/24/2020 10:52 AM, Anshuman Khandual wrote: This series adds more arch page table helper tests. The new tests here are either related to core memory functions and advanced arch pgtable helpers. This also creates a documentation file enl

Re: [PATCH V15] mm/debug: Add tests validating architecture page table helpers

2020-03-06 Thread Christophe Leroy
Le 07/03/2020 à 01:56, Anshuman Khandual a écrit : On 03/07/2020 06:04 AM, Qian Cai wrote: On Mar 6, 2020, at 7:03 PM, Anshuman Khandual wrote: Hmm, set_pte_at() function is not preferred here for these tests. The idea is to avoid or atleast minimize TLB/cache flushes triggered from the

Re: [PATCH V14] mm/debug: Add tests validating architecture page table helpers

2020-03-04 Thread Christophe Leroy
Le 05/03/2020 à 01:54, Anshuman Khandual a écrit : On 03/04/2020 04:59 PM, Qian Cai wrote: On Mar 4, 2020, at 1:49 AM, Christophe Leroy wrote: AFAIU, you are not taking an interrupt here. You are stuck in the pte_update(), most likely due to nested locks. Try with LOCKDEP ? Not

Re: [PATCH V14] mm/debug: Add tests validating architecture page table helpers

2020-03-03 Thread Christophe Leroy
Le 04/03/2020 à 02:39, Qian Cai a écrit : Below is slightly modified version of your change above and should still prevent the bug on powerpc. Will it be possible for you to re-test this ? Once confirmed, will send a patch enabling this test on powerpc64 keeping your authorship. Thank you.

Re: [PATCH V14] mm/debug: Add tests validating architecture page table helpers

2020-03-02 Thread Christophe Leroy
Le 02/03/2020 à 20:40, Qian Cai a écrit : On Wed, 2020-02-26 at 10:51 -0500, Qian Cai wrote: On Wed, 2020-02-26 at 15:45 +0100, Christophe Leroy wrote: Le 26/02/2020 à 15:09, Qian Cai a écrit : On Mon, 2020-02-17 at 08:47 +0530, Anshuman Khandual wrote: This adds tests which will validate

Re: [PATCH] mm/debug: Add tests validating arch page table helpers for core features

2020-03-02 Thread Christophe Leroy
Anshuman Khandual a écrit : On 02/27/2020 04:59 PM, Christophe Leroy wrote: Le 27/02/2020 à 11:33, Anshuman Khandual a écrit : This adds new tests validating arch page table helpers for these following core memory features. These tests create and test specific mapping types at various page

Re: [PATCH] mm/debug: Add tests validating arch page table helpers for core features

2020-02-27 Thread Christophe Leroy
Le 27/02/2020 à 11:33, Anshuman Khandual a écrit : This adds new tests validating arch page table helpers for these following core memory features. These tests create and test specific mapping types at various page table levels. * SPECIAL mapping * PROTNONE mapping * DEVMAP mapping * SOFTDIRTY

Re: [PATCH] mm/debug: Add tests validating arch page table helpers for core features

2020-02-27 Thread Christophe Leroy
Le 27/02/2020 à 11:33, Anshuman Khandual a écrit : This adds new tests validating arch page table helpers for these following core memory features. These tests create and test specific mapping types at various page table levels. * SPECIAL mapping * PROTNONE mapping * DEVMAP mapping * SOFTDIRTY

Re: [PATCH V14] mm/debug: Add tests validating architecture page table helpers

2020-02-26 Thread Christophe Leroy
Le 26/02/2020 à 15:09, Qian Cai a écrit : On Mon, 2020-02-17 at 08:47 +0530, Anshuman Khandual wrote: This adds tests which will validate architecture page table helpers and other accessors in their compliance with expected generic MM semantics. This will help various architectures in validati

Re: [PATCH V14] mm/debug: Add tests validating architecture page table helpers

2020-02-26 Thread Christophe Leroy
Le 26/02/2020 à 15:12, Qian Cai a écrit : On Wed, 2020-02-26 at 09:09 -0500, Qian Cai wrote: On Mon, 2020-02-17 at 08:47 +0530, Anshuman Khandual wrote: How useful is this that straightly crash the powerpc? And then generate warnings on arm64, [  146.634626][T1] debug_vm_pgtable: debug

Re: [PATCH V13] mm/debug: Add tests validating architecture page table helpers

2020-02-10 Thread Christophe Leroy
Le 11/02/2020 à 03:25, Anshuman Khandual a écrit : On 02/10/2020 04:36 PM, Russell King - ARM Linux admin wrote: There are good reasons for the way ARM does stuff. The generic crap was written without regard for the circumstances that ARM has, and thus is entirely unsuitable for 32-bit ARM.

Re: [PATCH V13] mm/debug: Add tests validating architecture page table helpers

2020-02-10 Thread Christophe Leroy
Le 10/02/2020 à 11:02, Russell King - ARM Linux admin a écrit : On Mon, Feb 10, 2020 at 07:38:38AM +0100, Christophe Leroy wrote: Le 10/02/2020 à 06:35, Anshuman Khandual a écrit : On 02/10/2020 10:22 AM, Andrew Morton wrote: On Thu, 6 Feb 2020 13:49:35 +0530 Anshuman Khandual wrote

Re: [PATCH V13] mm/debug: Add tests validating architecture page table helpers

2020-02-09 Thread Christophe Leroy
Le 10/02/2020 à 06:35, Anshuman Khandual a écrit : On 02/10/2020 10:22 AM, Andrew Morton wrote: On Thu, 6 Feb 2020 13:49:35 +0530 Anshuman Khandual wrote: On 02/06/2020 04:40 AM, kbuild test robot wrote: Hi Anshuman, Thank you for the patch! Yet something to improve: [auto build test

Re: [PATCH V12] mm/debug: Add tests validating architecture page table helpers

2020-02-03 Thread Christophe Leroy
Le 02/02/2020 à 12:26, Qian Cai a écrit : On Jan 30, 2020, at 9:13 AM, Christophe Leroy wrote: config DEBUG_VM_PGTABLE bool "Debug arch page table for semantics compliance" if ARCH_HAS_DEBUG_VM_PGTABLE || EXPERT depends on MMU default 'n' if !ARCH_

Re: [PATCH V12] mm/debug: Add tests validating architecture page table helpers

2020-02-02 Thread Christophe Leroy
Le 02/02/2020 à 08:18, Anshuman Khandual a écrit : On 01/30/2020 07:43 PM, Christophe Leroy wrote: Le 30/01/2020 à 14:04, Anshuman Khandual a écrit : On 01/28/2020 10:35 PM, Christophe Leroy wrote: I think we could make it standalone and 'default y if DEBUG_VM' instead.

Re: [PATCH V12] mm/debug: Add tests validating architecture page table helpers

2020-01-30 Thread Christophe Leroy
Le 30/01/2020 à 14:04, Anshuman Khandual a écrit : On 01/28/2020 10:35 PM, Christophe Leroy wrote: Le 28/01/2020 à 02:27, Anshuman Khandual a écrit : diff --git a/arch/x86/include/asm/pgtable_64.h b/arch/x86/include/asm/pgtable_64.h index 0b6c4042942a..fb0e76d254b3 100644 --- a/arch/x86

Re: [PATCH V12] mm/debug: Add tests validating architecture page table helpers

2020-01-28 Thread Christophe Leroy
h any changes to the agreed upon semantics expected from generic MM and enable platforms to accommodate it thereafter. [...] Tested-by: Christophe Leroy #PPC32 Also tested on PPC64 (under QEMU): book3s/64 64k pages, book3s/64 4k pages and book3e/64 Reviewed-by: Ingo Molnar Suggest

Re: [PATCH V12] mm/debug: Add tests validating architecture page table helpers

2020-01-27 Thread Christophe Leroy
Le 28/01/2020 à 06:48, Qian Cai a écrit : On Jan 27, 2020, at 11:58 PM, Anshuman Khandual wrote: As I had mentioned before, the test attempts to formalize page table helper semantics as expected from generic MM code paths and intend to catch deviations when enabled on a given platform.

Re: [PATCH V12] mm/debug: Add tests validating architecture page table helpers

2020-01-27 Thread Christophe Leroy
Le 28/01/2020 à 04:33, Qian Cai a écrit : On Jan 27, 2020, at 10:06 PM, Anshuman Khandual wrote: On 01/28/2020 07:41 AM, Qian Cai wrote: On Jan 27, 2020, at 8:28 PM, Anshuman Khandual wrote: This adds tests which will validate architecture page table helpers and other accessors i

Re: [RFT 00/13] iomap: Constify ioreadX() iomem argument

2020-01-08 Thread Christophe Leroy
Hi Geert, Le 08/01/2020 à 09:43, Geert Uytterhoeven a écrit : Hi Christophe, On Wed, Jan 8, 2020 at 9:35 AM Christophe Leroy wrote: Le 08/01/2020 à 09:18, Krzysztof Kozlowski a écrit : On Wed, 8 Jan 2020 at 09:13, Geert Uytterhoeven wrote: On Wed, Jan 8, 2020 at 9:07 AM Geert Uytterhoeven

Re: [RFT 00/13] iomap: Constify ioreadX() iomem argument

2020-01-08 Thread Christophe Leroy
Le 08/01/2020 à 09:18, Krzysztof Kozlowski a écrit : On Wed, 8 Jan 2020 at 09:13, Geert Uytterhoeven wrote: Hi Krzysztof, On Wed, Jan 8, 2020 at 9:07 AM Geert Uytterhoeven wrote: On Tue, Jan 7, 2020 at 5:53 PM Krzysztof Kozlowski wrote: The ioread8/16/32() and others have inconsistent i

Re: [PATCH V8] mm/debug: Add tests validating architecture page table helpers

2019-11-05 Thread Christophe Leroy
Le 06/11/2019 à 04:22, Anshuman Khandual a écrit : On 10/28/2019 10:59 AM, Anshuman Khandual wrote: +--- +| arch |status| +--- +| alpha: | TODO | +| arc: | TODO | +| arm: | TODO | +| arm64

Re: [PATCH V7] mm/debug: Add tests validating architecture page table helpers

2019-10-25 Thread Christophe Leroy
Le 25/10/2019 à 10:24, Anshuman Khandual a écrit : On 10/25/2019 12:41 PM, Christophe Leroy wrote: Le 25/10/2019 à 07:52, Qian Cai a écrit : On Oct 24, 2019, at 11:45 PM, Anshuman Khandual wrote: Nothing specific. But just tested this with x86 defconfig with relevant configs which

Re: [PATCH V7] mm/debug: Add tests validating architecture page table helpers

2019-10-25 Thread Christophe Leroy
Le 25/10/2019 à 07:52, Qian Cai a écrit : On Oct 24, 2019, at 11:45 PM, Anshuman Khandual wrote: Nothing specific. But just tested this with x86 defconfig with relevant configs which are required for this test. Not sure if it involved W=1. No, it will not. It needs to run like, make W=

Re: [PATCH V7] mm/debug: Add tests validating architecture page table helpers

2019-10-22 Thread Christophe Leroy
s Cc: "David S. Miller" Cc: Vineet Gupta Cc: James Hogan Cc: Paul Burton Cc: Ralf Baechle Cc: Kirill A. Shutemov Cc: Gerald Schaefer Cc: Christophe Leroy Cc: Ingo Molnar Cc: linux-snps-arc@lists.infradead.org Cc: linux-m...@vger.kernel.org Cc: linux-arm-ker...@lists.infradead.

Re: [PATCH] mm/pgtable/debug: Fix test validating architecture page table helpers

2019-09-18 Thread Christophe Leroy
Le 18/09/2019 à 09:32, Anshuman Khandual a écrit : On 09/13/2019 11:53 AM, Christophe Leroy wrote: Fix build failure on powerpc. Fix preemption imbalance. Signed-off-by: Christophe Leroy --- mm/arch_pgtable_test.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mm

Re: [PATCH V2 2/2] mm/pgtable/debug: Add test validating architecture page table helpers

2019-09-18 Thread Christophe Leroy
Le 19/09/2019 à 06:56, Anshuman Khandual a écrit : On 09/18/2019 09:56 PM, Christophe Leroy wrote: Le 18/09/2019 à 07:04, Anshuman Khandual a écrit : On 09/13/2019 03:31 PM, Christophe Leroy wrote: Le 13/09/2019 à 11:02, Anshuman Khandual a écrit : +#if !defined

Re: [PATCH V2 2/2] mm/pgtable/debug: Add test validating architecture page table helpers

2019-09-18 Thread Christophe Leroy
Le 18/09/2019 à 07:04, Anshuman Khandual a écrit : On 09/13/2019 03:31 PM, Christophe Leroy wrote: Le 13/09/2019 à 11:02, Anshuman Khandual a écrit : +#if !defined(__PAGETABLE_PMD_FOLDED) && !defined(__ARCH_HAS_4LEVEL_HACK) #ifdefs have to be avoided as much as possible, s

Re: [PATCH V2 2/2] mm/pgtable/debug: Add test validating architecture page table helpers

2019-09-13 Thread Christophe Leroy
Le 13/09/2019 à 11:02, Anshuman Khandual a écrit : +#if !defined(__PAGETABLE_PMD_FOLDED) && !defined(__ARCH_HAS_4LEVEL_HACK) #ifdefs have to be avoided as much as possible, see below Yeah but it has been bit difficult to avoid all these $ifdef because of the availability (or lack of it) f

Re: [PATCH] mm/pgtable/debug: Fix test validating architecture page table helpers

2019-09-13 Thread Christophe Leroy
Le 13/09/2019 à 09:03, Christophe Leroy a écrit : Le 13/09/2019 à 08:58, Anshuman Khandual a écrit : On 09/13/2019 11:53 AM, Christophe Leroy wrote: Fix build failure on powerpc. Fix preemption imbalance. Signed-off-by: Christophe Leroy ---   mm/arch_pgtable_test.c | 3 +++   1 file

Re: [PATCH] mm/pgtable/debug: Fix test validating architecture page table helpers

2019-09-13 Thread Christophe Leroy
Le 13/09/2019 à 08:58, Anshuman Khandual a écrit : On 09/13/2019 11:53 AM, Christophe Leroy wrote: Fix build failure on powerpc. Fix preemption imbalance. Signed-off-by: Christophe Leroy --- mm/arch_pgtable_test.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mm

Re: [PATCH V2 0/2] mm/debug: Add tests for architecture exported page table helpers

2019-09-12 Thread Christophe Leroy
Le 13/09/2019 à 08:24, Anshuman Khandual a écrit : On 09/12/2019 08:12 PM, Christophe Leroy wrote: Hi, I didn't get patch 1 of this series, and it is not on linuxppc-dev patchwork either. Can you resend ? Its there on linux-mm patchwork and copied on linux-ker...@vger.kernel.org as

Re: [PATCH V2 2/2] mm/pgtable/debug: Add test validating architecture page table helpers

2019-09-12 Thread Christophe Leroy
Le 12/09/2019 à 17:52, Christophe Leroy a écrit : Le 12/09/2019 à 17:36, Christophe Leroy a écrit : Le 12/09/2019 à 17:00, Christophe Leroy a écrit : On 09/12/2019 06:02 AM, Anshuman Khandual wrote: This adds a test module which will validate architecture page table helpers and

[PATCH] mm/pgtable/debug: Fix test validating architecture page table helpers

2019-09-12 Thread Christophe Leroy
Fix build failure on powerpc. Fix preemption imbalance. Signed-off-by: Christophe Leroy --- mm/arch_pgtable_test.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mm/arch_pgtable_test.c b/mm/arch_pgtable_test.c index 8b4a92756ad8..f2b3c9ec35fa 100644 --- a/mm/arch_pgtable_test.c +++ b

Re: [PATCH V2 2/2] mm/pgtable/debug: Add test validating architecture page table helpers

2019-09-12 Thread Christophe Leroy
Le 12/09/2019 à 08:02, Anshuman Khandual a écrit : This adds a test module which will validate architecture page table helpers and accessors regarding compliance with generic MM semantics expectations. This will help various architectures in validating changes to the existing page table helpers

Re: [PATCH V2 2/2] mm/pgtable/debug: Add test validating architecture page table helpers

2019-09-12 Thread Christophe Leroy
Le 12/09/2019 à 17:36, Christophe Leroy a écrit : Le 12/09/2019 à 17:00, Christophe Leroy a écrit : On 09/12/2019 06:02 AM, Anshuman Khandual wrote: This adds a test module which will validate architecture page table helpers and accessors regarding compliance with generic MM semantics

Re: [PATCH V2 2/2] mm/pgtable/debug: Add test validating architecture page table helpers

2019-09-12 Thread Christophe Leroy
Le 12/09/2019 à 17:00, Christophe Leroy a écrit : On 09/12/2019 06:02 AM, Anshuman Khandual wrote: This adds a test module which will validate architecture page table helpers and accessors regarding compliance with generic MM semantics expectations. This will help various architectures in

Re: [PATCH V2 2/2] mm/pgtable/debug: Add test validating architecture page table helpers

2019-09-12 Thread Christophe Leroy
an Cc: Paul Mackerras Cc: Martin Schwidefsky Cc: Heiko Carstens Cc: "David S. Miller" Cc: Vineet Gupta Cc: James Hogan Cc: Paul Burton Cc: Ralf Baechle Cc: Kirill A. Shutemov Cc: Gerald Schaefer Cc: Christophe Leroy Cc: linux-snps-arc@lists.infradead.org Cc: linux-m...@vger.ker

  1   2   >