Re: [PATCH v2 0/3] sysfs: constify bin_attribute argument of sysfs_bin_attr_simple_read()

2025-01-08 Thread Greg Kroah-Hartman
On Wed, Jan 08, 2025 at 09:45:45AM -0800, Alexei Starovoitov wrote: > On Tue, Dec 31, 2024 at 2:30 AM Thomas Weißschuh wrote: > > > > On 2024-12-30 16:50:41-0800, Alexei Starovoitov wrote: > > > On Sat, Dec 28, 2024 at 12:43 AM Thomas Weißschuh > > > wrote: > > > > > > > > Most users use this fu

Re: [PATCH 5/6] powerpc/pseries: Add ibm,get-dynamic-sensor-state RTAS call support

2025-01-08 Thread Dan Carpenter
://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next patch link: https://lore.kernel.org/r/20250104204652.388720-6-haren%40linux.ibm.com patch subject: [PATCH 5/6] powerpc/pseries: Add ibm,get-dynamic-sensor-state RTAS call support config: powerpc64-randconfig-r071-20250108 (https

Re: [PATCH 4/6] powerpc/pseries: Add ibm,set-dynamic-indicator RTAS call support

2025-01-08 Thread Dan Carpenter
://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next patch link: https://lore.kernel.org/r/20250104204652.388720-5-haren%40linux.ibm.com patch subject: [PATCH 4/6] powerpc/pseries: Add ibm,set-dynamic-indicator RTAS call support config: powerpc64-randconfig-r071-20250108 (https

[PATCH] powerpc/ipic: Stop printing address of registers

2025-01-08 Thread Christophe Leroy
The following line appears at boot: IPIC (128 IRQ sources) at (ptrval) This is pointless so remove the printing of the virtual address and replace it by matching physical address. Signed-off-by: Christophe Leroy --- arch/powerpc/sysdev/ipic.c | 3 +-- 1 file changed, 1 insertion(+), 2

[PATCH] spi: fsl-spi: Remove display of virtual address

2025-01-08 Thread Christophe Leroy
The following appears in kernel log at boot: fsl_spi b01004c0.spi: at 0x(ptrval) (irq = 51), QE mode This is useless, so remove the display of that virtual address and display the MMIO address instead, just like serial core does. Signed-off-by: Christophe Leroy --- drivers/spi/spi-fsl-

Re: [PATCH] perf machine: Don't ignore _etext when not a text symbol

2025-01-08 Thread Christophe Leroy
Le 08/01/2025 à 21:14, Arnaldo Carvalho de Melo a écrit : On Wed, Jan 08, 2025 at 10:15:24AM +0100, Christophe Leroy wrote: Depending on how vmlinux.lds is written, _etext might be the very first data symbol instead of the very last text symbol. Don't require it to be a text symbol, accept a

Re: [PATCH v5 05/25] fs/dax: Create a common implementation to break DAX layouts

2025-01-08 Thread Alistair Popple
On Wed, Jan 08, 2025 at 04:14:20PM -0800, Dan Williams wrote: > Alistair Popple wrote: > > Prior to freeing a block file systems supporting FS DAX must check > > that the associated pages are both unmapped from user-space and not > > undergoing DMA or other access from eg. get_user_pages(). This is

Re: [PATCH] kexec: Initialize ELF lowest address to ULONG_MAX

2025-01-08 Thread Sourabh Jain
Hello Andrew, On 09/01/25 10:58, Andrew Morton wrote: On Thu, 9 Jan 2025 09:42:14 +0530 Sourabh Jain wrote: Hello Baoquan and Eric, On 12/12/24 08:25, Baoquan he wrote: On 12/10/24 at 02:43pm, Sourabh Jain wrote: kexec_elf_load() loads an ELF executable and sets the address of the lowest

Re: [PATCH v3 5/6] s390/crash: Use note name macros

2025-01-08 Thread Akihiko Odaki
On 2025/01/08 22:50, Dave Martin wrote: On Wed, Jan 08, 2025 at 01:53:51PM +0900, Akihiko Odaki wrote: On 2025/01/08 1:17, Dave Martin wrote: Hi, On Tue, Jan 07, 2025 at 09:45:56PM +0900, Akihiko Odaki wrote: Use note name macros to match with the userspace's expectation. Signed-off-by: Akih

Re: [PATCH] kexec: Initialize ELF lowest address to ULONG_MAX

