Re: [PATCH v3 04/22] powerpc/cell: Switch to irq_get_nr_irqs()

2024-10-15 Thread Michael Ellerman
Bart Van Assche writes: > Use the irq_get_nr_irqs() function instead of the global variable > 'nr_irqs'. Prepare for changing 'nr_irqs' from an exported global > variable into a variable with file scope. > > Cc: linuxppc-dev@lists.ozlabs.org > Signed-off-by: Bart Van Assche > --- > arch/powerpc/

Re: [PATCH v5 14/16] modules: Support extended MODVERSIONS info

2024-10-15 Thread Matthew Maurer
So, the basic things I can think of to test here are: 1. The kernel can still load the previous MODVERSIONS format 2. The kernel can load the new MODVERSIONS format 3. If we artificially tweak a CRC in the previous format, it will fail to load. 4. If we artificially tweak a CRC in the new format,

Re: [PATCH] tpm: ibmvtpm: Set TPM_OPS_AUTO_STARTUP flag on driver

2024-10-15 Thread Jarkko Sakkinen
On Wed Oct 16, 2024 at 12:15 AM EEST, Jarkko Sakkinen wrote: > On Mon Oct 14, 2024 at 5:16 PM EEST, Stefan Berger wrote: > > Set the TPM_OPS_AUTO_STARTUP on the driver so that the ibmvtpm driver now > > uses tpm2_auto_startup and tpm1_auto_startup like many other drivers do. > > Remove tpm_get_time

Re: [PATCH] tpm: ibmvtpm: Set TPM_OPS_AUTO_STARTUP flag on driver

2024-10-15 Thread Jarkko Sakkinen
On Mon Oct 14, 2024 at 5:16 PM EEST, Stefan Berger wrote: > Set the TPM_OPS_AUTO_STARTUP on the driver so that the ibmvtpm driver now > uses tpm2_auto_startup and tpm1_auto_startup like many other drivers do. > Remove tpm_get_timeouts, tpm2_get_cc_attrs_tbl, and tpm2_sessions_init > calls from it s

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

2024-10-15 Thread Luis Chamberlain
On Tue, Oct 15, 2024 at 08:54:29AM +0300, Mike Rapoport wrote: > On Mon, Oct 14, 2024 at 09:09:49PM -0700, Luis Chamberlain wrote: > > Mike, please run this with kmemleak enabled and running, and also try to get > > tools/testing/selftests/kmod/kmod.sh to pass. > > There was an issue with kmemleak

Re: [PATCH 0/2] net: ethernet: freescale: Use %pa to format resource_size_t

2024-10-15 Thread patchwork-bot+netdevbpf
Hello: This series was applied to netdev/net-next.git (main) by Jakub Kicinski : On Mon, 14 Oct 2024 11:48:06 +0100 you wrote: > Hi, > > This short series addersses the formatting of variables of > type resource_size_t in freescale drivers. > > The correct format string for resource_size_t is %

Re: [PATCH 00/17] replace call_rcu by kfree_rcu for simple kmem_cache_free callback

2024-10-15 Thread patchwork-bot+netdevbpf
Hello: This series was applied to netdev/net-next.git (main) by Jakub Kicinski : On Sun, 13 Oct 2024 22:16:47 +0200 you wrote: > Since SLOB was removed and since > commit 6c6c47b063b5 ("mm, slab: call kvfree_rcu_barrier() from > kmem_cache_destroy()"), > it is not necessary to use call_rcu when

Re: [PATCH 1/7] powerpc/entry: convert to common and generic entry

2024-10-15 Thread Christophe Leroy
Le 12/10/2024 à 05:56, Luming Yu a écrit : convert powerpc entry code in syscall and fault to use syscall_work and irqentry_state as well as common calls implemented in generic entry infrastructure. Signed-off-by: Luming Yu --- arch/powerpc/Kconfig | 1 + arch/powerpc/in

Re: [PATCH 6/7] powerpc/entry: factout irqentry-state

2024-10-15 Thread Thomas Gleixner
On Sat, Oct 12 2024 at 11:56, Luming Yu wrote: > To have lowlevel paca.h include high level entry-common.h cause > include file dependency mess. Split irqentry-state.h to have > the irqentry_state.h can be included in low level paca.h What's the rationale for this? > Signed-off-by: Luming Yu >

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-15 Thread Catalin Marinas
On Tue, Oct 15, 2024 at 12:41:16PM +0100, Will Deacon wrote: > On Tue, Oct 15, 2024 at 10:59:11AM +0100, Joey Gouly wrote: > > On Mon, Oct 14, 2024 at 06:10:23PM +0100, Will Deacon wrote: > > > Looking a little more at this, I think we have quite a weird behaviour > > > on arm64 as it stands. It lo

Re: [RFC v3 3/3] fadump: Move fadump_cma_init to setup_arch() after initmem_init()

2024-10-15 Thread Madhavan Srinivasan
On 10/11/24 8:30 PM, Ritesh Harjani (IBM) wrote: > During early init CMA_MIN_ALIGNMENT_BYTES can be PAGE_SIZE, > since pageblock_order is still zero and it gets initialized > later during initmem_init() e.g. > setup_arch() -> initmem_init() -> sparse_init() -> set_pageblock_order() > > One such

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-15 Thread Dave Martin
On Tue, Oct 15, 2024 at 12:41:16PM +0100, Will Deacon wrote: > On Tue, Oct 15, 2024 at 10:59:11AM +0100, Joey Gouly wrote: > > On Mon, Oct 14, 2024 at 06:10:23PM +0100, Will Deacon wrote: > > > Kevin, Joey, > > > > > > On Wed, Oct 09, 2024 at 03:43:01PM +0100, Will Deacon wrote: > > > > On Tue, Se

Re: [PATCH 00/17] replace call_rcu by kfree_rcu for simple kmem_cache_free callback

2024-10-15 Thread patchwork-bot+netdevbpf
Hello: This series was applied to netdev/net-next.git (main) by Simon Wunderlich : On Sun, 13 Oct 2024 22:16:47 +0200 you wrote: > Since SLOB was removed and since > commit 6c6c47b063b5 ("mm, slab: call kvfree_rcu_barrier() from > kmem_cache_destroy()"), > it is not necessary to use call_rcu whe

Re: [RFC PATCH v3 4/4] sched+mm: Use hazard pointers to track lazy active mm existence

2024-10-15 Thread Mathieu Desnoyers
On 2024-10-14 04:27, kernel test robot wrote: Hello, kernel test robot noticed "WARNING:at_kernel/hazptr.c:#hazptr_scan" on: commit: c1508707268498a6fd3ca5853ad65f9482c12374 ("[RFC PATCH v3 4/4] sched+mm: Use hazard pointers to track lazy active mm existence") url: https://github.com/intel-

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-15 Thread Mark Brown
On Tue, Oct 15, 2024 at 01:25:29PM +0100, Joey Gouly wrote: > On Tue, Oct 15, 2024 at 12:41:16PM +0100, Will Deacon wrote: > > if (system_supports_poe() && err == 0 && user->poe_offset) { > > ... > > which gives the wrong impression that the POR is somehow optional, even > > if th

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-15 Thread Joey Gouly
On Tue, Oct 15, 2024 at 12:41:16PM +0100, Will Deacon wrote: > On Tue, Oct 15, 2024 at 10:59:11AM +0100, Joey Gouly wrote: > > On Mon, Oct 14, 2024 at 06:10:23PM +0100, Will Deacon wrote: > > > Kevin, Joey, > > > > > > On Wed, Oct 09, 2024 at 03:43:01PM +0100, Will Deacon wrote: > > > > On Tue, Se

Re: [PATCH 0/2] net: ethernet: freescale: Use %pa to format resource_size_t

2024-10-15 Thread Simon Horman
On Tue, Oct 15, 2024 at 07:24:48AM +, Daniel Machon wrote: > > Hi, > > > > This short series addersses the formatting of variables of > > type resource_size_t in freescale drivers. > > > > The correct format string for resource_size_t is %pa which > > acts on the address of the variable to be

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-15 Thread Will Deacon
On Tue, Oct 15, 2024 at 10:59:11AM +0100, Joey Gouly wrote: > On Mon, Oct 14, 2024 at 06:10:23PM +0100, Will Deacon wrote: > > Kevin, Joey, > > > > On Wed, Oct 09, 2024 at 03:43:01PM +0100, Will Deacon wrote: > > > On Tue, Sep 24, 2024 at 01:27:58PM +0200, Kevin Brodsky wrote: > > > > On 22/08/202

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-15 Thread Mark Brown
On Tue, Oct 15, 2024 at 10:59:11AM +0100, Joey Gouly wrote: > On Mon, Oct 14, 2024 at 06:10:23PM +0100, Will Deacon wrote: > > Looking a little more at this, I think we have quite a weird behaviour > > on arm64 as it stands. It looks like we rely on the signal frame to hold > > the original POR_EL

Re: [RFC v3 2/3] fadump: Reserve page-aligned boot_memory_size during fadump_reserve_mem

2024-10-15 Thread Madhavan Srinivasan
On 10/11/24 8:30 PM, Ritesh Harjani (IBM) wrote: > This patch refactors all CMA related initialization and alignment code > to within fadump_cma_init() which gets called in the end. This also means > that we keep [reserve_dump_area_start, boot_memory_size] page aligned > during fadump_reserve_me

Re: drivers/nx: Invalid wait context issue when rebooting

2024-10-15 Thread Vishal Chourasia
On Mon, Oct 14, 2024 at 05:54:44PM +0530, Ritesh Harjani wrote: > Vishal Chourasia writes: > > > On Fri, Oct 11, 2024 at 09:37:27PM +1100, Michael Ellerman wrote: > >> > >> I don't see why of_reconfig_notifier_unregister() needs to be called > >> with the devdata_mutext held, but I haven't looke

Re: [RFC PATCH v1 01/57] mm: Add macros ahead of supporting boot-time page size selection

2024-10-15 Thread Ryan Roberts
On 15/10/2024 04:04, Pingfan Liu wrote: > On Mon, Oct 14, 2024 at 10:07 PM Ryan Roberts wrote: >> >> On 14/10/2024 14:54, Pingfan Liu wrote: >>> Hello Ryan, >>> >>> On Mon, Oct 14, 2024 at 11:58:08AM +0100, Ryan Roberts wrote: arm64 can support multiple base page sizes. Instead of selecting a

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-15 Thread Borislav Petkov
On Mon, Oct 14, 2024 at 04:39:26PM +0100, Andrew Cooper wrote: > But, I expect it will malfunction on newer hardware when > CONFIG_X86_5LEVEL=n, because it causes Linux to explicitly ignore the > LA57 bit.  That can be fixed by changing how CONFIG_X86_5LEVEL works. https://lore.kernel.org/all/8073

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-15 Thread Joey Gouly
On Mon, Oct 14, 2024 at 06:10:23PM +0100, Will Deacon wrote: > Kevin, Joey, > > On Wed, Oct 09, 2024 at 03:43:01PM +0100, Will Deacon wrote: > > On Tue, Sep 24, 2024 at 01:27:58PM +0200, Kevin Brodsky wrote: > > > On 22/08/2024 17:11, Joey Gouly wrote: > > > > @@ -1178,6 +1237,9 @@ static void set

Re: [PATCH v5 6/8] x86/module: perpare module loading for ROX allocations of text

2024-10-15 Thread Nathan Chancellor
On Fri, Oct 11, 2024 at 03:58:04PM +0300, Mike Rapoport wrote: > I overlooked how cfi_*_callers routines update addr. > This patch should fix it: Thanks, can confirm. My boot is working again and LKDTM's CFI_FORWARD_PROTO test properly fails. > diff --git a/arch/x86/kernel/alternative.c b/arch/x8

Re: [RFC RESEND v2 02/13] powerpc: mm: Fix kfence page fault reporting

2024-10-15 Thread IBM
Christophe Leroy writes: > Le 15/10/2024 à 03:33, Ritesh Harjani (IBM) a écrit : >> copy_from_kernel_nofault() can be called when doing read of /proc/kcore. >> /proc/kcore can have some unmapped kfence objects which when read via >> copy_from_kernel_nofault() can cause page faults. Since *_nofaul

Re: [PATCH 0/2] net: ethernet: freescale: Use %pa to format resource_size_t

2024-10-15 Thread Daniel Machon
> Hi, > > This short series addersses the formatting of variables of > type resource_size_t in freescale drivers. > > The correct format string for resource_size_t is %pa which > acts on the address of the variable to be formatted [1]. > > [1] > https://elixir.bootlin.com/linux/v6.11.3/source/D

Re: [RFC RESEND v2 02/13] powerpc: mm: Fix kfence page fault reporting

2024-10-14 Thread Christophe Leroy
Le 15/10/2024 à 03:33, Ritesh Harjani (IBM) a écrit : copy_from_kernel_nofault() can be called when doing read of /proc/kcore. /proc/kcore can have some unmapped kfence objects which when read via copy_from_kernel_nofault() can cause page faults. Since *_nofault() functions define their own fi

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

2024-10-14 Thread Mike Rapoport
On Mon, Oct 14, 2024 at 09:09:49PM -0700, Luis Chamberlain wrote: > Mike, please run this with kmemleak enabled and running, and also try to get > tools/testing/selftests/kmod/kmod.sh to pass. There was an issue with kmemleak, I fixed it here: https://lore.kernel.org/linux-mm/20241009180816.83591

Re: [PATCH 2/2] asm-generic: add an optional pfn_valid check to pfn_valid

2024-10-14 Thread Thomas Huth
On 14/10/2024 16.44, Christoph Hellwig wrote: page_to_pfn is usually implemented by pointer arithmetics on the memory map, which means that bogus input can lead to even more bogus output. Powerpc had a pfn_valid check on the regult to it's page_to_phys s/regult/result/ implementation when CO

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

2024-10-14 Thread Luis Chamberlain
Mike, please run this with kmemleak enabled and running, and also try to get tools/testing/selftests/kmod/kmod.sh to pass. I run into silly boot issues with just a guest. Luis

Re: [RFC PATCH v1 01/57] mm: Add macros ahead of supporting boot-time page size selection

2024-10-14 Thread Pingfan Liu
On Mon, Oct 14, 2024 at 10:07 PM Ryan Roberts wrote: > > On 14/10/2024 14:54, Pingfan Liu wrote: > > Hello Ryan, > > > > On Mon, Oct 14, 2024 at 11:58:08AM +0100, Ryan Roberts wrote: > >> arm64 can support multiple base page sizes. Instead of selecting a page > >> size at compile time, as is done

Re: [RFC PATCH v1 01/57] mm: Add macros ahead of supporting boot-time page size selection

2024-10-14 Thread Pingfan Liu
Hello Ryan, On Mon, Oct 14, 2024 at 11:58:08AM +0100, Ryan Roberts wrote: > arm64 can support multiple base page sizes. Instead of selecting a page > size at compile time, as is done today, we will make it possible to > select the desired page size on the command line. > > In this case PAGE_SHIFT

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

2024-10-14 Thread Luis Chamberlain
On Sun, Oct 13, 2024 at 08:26:26PM -0700, Andrew Morton wrote: > On Sun, 13 Oct 2024 11:43:41 +0300 Mike Rapoport wrote: > > > > > The idea is to keep everything together and have execmem_info describe > > > > all > > > > that architecture needs. > > > > > > But why? That's pretty different f

Re: [RFC] ipw2100 ipw2200 ps3_gelic rtl8712 --- Are we ready for wext cleanup?

2024-10-14 Thread Philipp Hortmann
On 14.10.24 11:32, Kalle Valo wrote: Philipp Hortmann writes: origin of this question was the following patch series from Arnd Bergmann [PATCH 00/10] Remove obsolete and orphaned wifi drivers https://lore.kernel.org/linux-staging/20231023131953.2876682-1-a...@kernel.org/ Here the remaining fi

Re: [PATCH] tools/perf/tests: Remove duplicate evlist__delete in tests/tool_pmu.c

2024-10-14 Thread Namhyung Kim
On Sun, 13 Oct 2024 22:37:32 +0530, Athira Rajeev wrote: > The testcase for tool_pmu failed in powerpc as below: > > ./perf test -v "Parsing without PMU name" > 8: Tool PMU: > 8.1: Parsing without PMU name

Re: [PATCH] tools/perf/tests: Fix compilation error with strncpy in tests/tool_pmu

2024-10-14 Thread Namhyung Kim
On Sun, 13 Oct 2024 23:07:42 +0530, Athira Rajeev wrote: > perf fails to compile on systems with GCC version11 > as below: > > In file included from /usr/include/string.h:519, > from > /home/athir/perf-tools-next/tools/include/linux/bitmap.h:5, > from /home/athi

Re: [PATCH] tools/perf/tests: Fix compilation error with strncpy in tests/tool_pmu

2024-10-14 Thread Namhyung Kim
On Sun, Oct 13, 2024 at 11:07:42PM +0530, Athira Rajeev wrote: > perf fails to compile on systems with GCC version11 > as below: I have one more build failure on 32 bit systems. I'll carry this as well. Thanks, Namhyung ---8<--- >From 2e2c7ca3691d223d94ea383a6b688e35579d14d5 Mon Sep 17 00:00:00

Re: [PATCH] tools/perf/tests: Fix compilation error with strncpy in tests/tool_pmu

2024-10-14 Thread Namhyung Kim
Hello Athira, On Sun, Oct 13, 2024 at 11:07:42PM +0530, Athira Rajeev wrote: > perf fails to compile on systems with GCC version11 > as below: > > In file included from /usr/include/string.h:519, > from > /home/athir/perf-tools-next/tools/include/linux/bitmap.h:5, >

Re: [PATCH v5 19/30] arm64: add POE signal support

2024-10-14 Thread Will Deacon
Kevin, Joey, On Wed, Oct 09, 2024 at 03:43:01PM +0100, Will Deacon wrote: > On Tue, Sep 24, 2024 at 01:27:58PM +0200, Kevin Brodsky wrote: > > On 22/08/2024 17:11, Joey Gouly wrote: > > > @@ -1178,6 +1237,9 @@ static void setup_return(struct pt_regs *regs, > > > struct k_sigaction *ka, > > >

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-14 Thread Linus Torvalds
On Mon, 14 Oct 2024 at 05:30, Kirill A. Shutemov wrote: > > Given that LAM enforces bit 47/56 to be equal to bit 63 I think we can do > this unconditionally instead of masking: > > diff --git a/arch/x86/lib/getuser.S b/arch/x86/lib/getuser.S > index d066aecf8aeb..86d4511520b1 100644 > --- a/arch/x

Re: (subset) [PATCH v3 00/16] timers: Cleanup delay/sleep related mess

2024-10-14 Thread Mark Brown
On Mon, 14 Oct 2024 10:22:17 +0200, Anna-Maria Behnsen wrote: > a question about which sleeping function should be used in acpi_os_sleep() > started a discussion and examination about the existing documentation and > implementation of functions which insert a sleep/delay. > > The result of the dis

Re: [PATCH v5 3/5] powerpc: perf: Use perf_arch_instruction_pointer()

2024-10-14 Thread Madhavan Srinivasan
c/perf/callchain.c > +++ b/arch/powerpc/perf/callchain.c > @@ -51,7 +51,7 @@ perf_callchain_kernel(struct perf_callchain_entry_ctx > *entry, struct pt_regs *re > > lr = regs->link; > sp = regs->gpr[1]; > - perf_callchain_store(entry, p

Re: [PATCH v5 2/5] perf: Hoist perf_instruction_pointer() and perf_misc_flags()

2024-10-14 Thread Madhavan Srinivasan
On 9/20/24 11:17 PM, Colton Lewis wrote: > For clarity, rename the arch-specific definitions of these functions > to perf_arch_* to denote they are arch-specifc. Define the > generic-named functions in one place where they can call the > arch-specific ones as needed. > > Signed-off-by: Colton L

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-14 Thread Andrew Cooper
On 14/10/2024 1:30 pm, Kirill A. Shutemov wrote: > On Sun, Oct 13, 2024 at 11:50:55PM -0700, Linus Torvalds wrote: >> Anyway, the attached patch >> >> diff --git a/arch/x86/lib/getuser.S b/arch/x86/lib/getuser.S >> index d066aecf8aeb..7d5730aa18b8 100644 >> --- a/arch/x86/lib/getuser.S >> +++ b/arc

RE: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-14 Thread David Laight
From: Linus Torvalds > Sent: 14 October 2024 12:21 > > On Mon, 14 Oct 2024 at 02:59, David Laight wrote: > > > > Isn't LAM just plain stupid unless the hardware validates the bits > > against the TLB? > > What? No. You can't do that. At some point, the TLB isn't filled, and > then you have to do

Re: [RFC PATCH v1 01/57] mm: Add macros ahead of supporting boot-time page size selection

2024-10-14 Thread Ryan Roberts
On 14/10/2024 14:54, Pingfan Liu wrote: > Hello Ryan, > > On Mon, Oct 14, 2024 at 11:58:08AM +0100, Ryan Roberts wrote: >> arm64 can support multiple base page sizes. Instead of selecting a page >> size at compile time, as is done today, we will make it possible to >> select the desired page size

Re: [PATCH 3/9] arm64: vdso: Remove timekeeper include

2024-10-14 Thread Will Deacon
On Thu, Oct 10, 2024 at 05:44:46PM +0200, Thomas Weißschuh wrote: > Since the generic VDSO clock mode storage is used, this header file is > unused and can be removed. > > Signed-off-by: Thomas Weißschuh > --- > arch/arm64/kernel/vdso.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/ar

Re: [PATCH 1/9] vdso: Remove timekeeper argument of __arch_update_vsyscall()

2024-10-14 Thread Will Deacon
On Thu, Oct 10, 2024 at 05:44:44PM +0200, Thomas Weißschuh wrote: > No implementation of this hook uses the passed in timekeeper anymore. > > This avoids including a non-VDSO header while building the VDSO, > which can lead to compilation errors. > > Signed-off-by: Thomas Weißschuh > --- > arch

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

2024-10-14 Thread Mike Rapoport
On Sun, Oct 13, 2024 at 10:55:25PM -0700, Christoph Hellwig wrote: > On Sun, Oct 13, 2024 at 11:43:41AM +0300, Mike Rapoport wrote: > > > But why? That's pretty different from our normal style of arch hooks, > > > and introduces an indirect call in a security sensitive area. > > > > Will change t

Re: [PATCHES] drm/radeon issues

2024-10-14 Thread Alex Deucher
On Thu, Oct 10, 2024 at 11:54 PM Christian Zigotzky wrote: > > On 11 October 2024 at 01:49am, Jeff Johnson wrote: > > Can you provide links to all 3 patches? > > 6.12-rc2 was back merged to my ath.git project, but then my laptop > stopped booting correctly and I discovered a few Radeon KASAN repo

Re: drivers/nx: Invalid wait context issue when rebooting

2024-10-14 Thread IBM
Vishal Chourasia writes: > On Fri, Oct 11, 2024 at 09:37:27PM +1100, Michael Ellerman wrote: >> >> I don't see why of_reconfig_notifier_unregister() needs to be called >> with the devdata_mutext held, but I haven't looked that closely at it. >> >> So the change below might work. >> >> cheers >

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-14 Thread Kirill A. Shutemov
On Sun, Oct 13, 2024 at 11:50:55PM -0700, Linus Torvalds wrote: > Anyway, the attached patch > > diff --git a/arch/x86/lib/getuser.S b/arch/x86/lib/getuser.S > index d066aecf8aeb..7d5730aa18b8 100644 > --- a/arch/x86/lib/getuser.S > +++ b/arch/x86/lib/getuser.S > @@ -37,11 +37,17 @@ > > #define

Re: [PATCH 00/17] replace call_rcu by kfree_rcu for simple kmem_cache_free callback

2024-10-14 Thread Pablo Neira Ayuso
On Sun, Oct 13, 2024 at 10:16:47PM +0200, Julia Lawall wrote: > Since SLOB was removed and since > commit 6c6c47b063b5 ("mm, slab: call kvfree_rcu_barrier() from > kmem_cache_destroy()"), > it is not necessary to use call_rcu when the callback only performs > kmem_cache_free. Use kfree_rcu() direc

Re: [RFC v3 1/3] fadump: Refactor and prepare fadump_cma_init for late init

2024-10-14 Thread Madhavan Srinivasan
On 10/14/24 4:54 PM, Ritesh Harjani (IBM) wrote: > Madhavan Srinivasan writes: > >> On 10/11/24 8:30 PM, Ritesh Harjani (IBM) wrote: >>> We anyway don't use any return values from fadump_cma_init(). Since >>> fadump_reserve_mem() from where fadump_cma_init() gets called today, >>> already has

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-14 Thread Kirill A. Shutemov
On Sat, Oct 12, 2024 at 05:53:19PM -0700, Linus Torvalds wrote: > On Sat, 12 Oct 2024 at 10:44, Linus Torvalds > wrote: > > > > Anyway, what's the speculation window size like? > > Note that this is important basically because we do *NOT* want to > check the address against TASK_SIZE_MAX like we

Re: [RFC v3 1/3] fadump: Refactor and prepare fadump_cma_init for late init

2024-10-14 Thread IBM
Madhavan Srinivasan writes: > On 10/11/24 8:30 PM, Ritesh Harjani (IBM) wrote: >> We anyway don't use any return values from fadump_cma_init(). Since >> fadump_reserve_mem() from where fadump_cma_init() gets called today, >> already has the required checks. >> This patch makes this function retur

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-14 Thread Linus Torvalds
On Mon, 14 Oct 2024 at 02:59, David Laight wrote: > > Isn't LAM just plain stupid unless the hardware validates the bits > against the TLB? What? No. You can't do that. At some point, the TLB isn't filled, and then you have to do the access with lots of linear address bits masked. > Doesn't ARM6

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-14 Thread Andrew Cooper
On 14/10/2024 7:50 am, Linus Torvalds wrote: > On Sun, 13 Oct 2024 at 20:54, Josh Poimboeuf wrote: >> If I understand correctly, LAM bits are for the benefit of SW and are >> ignored by HW? That is what is written in the ISE today. But, I'll note that on ARM, MTE (Memory Tagging Extensions) use

Re: Build regressions/improvements in v6.12-rc3

2024-10-14 Thread Simon Horman
On Mon, Oct 14, 2024 at 11:18:14AM +0200, Geert Uytterhoeven wrote: > Hi Simon, > > On Mon, Oct 14, 2024 at 10:58 AM Simon Horman wrote: > > On Mon, Oct 14, 2024 at 10:38:20AM +0200, Geert Uytterhoeven wrote: > > > + /kisskb/src/drivers/net/ethernet/freescale/fs_enet/mii-bitbang.c: > > > error

Re: [RFC v3 1/3] fadump: Refactor and prepare fadump_cma_init for late init

2024-10-14 Thread Madhavan Srinivasan
On 10/11/24 8:30 PM, Ritesh Harjani (IBM) wrote: > We anyway don't use any return values from fadump_cma_init(). Since > fadump_reserve_mem() from where fadump_cma_init() gets called today, > already has the required checks. > This patch makes this function return type as void. Let's also handle

Re: [PATCH] powerpc/pseries/iommu: Wait until all TCEs are unmapped before deleting DDW

2024-10-14 Thread Michael Ellerman
Hi Gaurav, Gaurav Batra writes: > Some of the network drivers, like Mellanox, use core linux page_pool APIs > to manage DMA buffers. These page_pool APIs cache DMA buffers with > infrequent map/unmap calls for DMA mappings, thus increasing performance. Can you please resend this and Cc the netde

Re: [PATCH v4 0/7] ASoC: fsl: add memory to memory function for ASRC

2024-10-14 Thread Takashi Iwai
On Wed, 25 Sep 2024 08:55:09 +0200, Shengjiu Wang wrote: > > This function is base on the accelerator implementation > for compress API: > https://patchwork.kernel.org/project/alsa-devel/patch/20240731083843.59911-1-pe...@perex.cz/ > Add it to this patch set. > > Audio signal processing also has

RE: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-14 Thread David Laight
... > > If I understand correctly, LAM bits are for the benefit of SW and are > > ignored by HW? Can we just mask those bits off? > > Yes. But then you waste time on the masking, but particularly if it > then causes silly extra overhead just to get the mask. Isn't LAM just plain stupid unless th

Re: [RFC] ipw2100 ipw2200 ps3_gelic rtl8712 --- Are we ready for wext cleanup?

2024-10-14 Thread Kalle Valo
Philipp Hortmann writes: > origin of this question was the following patch series from Arnd Bergmann > [PATCH 00/10] Remove obsolete and orphaned wifi drivers > https://lore.kernel.org/linux-staging/20231023131953.2876682-1-a...@kernel.org/ > > Here the remaining files that use iw_handler_def: >

Re: Build regressions/improvements in v6.12-rc3

2024-10-14 Thread Geert Uytterhoeven
Hi Simon, On Mon, Oct 14, 2024 at 10:58 AM Simon Horman wrote: > On Mon, Oct 14, 2024 at 10:38:20AM +0200, Geert Uytterhoeven wrote: > > + /kisskb/src/drivers/net/ethernet/freescale/fs_enet/mii-bitbang.c: > > error: format '%x' expects argument of type 'unsigned int', but argument 4 > > has t

Re: Build regressions/improvements in v6.12-rc3

2024-10-14 Thread Simon Horman
On Mon, Oct 14, 2024 at 10:38:20AM +0200, Geert Uytterhoeven wrote: > On Mon, 14 Oct 2024, Geert Uytterhoeven wrote: > > JFYI, when comparing v6.12-rc3[1] to v6.12-rc2[3], the summaries are: > > - build errors: +3/-1 > > + /kisskb/src/crypto/async_tx/async_tx.c: error: no previous prototype for

Re: Build regressions/improvements in v6.12-rc3

2024-10-14 Thread Geert Uytterhoeven
On Mon, 14 Oct 2024, Geert Uytterhoeven wrote: JFYI, when comparing v6.12-rc3[1] to v6.12-rc2[3], the summaries are: - build errors: +3/-1 + /kisskb/src/crypto/async_tx/async_tx.c: error: no previous prototype for '__async_tx_find_channel' [-Werror=missing-prototypes]: => 43:1 powerpc-gcc

Re: [RFC PATCH v3 4/4] sched+mm: Use hazard pointers to track lazy active mm existence

2024-10-14 Thread kernel test robot
Hello, kernel test robot noticed "WARNING:at_kernel/hazptr.c:#hazptr_scan" on: commit: c1508707268498a6fd3ca5853ad65f9482c12374 ("[RFC PATCH v3 4/4] sched+mm: Use hazard pointers to track lazy active mm existence") url: https://github.com/intel-lab-lkp/linux/commits/Mathieu-Desnoyers/compile

Re: [PATCH 09/12] mm: Update vm_normal_page() callers to accept FS DAX pages

2024-10-14 Thread Alistair Popple
Dan Williams writes: > Alistair Popple wrote: >> Currently if a PTE points to a FS DAX page vm_normal_page() will >> return NULL as these have their own special refcounting scheme. A >> future change will allow FS DAX pages to be refcounted the same as any >> other normal page. >> >> Therefore

Re: [PATCH 00/17] replace call_rcu by kfree_rcu for simple kmem_cache_free callback

2024-10-14 Thread Vlastimil Babka
On 10/13/24 22:16, Julia Lawall wrote: > Since SLOB was removed and since > commit 6c6c47b063b5 ("mm, slab: call kvfree_rcu_barrier() from > kmem_cache_destroy()"), > it is not necessary to use call_rcu when the callback only performs > kmem_cache_free. Use kfree_rcu() directly. > > The changes w

Re: [PATCH 11/12] mm: Remove pXX_devmap callers

2024-10-14 Thread Alistair Popple
Alexander Gordeev writes: > On Tue, Sep 10, 2024 at 02:14:36PM +1000, Alistair Popple wrote: > > Hi Alistair, > >> diff --git a/arch/powerpc/mm/book3s64/pgtable.c >> b/arch/powerpc/mm/book3s64/pgtable.c >> index 5a4a753..4537a29 100644 >> --- a/arch/powerpc/mm/book3s64/pgtable.c >> +++ b/arch/

Re: [PATCH 08/12] gup: Don't allow FOLL_LONGTERM pinning of FS DAX pages

2024-10-14 Thread Alistair Popple
Dan Williams writes: > Dan Williams wrote: >> Alistair Popple wrote: >> > Longterm pinning of FS DAX pages should already be disallowed by >> > various pXX_devmap checks. However a future change will cause these >> > checks to be invalid for FS DAX pages so make >> > folio_is_longterm_pinnable(

Re: [PATCH 07/12] huge_memory: Allow mappings of PMD sized pages

2024-10-14 Thread Alistair Popple
Dan Williams writes: > Alistair Popple wrote: >> Currently DAX folio/page reference counts are managed differently to >> normal pages. To allow these to be managed the same as normal pages >> introduce dax_insert_pfn_pmd. This will map the entire PMD-sized folio >> and take references as it wou

Re: [RFC v3 -next] cma: Enforce non-zero pageblock_order during cma_init_reserved_mem()

2024-10-13 Thread Anshuman Khandual
On 10/11/24 20:26, Ritesh Harjani (IBM) wrote: > cma_init_reserved_mem() checks base and size alignment with > CMA_MIN_ALIGNMENT_BYTES. However, some users might call this during > early boot when pageblock_order is 0. That means if base and size does > not have pageblock_order alignment, it can

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-13 Thread Linus Torvalds
On Sun, 13 Oct 2024 at 20:54, Josh Poimboeuf wrote: > > If I understand correctly, LAM bits are for the benefit of SW and are > ignored by HW? Can we just mask those bits off? Yes. But then you waste time on the masking, but particularly if it then causes silly extra overhead just to get the mas

Re: [PATCH 06/12] huge_memory: Allow mappings of PUD sized pages

2024-10-13 Thread Alistair Popple
Dan Williams writes: > Alistair Popple wrote: >> Currently DAX folio/page reference counts are managed differently to >> normal pages. To allow these to be managed the same as normal pages >> introduce dax_insert_pfn_pud. This will map the entire PUD-sized folio >> and take references as it wou

Re: [PATCH] tty: hvc: riscv_sbi: instantiate the legcay console earlier

2024-10-13 Thread Greg Kroah-Hartman
On Mon, Oct 14, 2024 at 08:08:57AM +0800, Jisheng Zhang wrote: > The hvc_instantiate() is an early console discovery mechanism, it is > usually called before allocating hvc terminal devices. In fact, if > we check hvc_riscv_sbi's hvc_instantiate() return value, we'll find > that it's -1. So the cal

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

2024-10-13 Thread Christoph Hellwig
On Sun, Oct 13, 2024 at 11:43:41AM +0300, Mike Rapoport wrote: > > But why? That's pretty different from our normal style of arch hooks, > > and introduces an indirect call in a security sensitive area. > > Will change to __weak hook. Isn't the callback required when using the large ROX page?

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-13 Thread Josh Poimboeuf
On Sat, Oct 12, 2024 at 06:21:12PM -0700, Linus Torvalds wrote: > On Sat, 12 Oct 2024 at 17:53, Linus Torvalds > wrote: > > > > So no, the address masking can not depend on things like > > __VIRTUAL_MASK_SHIFT, it would need to at least take LAM into account > > too. Not that I know if there are a

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

2024-10-13 Thread Andrew Morton
On Sun, 13 Oct 2024 11:43:41 +0300 Mike Rapoport wrote: > > > The idea is to keep everything together and have execmem_info describe all > > > that architecture needs. > > > > But why? That's pretty different from our normal style of arch hooks, > > and introduces an indirect call in a securit

Re: [GIT PULL] Please pull powerpc/linux.git powerpc-6.12-4 tag

2024-10-13 Thread pr-tracker-bot
The pull request you sent on Sun, 13 Oct 2024 10:19:32 +1100: > https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git > tags/powerpc-6.12-4 has been merged into torvalds/linux.git: https://git.kernel.org/torvalds/c/36c254515dc6592c44db77b84908358979dd6b50 Thank you! -- Deet-doot-d

Re: [PATCH 00/17] replace call_rcu by kfree_rcu for simple kmem_cache_free callback

2024-10-13 Thread Paul E. McKenney
On Sun, Oct 13, 2024 at 10:16:47PM +0200, Julia Lawall wrote: > Since SLOB was removed and since > commit 6c6c47b063b5 ("mm, slab: call kvfree_rcu_barrier() from > kmem_cache_destroy()"), > it is not necessary to use call_rcu when the callback only performs > kmem_cache_free. Use kfree_rcu() direc

Re: (subset) [PATCH 00/17] replace call_rcu by kfree_rcu for simple kmem_cache_free callback

2024-10-13 Thread Jens Axboe
On Sun, 13 Oct 2024 22:16:47 +0200, Julia Lawall wrote: > Since SLOB was removed and since > commit 6c6c47b063b5 ("mm, slab: call kvfree_rcu_barrier() from > kmem_cache_destroy()"), > it is not necessary to use call_rcu when the callback only performs > kmem_cache_free. Use kfree_rcu() directly.

Re: [PATCH] powermac: Use of_property_match_string() in pmac_has_backlight_type()

2024-10-13 Thread Dan Carpenter
On Fri, Oct 11, 2024 at 06:25:45PM +0200, Christophe Leroy wrote: > > diff --git a/arch/powerpc/platforms/powermac/backlight.c > > b/arch/powerpc/platforms/powermac/backlight.c > > index 12bc01353bd3..79741370c40c 100644 > > --- a/arch/powerpc/platforms/powermac/backlight.c > > +++ b/arch/powerpc/

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

2024-10-13 Thread Mike Rapoport
On Fri, Oct 11, 2024 at 12:46:23AM -0700, Christoph Hellwig wrote: > On Thu, Oct 10, 2024 at 03:57:33PM +0300, Mike Rapoport wrote: > > On Wed, Oct 09, 2024 at 11:58:33PM -0700, Christoph Hellwig wrote: > > > On Wed, Oct 09, 2024 at 09:08:15PM +0300, Mike Rapoport wrote: > > > > /** > > > > * st

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Borislav Petkov
On Sat, Oct 12, 2024 at 09:09:23AM -0500, Josh Poimboeuf wrote: > On Sat, Oct 12, 2024 at 09:48:57AM +0100, Andrew Cooper wrote: > > On 12/10/2024 5:09 am, Josh Poimboeuf wrote: > > > For x86-64, the barrier_nospec() in copy_from_user() is overkill and > > > painfully slow. Instead, use pointer ma

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Linus Torvalds
On Sat, 12 Oct 2024 at 17:53, Linus Torvalds wrote: > > So no, the address masking can not depend on things like > __VIRTUAL_MASK_SHIFT, it would need to at least take LAM into account > too. Not that I know if there are any CPU's out there that actually > have LAM enabled. Lunar Lake and Arrow L

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Linus Torvalds
On Sat, 12 Oct 2024 at 10:44, Linus Torvalds wrote: > > Anyway, what's the speculation window size like? Note that this is important basically because we do *NOT* want to check the address against TASK_SIZE_MAX like we used to, because not only is TASK_SIZE_MAX not a compile-time constant, but wi

Re: [PATCH] powerpc/8xx: Fix kernel DTLB miss on dcbz

2024-10-12 Thread Michael Ellerman
On Sat, 05 Oct 2024 10:53:29 +0200, Christophe Leroy wrote: > Following OOPS is encountered while loading test_bpf module > on powerpc 8xx: > > [ 218.835567] BUG: Unable to handle kernel data access on write at 0xcb00 > [ 218.842473] Faulting instruction address: 0xc0017a80 > [ 218.847451]

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Linus Torvalds
On Sat, 12 Oct 2024 at 10:23, Andrew Cooper wrote: >> > This logic is asymmetric. > > For an address in the upper half (canonical or non-canonical), it ORs > with -1 and fully replaces the prior address. Right. The point is that non-canonical addresses will fault, and kernel addresses are guarant

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Andrew Cooper
On 12/10/2024 4:44 pm, Linus Torvalds wrote: > On Sat, 12 Oct 2024 at 01:49, Andrew Cooper wrote: >> You do realise mask_user_address() is unsafe under speculation on AMD >> systems? > That had *better* not be true. Yeah I'd prefer it wasn't true either. >> Had the mask_user_address() patch been

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Linus Torvalds
On Sat, 12 Oct 2024 at 07:21, Borislav Petkov wrote: > > Commit > > 2865baf54077 ("x86: support user address masking instead of > non-speculative conditional") No. Thos started long before. Again, see commit b19b74bc99b1 ("x86/mm: Rework address range check in get_user() and put_user(

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Linus Torvalds
On Sat, 12 Oct 2024 at 01:49, Andrew Cooper wrote: > > You do realise mask_user_address() is unsafe under speculation on AMD > systems? That had *better* not be true. > Had the mask_user_address() patch been put for review, this feedback > would have been given then. That's BS. Why? Look at co

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Andrew Cooper
On 12/10/2024 3:09 pm, Josh Poimboeuf wrote: > On Sat, Oct 12, 2024 at 09:48:57AM +0100, Andrew Cooper wrote: >> On 12/10/2024 5:09 am, Josh Poimboeuf wrote: >>> For x86-64, the barrier_nospec() in copy_from_user() is overkill and >>> painfully slow. Instead, use pointer masking to force the user

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Josh Poimboeuf
On Sat, Oct 12, 2024 at 09:48:57AM +0100, Andrew Cooper wrote: > On 12/10/2024 5:09 am, Josh Poimboeuf wrote: > > For x86-64, the barrier_nospec() in copy_from_user() is overkill and > > painfully slow. Instead, use pointer masking to force the user pointer > > to a non-kernel value even in specul

Re: [PATCH 0/2] ASoC: imx-card: add cs42888 codec support

2024-10-12 Thread Mark Brown
On Wed, 09 Oct 2024 15:46:42 +0800, Shengjiu Wang wrote: > add cs42888 codec support > > Chancel Liu (2): > ASoC: imx-card: Set mclk for codec > ASoC: imx-card: Add CS42888 support > > sound/soc/fsl/imx-card.c | 59 +++- > 1 file changed, 52 insertions(+),

Re: [PATCH 5/7] powerpc/entry: add irqentry_state and generic entry support

2024-10-12 Thread 虞陆铭
Le 12/10/2024 à 05:56, Luming Yu a écrit : >> generic irq entry support via generic irqentry is added for powerpc. >> There may be duplciate calls and missing callbacks requires further >> work. >> >> Signed-off-by: Luming Yu > >This patch doesn't apply. sorry to hear that. :-( the ppc linux-c

Re: [PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()

2024-10-12 Thread Andrew Cooper
On 12/10/2024 5:09 am, Josh Poimboeuf wrote: > For x86-64, the barrier_nospec() in copy_from_user() is overkill and > painfully slow. Instead, use pointer masking to force the user pointer > to a non-kernel value even in speculative paths. > > Signed-off-by: Josh Poimboeuf You do realise mask_us

Re: [PATCH 5/7] powerpc/entry: add irqentry_state and generic entry support

2024-10-12 Thread Christophe Leroy
Le 12/10/2024 à 05:56, Luming Yu a écrit : generic irq entry support via generic irqentry is added for powerpc. There may be duplciate calls and missing callbacks requires further work. Signed-off-by: Luming Yu This patch doesn't apply. Applying: powerpc/entry: add irqentry_state and gene

  1   2   3   4   5   6   7   8   9   10   >