2025-01-08 Thread Andrew Morton
On Thu, 9 Jan 2025 09:42:14 +0530 Sourabh Jain wrote: > Hello Baoquan and Eric, > > > On 12/12/24 08:25, Baoquan he wrote: > > On 12/10/24 at 02:43pm, Sourabh Jain wrote: > >> kexec_elf_load() loads an ELF executable and sets the address of the > >> lowest PT_LOAD section to the address held b

Re: [PATCH v5 03/25] fs/dax: Don't skip locked entries when scanning entries

2025-01-08 Thread Alistair Popple
On Wed, Jan 08, 2025 at 02:50:36PM -0800, Dan Williams wrote: > Alistair Popple wrote: > > Several functions internal to FS DAX use the following pattern when > > trying to obtain an unlocked entry: > > > > xas_for_each(&xas, entry, end_idx) { > > if (dax_is_locked(entry)) > > entr

Re: [PATCH v5 01/25] fuse: Fix dax truncate/punch_hole fault path

2025-01-08 Thread Alistair Popple
On Wed, Jan 08, 2025 at 02:30:24PM -0800, Dan Williams wrote: > Alistair Popple wrote: > > FS DAX requires file systems to call into the DAX layout prior to > > unlinking inodes to ensure there is no ongoing DMA or other remote > > access to the direct mapped page. The fuse file system implements >

Re: [PATCH] kexec: Initialize ELF lowest address to ULONG_MAX

2025-01-08 Thread Sourabh Jain
Hello Baoquan and Eric, On 12/12/24 08:25, Baoquan he wrote: On 12/10/24 at 02:43pm, Sourabh Jain wrote: kexec_elf_load() loads an ELF executable and sets the address of the lowest PT_LOAD section to the address held by the lowest_load_addr function argument. To determine the lowest PT_LOAD a

Re: [PATCH RESEND v1 1/5] crash: remove an unused argument from reserve_crashkernel_generic()

2025-01-08 Thread Sourabh Jain
Hello Baoquan, On 08/01/25 16:46, Baoquan he wrote: On 01/08/25 at 03:44pm, Sourabh Jain wrote: cmdline argument is not used in reserve_crashkernel_generic() so remove it. Correspondingly, all the callers have been updated as well. No functional change intended. Cc: Andrew Morton Cc: Baoqua

Re: [PATCH RESEND v1 4/5] powerpc/crash: use generic crashkernel reservation

2025-01-08 Thread Sourabh Jain
Hello Mahesh, On 08/01/25 22:35, Mahesh J Salgaonkar wrote: On 2025-01-08 15:44:57 Wed, Sourabh Jain wrote: Commit 0ab97169aa05 ("crash_core: add generic function to do reservation") added a generic function to reserve crashkernel memory. So let's use the same function on powerpc and remove the

Re: [PATCH RESEND v1 3/5] powerpc/kdump: preserve user-specified memory limit

2025-01-08 Thread Sourabh Jain
Hello Mahesh, On 08/01/25 22:36, Mahesh J Salgaonkar wrote: On 2025-01-08 15:44:56 Wed, Sourabh Jain wrote: Commit 59d58189f3d9 ("crash: fix crash memory reserve exceed system memory bug") fails crashkernel parsing if the crash size is found to be higher than system RAM, which makes the memory

Re: [PATCH v5 00/25] fs/dax: Fix ZONE_DEVICE page reference counts

2025-01-08 Thread Alison Schofield
On Tue, Jan 07, 2025 at 02:42:16PM +1100, Alistair Popple wrote: > Main updates since v4: > > - Removed most of the devdax/fsdax checks in fs/proc/task_mmu.c. This >means smaps/pagemap may contain DAX pages. > > - Fixed rmap accounting of PUD mapped pages. > > - Minor code clean-ups. > >

Re: [PATCH v5 05/25] fs/dax: Create a common implementation to break DAX layouts

2025-01-08 Thread Dan Williams
Alistair Popple wrote: > Prior to freeing a block file systems supporting FS DAX must check > that the associated pages are both unmapped from user-space and not > undergoing DMA or other access from eg. get_user_pages(). This is > achieved by unmapping the file range and scanning the FS DAX > page

linux-next: manual merge of the powerpc tree with the mm tree

2025-01-08 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the powerpc tree got a conflict in: arch/powerpc/Kconfig between commit: c0c3319917db ("mm: remove devmap related functions and page table bits") from the mm-unstable branch of the mm tree and commit: 00199ed6f2ca ("powerpc: Add preempt lazy support")

Re: [PATCH v5 03/25] fs/dax: Don't skip locked entries when scanning entries

2025-01-08 Thread Dan Williams
Alistair Popple wrote: > Several functions internal to FS DAX use the following pattern when > trying to obtain an unlocked entry: > > xas_for_each(&xas, entry, end_idx) { > if (dax_is_locked(entry)) > entry = get_unlocked_entry(&xas, 0); > > This is problematic because get_un

Re: [PATCH] of: address: Unify resource bounds overflow checking

2025-01-08 Thread Rob Herring
On Wed, Jan 8, 2025 at 8:04 AM Basharath Hussain Khaja wrote: > > Hi, > > >> Thomas Weißschuh writes: > >> > The members "start" and "end" of struct resource are of type > >> > "resource_size_t" which can be 32bit wide. > >> > Values read from OF however are always 64bit wide. > >> > > >> > Refac

Re: [PATCH v5 02/25] fs/dax: Return unmapped busy pages from dax_layout_busy_page_range()

2025-01-08 Thread Dan Williams
Alistair Popple wrote: > dax_layout_busy_page_range() is used by file systems to scan the DAX > page-cache to unmap mapping pages from user-space and to determine if > any pages in the given range are busy, either due to ongoing DMA or > other get_user_pages() usage. > > Currently it checks to see

Re: [PATCH v5 01/25] fuse: Fix dax truncate/punch_hole fault path

2025-01-08 Thread Dan Williams
Alistair Popple wrote: > FS DAX requires file systems to call into the DAX layout prior to > unlinking inodes to ensure there is no ongoing DMA or other remote > access to the direct mapped page. The fuse file system implements > fuse_dax_break_layouts() to do this which includes a comment > indica

Re: [PATCH v8 3/7] PCI: Make pcie_read_tlp_log() signature same

2025-01-08 Thread Bjorn Helgaas
On Wed, Jan 08, 2025 at 03:40:11PM -0500, Yazen Ghannam wrote: > On Wed, Dec 18, 2024 at 04:37:43PM +0200, Ilpo Järvinen wrote: > > pcie_read_tlp_log()'s prototype and function signature diverged due to > > changes made while applying. > > > > Make the parameters of pcie_read_tlp_log() named ident

Re: [PATCH v5 00/25] fs/dax: Fix ZONE_DEVICE page reference counts

2025-01-08 Thread Dan Williams
Andrew Morton wrote: > On Tue, 7 Jan 2025 14:42:16 +1100 Alistair Popple wrote: > > > Device and FS DAX pages have always maintained their own page > > reference counts without following the normal rules for page reference > > counting. In particular pages are considered free when the refcount >

Re: [PATCH] powerpc/32: Stop printing Kernel virtual memory layout

2025-01-08 Thread Kees Cook
On Wed, Jan 08, 2025 at 07:40:38PM +0100, Christophe Leroy wrote: > Printing of Kernel virtual memory layout was added for debug purpose > by commit f637a49e507c ("powerpc: Minor cleanups of kernel virt > address space definitions") > > For security reasons, don't display the kernel's virtual memo

Re: [PATCH v8 6/7] PCI: Add TLP Prefix reading into pcie_read_tlp_log()

2025-01-08 Thread Yazen Ghannam
On Wed, Dec 18, 2024 at 04:37:46PM +0200, Ilpo Järvinen wrote: > pcie_read_tlp_log() handles only 4 Header Log DWORDs but TLP Prefix Log > (PCIe r6.1 secs 7.8.4.12 & 7.9.14.13) may also be present. > > Generalize pcie_read_tlp_log() and struct pcie_tlp_log to handle also > TLP Prefix Log. The rele

Re: [PATCH v8 5/7] PCI: Store # of supported End-End TLP Prefixes

2025-01-08 Thread Yazen Ghannam
On Wed, Dec 18, 2024 at 04:37:45PM +0200, Ilpo Järvinen wrote: > eetlp_prefix_path in the struct pci_dev tells if End-End TLP Prefixes > are supported by the path or not, the value is only calculated if > CONFIG_PCI_PASID is set. > > The Max End-End TLP Prefixes field in the Device Capabilities Re

Re: [PATCH] perf machine: Don't ignore _etext when not a text symbol

2025-01-08 Thread Arnaldo Carvalho de Melo
On Wed, Jan 08, 2025 at 10:15:24AM +0100, Christophe Leroy wrote: > Depending on how vmlinux.lds is written, _etext might be the very > first data symbol instead of the very last text symbol. > > Don't require it to be a text symbol, accept any symbol type. I'm adding a Link: Link: https://lore

Re: [PATCH v8 3/7] PCI: Make pcie_read_tlp_log() signature same

2025-01-08 Thread Yazen Ghannam
On Wed, Dec 18, 2024 at 04:37:43PM +0200, Ilpo Järvinen wrote: > pcie_read_tlp_log()'s prototype and function signature diverged due to > changes made while applying. > > Make the parameters of pcie_read_tlp_log() named identically. > > Signed-off-by: Ilpo Järvinen > Reviewed-by: Jonathan Camero

Re: [PATCH] of: address: Unify resource bounds overflow checking

2025-01-08 Thread Basharath Hussain Khaja
Hi, >> Thomas Weißschuh writes: >> > The members "start" and "end" of struct resource are of type >> > "resource_size_t" which can be 32bit wide. >> > Values read from OF however are always 64bit wide. >> > >> > Refactor the diff overflow checks into a helper function. >> > Also extend the checks

Re: [PATCH v2] perf: Fix display of kernel symbols

2025-01-08 Thread Arnaldo Carvalho de Melo
On Wed, Jan 08, 2025 at 06:06:03PM +0100, Christophe Leroy wrote: > > > Le 08/01/2025 à 15:53, Arnaldo Carvalho de Melo a écrit : > > On Wed, Jan 08, 2025 at 10:54:20AM +0100, Christophe Leroy wrote: > > > Since commit 659ad3492b91 ("perf maps: Switch from rbtree to lazily > > > sorted array for

[PATCH] powerpc/32: Stop printing Kernel virtual memory layout

2025-01-08 Thread Christophe Leroy
Printing of Kernel virtual memory layout was added for debug purpose by commit f637a49e507c ("powerpc: Minor cleanups of kernel virt address space definitions") For security reasons, don't display the kernel's virtual memory layout. Other architectures have removed it through following commits.

Re: Perf doesn't display kernel symbols anymore (bisected commit 659ad3492b91 ("perf maps: Switch from rbtree to lazily sorted array for addresses"))

2025-01-08 Thread Christophe Leroy
Le 06/01/2025 à 22:46, Namhyung Kim a écrit : And in System.map I have: c136a000 D __start___bug_table c1377c14 D __stop___bug_table c1378000 B __bss_start c1378000 B _edata c1378000 B initcall_debug c1378004 B reset_devices Should perf try to locate the very last symbol when it doesn't fin

Re: [PATCH v2 0/3] sysfs: constify bin_attribute argument of sysfs_bin_attr_simple_read()

2025-01-08 Thread Alexei Starovoitov
On Tue, Dec 31, 2024 at 2:30 AM Thomas Weißschuh wrote: > > On 2024-12-30 16:50:41-0800, Alexei Starovoitov wrote: > > On Sat, Dec 28, 2024 at 12:43 AM Thomas Weißschuh > > wrote: > > > > > > Most users use this function through the BIN_ATTR_SIMPLE* macros, > > > they can handle the switch trans

Re: watchdog: BUG: soft lockup

2025-01-08 Thread Doug Anderson
Hi, On Sun, Dec 22, 2024 at 10:32 PM wzs wrote: > > Hello, > when fuzzing the Linux kernel, > I triggered many "watch: BUG: soft lockup" warnings. > I am not sure whether this is an issue with the kernel or with the > fuzzing program I ran. > (The same fuzzing program, when tested on kernel versi

Re: [PATCH v2] perf: Fix display of kernel symbols

2025-01-08 Thread Ian Rogers
On Wed, Jan 8, 2025 at 1:54 AM Christophe Leroy wrote: > > Since commit 659ad3492b91 ("perf maps: Switch from rbtree to lazily > sorted array for addresses"), perf doesn't display anymore kernel > symbols on powerpc, allthough it still detects them as kernel addresses. > > # Overhead Comm

Re: [PATCH v2] perf: Fix display of kernel symbols

2025-01-08 Thread Christophe Leroy
Le 08/01/2025 à 15:53, Arnaldo Carvalho de Melo a écrit : On Wed, Jan 08, 2025 at 10:54:20AM +0100, Christophe Leroy wrote: Since commit 659ad3492b91 ("perf maps: Switch from rbtree to lazily sorted array for addresses"), perf doesn't display anymore kernel symbols on powerpc, allthough it st

Re: Raptor Engineering dedicating resources to KVM on PowerNV + KVM CI/CD

2025-01-08 Thread Shawn Anastasio
Hi Alex, On 1/7/25 5:45 AM, Alex Williamson wrote > Hi, > > What are you supposing the value to the community is for a CI pipeline > that always fails? Are you hoping the community will address the > failing tests or monitor the failures to try to make them not become > worse? The failing tests

Re: [PATCH RESEND v1 3/5] powerpc/kdump: preserve user-specified memory limit

2025-01-08 Thread Mahesh J Salgaonkar
On 2025-01-08 15:44:56 Wed, Sourabh Jain wrote: > Commit 59d58189f3d9 ("crash: fix crash memory reserve exceed system > memory bug") fails crashkernel parsing if the crash size is found to be > higher than system RAM, which makes the memory_limit adjustment code > ineffective due to an early exit f

Re: [PATCH RESEND v1 4/5] powerpc/crash: use generic crashkernel reservation

2025-01-08 Thread Mahesh J Salgaonkar
On 2025-01-08 15:44:57 Wed, Sourabh Jain wrote: > Commit 0ab97169aa05 ("crash_core: add generic function to do > reservation") added a generic function to reserve crashkernel memory. > So let's use the same function on powerpc and remove the > architecture-specific code that essentially does the sa

[PATCH] powerpc/pseries/iommu: create DDW for devices with DMA mask less than 64-bits

2025-01-08 Thread Gaurav Batra
Starting with PAPR level 2.13, platform supports placing PHB in limited address mode. Devices that support DMA masks less that 64-bit but greater than 32-bits are placed in limited address mode. In this mode, the starting DMA address returned by the DDW is 4GB. When the device driver calls dma_sup

Re: [PATCH v8 2/7] PCI: Move TLP Log handling to own file

2025-01-08 Thread Yazen Ghannam
On Wed, Dec 18, 2024 at 04:37:42PM +0200, Ilpo Järvinen wrote: > TLP Log is PCIe feature and is processed only by AER and DPC. > Configwise, DPC depends AER being enabled. In lack of better place, the > TLP Log handling code was initially placed into pci.c but it can be > easily placed in a separat

Re: [PATCH v5 06/17] s390: pgtable: add statistics for PUD and P4D level page table

2025-01-08 Thread Alexander Gordeev
On Wed, Jan 08, 2025 at 02:57:22PM +0800, Qi Zheng wrote: > Like PMD and PTE level page table, also add statistics for PUD and P4D > page table. > > Signed-off-by: Qi Zheng > Suggested-by: Peter Zijlstra (Intel) > Reviewed-by: Kevin Brodsky > Cc: linux-s...@vger.kernel.org > --- > arch/s390/in

Re: [PATCH v8 1/7] PCI: Don't expose pcie_read_tlp_log() outside of PCI subsystem

2025-01-08 Thread Yazen Ghannam
On Wed, Dec 18, 2024 at 04:37:41PM +0200, Ilpo Järvinen wrote: > pcie_read_tlp_log() was exposed by the commit 0a5a46a6a61b ("PCI/AER: > Generalize TLP Header Log reading") but this is now considered a > mistake. No drivers outside of PCI subsystem should build their own > diagnostic logging but sh

Re: [PATCH v5 13/17] s390: pgtable: consolidate PxD and PTE TLB free paths

2025-01-08 Thread Alexander Gordeev
On Wed, Jan 08, 2025 at 02:57:29PM +0800, Qi Zheng wrote: > Call pagetable_dtor() for PMD|PUD|P4D tables just before ptdesc is > freed - same as it is done for PTE tables. That allows consolidating > TLB free paths for all table types. > > Signed-off-by: Qi Zheng > Suggested-by: Peter Zijlstra (I

Re: [PATCH v5 07/17] mm: pgtable: introduce pagetable_dtor()

2025-01-08 Thread Alexander Gordeev
On Wed, Jan 08, 2025 at 02:57:23PM +0800, Qi Zheng wrote: > The pagetable_p*_dtor() are exactly the same except for the handling of > ptlock. If we make ptlock_free() handle the case where ptdesc->ptl is > NULL and remove VM_BUG_ON_PAGE() from pmd_ptlock_free(), we can unify > pagetable_p*_dtor() i

Re: [PATCH v8 0/7] PCI: Consolidate TLP Log reading and printing

2025-01-08 Thread Yazen Ghannam
On Wed, Dec 18, 2024 at 04:37:40PM +0200, Ilpo Järvinen wrote: > This series has the remaining patches of the AER & DPC TLP Log handling > consolidation and now includes a few minor improvements to the earlier > accepted TLP Logging code. > > v8: > - Added missing parameter to kerneldoc. > - Dropp

Re: [PATCH v2] perf: Fix display of kernel symbols

2025-01-08 Thread Arnaldo Carvalho de Melo
On Wed, Jan 08, 2025 at 10:54:20AM +0100, Christophe Leroy wrote: > Since commit 659ad3492b91 ("perf maps: Switch from rbtree to lazily > sorted array for addresses"), perf doesn't display anymore kernel > symbols on powerpc, allthough it still detects them as kernel addresses. > > # Overhea

Re: [PATCH] KVM: allow NULL writable argument to __kvm_faultin_pfn

2025-01-08 Thread Sean Christopherson
On Mon, Jan 06, 2025, Sean Christopherson wrote: > On Wed, Jan 01, 2025, Paolo Bonzini wrote: > > kvm_follow_pfn() is able to work with NULL in the .map_writable field > > of the homonymous struct. But __kvm_faultin_pfn() rejects the combo > > despite KVM for e500 trying to use it. Indeed .map_wr

Re: [PATCH 03/14] ibmvnic: simplify ibmvnic_set_queue_affinity()y

2025-01-08 Thread Nick Child
On Tue, Jan 07, 2025 at 03:04:40PM -0800, Yury Norov wrote: > On Tue, Jan 07, 2025 at 02:43:01PM -0800, Yury Norov wrote: > > On Tue, Jan 07, 2025 at 04:37:17PM -0600, Nick Child wrote: > > > On Sat, Dec 28, 2024 at 10:49:35AM -0800, Yury Norov wrote: > > > > A loop based on cpumask_next_wrap() ope

Re: [PATCH v3 5/6] s390/crash: Use note name macros

2025-01-08 Thread Dave Martin
On Wed, Jan 08, 2025 at 01:53:51PM +0900, Akihiko Odaki wrote: > On 2025/01/08 1:17, Dave Martin wrote: > > Hi, > > > > On Tue, Jan 07, 2025 at 09:45:56PM +0900, Akihiko Odaki wrote: > > > Use note name macros to match with the userspace's expectation. > > > > > > Signed-off-by: Akihiko Odaki >

Re: [PATCH v3 2/6] binfmt_elf: Use note name macros

2025-01-08 Thread Dave Martin
Hi, On Wed, Jan 08, 2025 at 01:34:24PM +0900, Akihiko Odaki wrote: > On 2025/01/08 1:18, Dave Martin wrote: > > On Tue, Jan 07, 2025 at 09:45:53PM +0900, Akihiko Odaki wrote: > > > Use note name macros to match with the userspace's expectation. > > > > Also (and more importantly) get rid of dupli

Re: [PATCH v3 5/6] s390/crash: Use note name macros

2025-01-08 Thread Heiko Carstens
On Wed, Jan 08, 2025 at 01:53:51PM +0900, Akihiko Odaki wrote: > On 2025/01/08 1:17, Dave Martin wrote: > > > +#define NT_INIT(buf, type, desc) \ > > > + (nt_init_name((buf), NT_ ## type, &(desc), sizeof(desc), NN_ ## type)) > > > > Nit: this macro name clashes with the naming scheme in elf.h. > >

Re: [PATCH RESEND v1 5/5] crash: option to let arch decide mem range is usable

2025-01-08 Thread Sourabh Jain
On 08/01/25 17:08, Baoquan he wrote: On 01/08/25 at 03:44pm, Sourabh Jain wrote: ...snip... diff --git a/include/linux/kexec.h b/include/linux/kexec.h index f0e9f8eda7a3..407f8b0346aa 100644 --- a/include/linux/kexec.h +++ b/include/linux/kexec.h @@ -205,6 +205,15 @@ static inline int arch_

Re: [PATCH RESEND v1 2/5] crash: let arch decide crash memory export to iomem_resource

2025-01-08 Thread Sourabh Jain
Hello Baoquan On 08/01/25 16:55, Baoquan he wrote: Hi, On 01/08/25 at 03:44pm, Sourabh Jain wrote: insert_crashkernel_resources() adds crash memory to iomem_resource if generic crashkernel reservation is enabled on an architecture. On PowerPC, system RAM is added to iomem_resource. See commit

Re: [PATCH RESEND v1 5/5] crash: option to let arch decide mem range is usable

2025-01-08 Thread Baoquan he
On 01/08/25 at 03:44pm, Sourabh Jain wrote: ...snip... > diff --git a/include/linux/kexec.h b/include/linux/kexec.h > index f0e9f8eda7a3..407f8b0346aa 100644 > --- a/include/linux/kexec.h > +++ b/include/linux/kexec.h > @@ -205,6 +205,15 @@ static inline int > arch_kimage_file_post_load_cleanup(st

Re: [PATCH RESEND v1 2/5] crash: let arch decide crash memory export to iomem_resource

2025-01-08 Thread Baoquan he
Hi, On 01/08/25 at 03:44pm, Sourabh Jain wrote: > insert_crashkernel_resources() adds crash memory to iomem_resource if > generic crashkernel reservation is enabled on an architecture. > > On PowerPC, system RAM is added to iomem_resource. See commit > c40dd2f766440 ("powerpc: Add System RAM to /

Re: [PATCH RESEND v1 1/5] crash: remove an unused argument from reserve_crashkernel_generic()

2025-01-08 Thread Baoquan he
On 01/08/25 at 03:44pm, Sourabh Jain wrote: > cmdline argument is not used in reserve_crashkernel_generic() so remove > it. Correspondingly, all the callers have been updated as well. > > No functional change intended. > > Cc: Andrew Morton > Cc: Baoquan he > Cc: Hari Bathini > CC: Madhavan Sr

Re: [PATCH v5 14/17] mm: pgtable: introduce generic __tlb_remove_table()

2025-01-08 Thread Arnd Bergmann
On Wed, Jan 8, 2025, at 07:57, Qi Zheng wrote: > Several architectures (arm, arm64, riscv and x86) define exactly the > same __tlb_remove_table(), just introduce generic __tlb_remove_table() to > eliminate these duplications. > > The s390 __tlb_remove_table() is nearly the same, so also make s390 >

Re: [PATCH v5 03/17] asm-generic: pgalloc: Provide generic p4d_{alloc_one,free}

2025-01-08 Thread Arnd Bergmann
On Wed, Jan 8, 2025, at 07:57, Qi Zheng wrote: > From: Kevin Brodsky > > Four architectures currently implement 5-level pgtables: arm64, > riscv, x86 and s390. The first three have essentially the same > implementation for p4d_alloc_one() and p4d_free(), so we've got an > opportunity to reduce dup

Re: [PATCH v3 01/28] module: Extend the preempt disabled section in dereference_symbol_descriptor().

2025-01-08 Thread Sebastian Andrzej Siewior
On 2025-01-08 10:55:04 [+0100], Helge Deller wrote: > Nice catch. > > Acked-by: Helge Deller > > This patch really should be backported. > Can you add a Cc: stable tag? It should be picked due to the fixes tag. I add it if I am going to repost it. > Helge Sebastian

[PATCH] powerpc/vmlinux: Remove etext, edata and end

2025-01-08 Thread Christophe Leroy
etext is not used anymore since commit 843a1ffaf6f2 ("powerpc/mm: use core_kernel_text() helper") edata and end have not been used since the merge of arch/ppc/ and arch/ppc64/ Remove the three and remove macro PROVIDE32. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/vmlinux.lds.S

[PATCH] powerpc/44x: Declare primary_uic static in uic.c

2025-01-08 Thread Christophe Leroy
primary_uic is not used outside uic.c, declare it static. Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202411101746.ld8ydvzy-...@intel.com/ Fixes: e58923ed1437 ("[POWERPC] Add arch/powerpc driver for UIC, PPC4xx interrupt controller") Signed-off-by: Christophe Le

[PATCH v2] perf: Fix display of kernel symbols

2025-01-08 Thread Christophe Leroy
Since commit 659ad3492b91 ("perf maps: Switch from rbtree to lazily sorted array for addresses"), perf doesn't display anymore kernel symbols on powerpc, allthough it still detects them as kernel addresses. # Overhead Command Shared Object Symbol # .. .

[PATCH] powerpc/64s: Rewrite __real_pte() as a static inline

2025-01-08 Thread Christophe Leroy
Rewrite __real_pte() as a static inline in order to avoid following warning/error when building with 4k page size: CC arch/powerpc/mm/book3s64/hash_tlb.o arch/powerpc/mm/book3s64/hash_tlb.c: In function 'hpte_need_flush': arch/powerpc/mm/book3s64/hash_tlb.c:49:16: er

[PATCH RESEND v1 5/5] crash: option to let arch decide mem range is usable

2025-01-08 Thread Sourabh Jain
On PowerPC, the memory reserved for the crashkernel can contain components like RTAS, TCE, OPAL, etc., which should be avoided when loading kexec segments into crashkernel memory. Due to these special components, PowerPC has its own set of functions to locate holes in the crashkernel memory for loa

[PATCH RESEND v1 4/5] powerpc/crash: use generic crashkernel reservation

2025-01-08 Thread Sourabh Jain
Commit 0ab97169aa05 ("crash_core: add generic function to do reservation") added a generic function to reserve crashkernel memory. So let's use the same function on powerpc and remove the architecture-specific code that essentially does the same thing. The generic crashkernel reservation also prov

[PATCH RESEND v1 3/5] powerpc/kdump: preserve user-specified memory limit

2025-01-08 Thread Sourabh Jain
Commit 59d58189f3d9 ("crash: fix crash memory reserve exceed system memory bug") fails crashkernel parsing if the crash size is found to be higher than system RAM, which makes the memory_limit adjustment code ineffective due to an early exit from reserve_crashkernel(). Regardless lets not violated

[PATCH RESEND v1 1/5] crash: remove an unused argument from reserve_crashkernel_generic()

2025-01-08 Thread Sourabh Jain
cmdline argument is not used in reserve_crashkernel_generic() so remove it. Correspondingly, all the callers have been updated as well. No functional change intended. Cc: Andrew Morton Cc: Baoquan he Cc: Hari Bathini CC: Madhavan Srinivasan Cc: Michael Ellerman Cc: ke...@lists.infradead.org

[PATCH RESEND v1 0/5] powerpc/crash: use generic crashkernel reservation

2025-01-08 Thread Sourabh Jain
Commit 0ab97169aa05 ("crash_core: add generic function to do reservation") added a generic function to reserve crashkernel memory. So let's use the same function on powerpc and remove the architecture-specific code that essentially does the same thing. The generic crashkernel reservation also prov

[PATCH RESEND v1 2/5] crash: let arch decide crash memory export to iomem_resource

2025-01-08 Thread Sourabh Jain
insert_crashkernel_resources() adds crash memory to iomem_resource if generic crashkernel reservation is enabled on an architecture. On PowerPC, system RAM is added to iomem_resource. See commit c40dd2f766440 ("powerpc: Add System RAM to /proc/iomem"). Enabling generic crashkernel reservation on

[PATCH] perf machine: Don't ignore _etext when not a text symbol

2025-01-08 Thread Christophe Leroy
Depending on how vmlinux.lds is written, _etext might be the very first data symbol instead of the very last text symbol. Don't require it to be a text symbol, accept any symbol type. Fixes: ed9adb2035b5 ("perf machine: Read also the end of the kernel") Signed-off-by: Christophe Leroy --- tools

[PATCH] kallsyms: Always include _edata

2025-01-08 Thread Christophe Leroy
Since commit 69a87a32f5cd ("perf machine: Include data symbols in the kernel map"), perf needs _edata symbol. Make sure it is always included in /proc/kallsyms and not only when CONFIG_KALLSYMS_ALL is selected. Signed-off-by: Christophe Leroy Fixes: 69a87a32f5cd ("perf machine: Include data symb

Re: [PATCH v3 01/28] module: Extend the preempt disabled section in dereference_symbol_descriptor().

2025-01-08 Thread Helge Deller
On 1/8/25 10:04, Sebastian Andrzej Siewior wrote: dereference_symbol_descriptor() needs to obtain the module pointer belonging to pointer in order to resolve that pointer. The returned mod pointer is obtained under RCU-sched/ preempt_disable() guarantees and needs to be used within this section t

[PATCH] PCI/AER: Add kernel.aer_print_skip_mask to control aer log

2025-01-08 Thread Bijie Xu
Sometimes certain PCIE devices installed on some servers occasionally produce large number of AER correctable error logs, which is quite annoying. Add this sysctl parameter kernel.aer_print_skip_mask to skip printing AER errors of certain severity. The AER severity can be 0(NONFATAL), 1(FATAL), 2(

[PATCH v3 01/28] module: Extend the preempt disabled section in dereference_symbol_descriptor().

2025-01-08 Thread Sebastian Andrzej Siewior
dereference_symbol_descriptor() needs to obtain the module pointer belonging to pointer in order to resolve that pointer. The returned mod pointer is obtained under RCU-sched/ preempt_disable() guarantees and needs to be used within this section to ensure that the module is not removed in the meant

[PATCH v3 20/28] powerpc/ftrace: Use RCU in all users of __module_text_address().

2025-01-08 Thread Sebastian Andrzej Siewior
__module_text_address() can be invoked within a RCU section, there is no requirement to have preemption disabled. Replace the preempt_disable() section around __module_text_address() with RCU. Cc: Christophe Leroy Cc: Madhavan Srinivasan Cc: Mark Rutland Cc: Masami Hiramatsu Cc: Michael Eller

Re: [PATCH v5 11/17] x86: pgtable: convert __tlb_remove_table() to use struct ptdesc

2025-01-08 Thread Kevin Brodsky
On 08/01/2025 07:57, Qi Zheng wrote: > Convert __tlb_remove_table() to use struct ptdesc, which will help to move > pagetable_dtor() to __tlb_remove_table(). > > And page tables shouldn't have swap cache, so use pagetable_free() instead > of free_page_and_swap_cache() to free page table pages. > >