[PATCH v2 4/4] powerpc/boot/install.sh: Fix shellcheck warnings

2025-05-17 Thread Madhavan Srinivasan
Fix shellcheck warning such as "Double quote to prevent globbing and word splitting." and Use $(...) notation instead of legacy backticks `...`. Tested-by: Venkat Rao Bagalkote Signed-off-by: Madhavan Srinivasan --- Changelog v1: -Added tested by tag arch/powerpc/boot/install.sh | 14 +++--

[PATCH v2 3/4] powerpc/prom_init: Fix shellcheck warnings

2025-05-17 Thread Madhavan Srinivasan
Fix "Double quote to prevent globbing and word splitting." warning from shellcheck Reviewed-by: Stephen Rothwell Tested-by: Venkat Rao Bagalkote Signed-off-by: Madhavan Srinivasan --- Changelog v1: - Added tags arch/powerpc/kernel/prom_init_check.sh | 16 1 file changed, 8 in

[PATCH v2 2/4] powerpc/perf: make isa207_pmu_format_group struct static

2025-05-17 Thread Madhavan Srinivasan
isa207_pmu_format_group struct is local to the source and does not need to be in global scope, so make it static Cleans up sparse warning: arch/powerpc/perf/isa207-common.c:40:30: warning: symbol 'isa207_pmu_format_group' was not declared. Should it be static? Tested-by: Venkat Rao Bagalkote Si

[PATCH v2 1/4] powerpc/kvm: Fix ifdef to remove build warning

2025-05-17 Thread Madhavan Srinivasan
When compiling for pseries or powernv defconfig with "make C=1", these warning were reported bu sparse tool in powerpc/kernel/kvm.c arch/powerpc/kernel/kvm.c:635:9: warning: switch with no cases arch/powerpc/kernel/kvm.c:646:9: warning: switch with no cases Currently #ifdef were added after the s

Re: [PATCH] powerpc: Replace strcpy() with strscpy() in proc_ppc64_init()

2025-05-17 Thread Madhavan Srinivasan
On Mon, 21 Apr 2025 20:31:08 +0200, Thorsten Blum wrote: > strcpy() is deprecated; use strscpy() instead. > > Don't cast the destination buffer from 'u8[]' to 'char *' to satisfy the > __must_be_array() requirement of strscpy(). > > No functional changes intended. > > [...] Applied to powerpc/n

Re: [PATCH 4/6] powerpc: fix sparse warnings

2025-05-17 Thread Madhavan Srinivasan
On 5/2/25 3:46 PM, Christophe Leroy wrote: > > > Le 22/04/2025 à 15:10, Madhavan Srinivasan a écrit : >> structs are local to the source and does not need to >> be in global scope, so make it static. >> >> Signed-off-by: Madhavan Srinivasan >> --- >>   arch/powerpc/kernel/btext.c 

Re: [PATCH 2/6] powerpc/xmon: fix sparse warning "Using plain integer as NULL pointer"

2025-05-17 Thread Madhavan Srinivasan
On 5/2/25 3:38 PM, Christophe Leroy wrote: > > > Le 22/04/2025 à 15:10, Madhavan Srinivasan a écrit : >> Fix passing of argument 0 to NULL to avoid sparse warning > > I thought we wanted to keep this file in sync with opcodes/ppc-opc.c in the > binutils repository. > > Are you sure you want

Re: [PATCH] powerpc: Transliterate author name and remove FIXME

2025-05-17 Thread Madhavan Srinivasan
On Sun, 10 Nov 2024 17:21:37 +0100, Thorsten Blum wrote: > The name is Mimi Phuong-Thao Vo. > > Applied to powerpc/next. [1/1] powerpc: Transliterate author name and remove FIXME https://git.kernel.org/powerpc/c/8bc3252436d371e7ac505f9f2685611090680a48 Thanks

Re: [PATCH] powerpc/powermac: Use str_enabled_disabled() and str_on_off() helpers

2025-05-17 Thread Madhavan Srinivasan
On Fri, 17 Jan 2025 12:46:20 +0100, Thorsten Blum wrote: > Remove hard-coded strings by using the str_enabled_disabled() and > str_on_off() helper functions. > > Applied to powerpc/next. [1/1] powerpc/powermac: Use str_enabled_disabled() and str_on_off() helpers https://git.kernel.org/pow

Re: [PATCH] powerpc/iommu: Use str_disabled_enabled() helper

2025-05-17 Thread Madhavan Srinivasan
On Mon, 10 Feb 2025 23:42:44 +0100, Thorsten Blum wrote: > Remove hard-coded strings by using the str_disabled_enabled() helper. > > Applied to powerpc/next. [1/1] powerpc/iommu: Use str_disabled_enabled() helper https://git.kernel.org/powerpc/c/f15e87340afd4f5a35575e112aa4bdb0a138aa26 T

Re: [PATCH] powerpc/mm/fault: Use str_write_read() helper function

2025-05-17 Thread Madhavan Srinivasan
On Mon, 10 Feb 2025 11:06:46 +0100, Thorsten Blum wrote: > Remove hard-coded strings by using the str_write_read() helper function. > > Applied to powerpc/next. [1/1] powerpc/mm/fault: Use str_write_read() helper function https://git.kernel.org/powerpc/c/ff27a9a0c66cfeb6a15d8f2ab4754f312e

Re: [PATCH] powerpc/kernel: Fix ppc_save_regs inclusion in build

2025-05-17 Thread Madhavan Srinivasan
On Sun, 11 May 2025 09:41:11 +0530, Madhavan Srinivasan wrote: > Recent patch fixed an old commit > 'fc2a5a6161a2 ("powerpc/64s: ppc_save_regs is now needed for all 64s builds")' > which is to include building of ppc_save_reg.c only when XMON > and KEXEC_CORE and PPC_BOOK3S are enabled. This was va

Re: [PATCH v3] powerpc/pseries/iommu: Fix kmemleak in TCE table userspace view

2025-05-17 Thread Madhavan Srinivasan
On Mon, 12 May 2025 17:46:53 -0500, Gaurav Batra wrote: > When a device is opened by a userspace driver, via VFIO interface, DMA > window is created. This DMA window has TCE Table and a corresponding > data for userview of TCE table. > > When the userspace driver closes the device, all the above i

Re: [PATCH] powerpc/8xx: Reduce alignment constraint for kernel memory

2025-05-17 Thread Madhavan Srinivasan
On Fri, 02 May 2025 15:07:53 +0200, Christophe Leroy wrote: > 8xx has three large page sizes: 8M, 512k and 16k. > > A too big alignment can lead to wasting memory. On a board which has > only 32 MBytes of RAM, every single byte is worth it and a 512k > alignment is sometimes too much. > > Allow m

Re: [PATCH] KVM: PPC: Book3S HV: Fix IRQ map warnings with XICS on pSeries KVM Guest

2025-05-17 Thread Madhavan Srinivasan
On Sat, 26 Apr 2025 00:26:41 +0530, Amit Machhiwal wrote: > The commit 9576730d0e6e ("KVM: PPC: select IRQ_BYPASS_MANAGER") enabled > IRQ_BYPASS_MANAGER when CONFIG_KVM was set. Subsequently, commit > c57875f5f9be ("KVM: PPC: Book3S HV: Enable IRQ bypass") enabled IRQ > bypass and added the necessa

Re: [PATCH] powerpc/pseries/htmdump: Include header file to get is_kvm_guest() definition

2025-05-17 Thread Madhavan Srinivasan
On Tue, 06 May 2025 19:22:32 +0530, Athira Rajeev wrote: > htmdump_init calls is_kvm_guest() to check for guest environment. > is_kvm_guest() is defined in kvm_guest.h header file. Without including > the header file, build hits error failing to find the function. > > arch/powerpc/platforms/pser

[PATCH] docs: powerpc: Add htm.rst to table of contents

2025-05-17 Thread Brigham Campbell
These changes fix the following error, which was introduced by commit ab1456c5 when Documentation/arch/powerpc/htm.rst was added to the repository without any reference to the document. Documentation/arch/powerpc/htm.rst: WARNING: document isn't included in any toctree [toc.not_included] Signed-

Re: [PATCH 0/6] bus: fsl-mc: cleanup and fixes

2025-05-17 Thread Christophe Leroy
On Tue, 08 Apr 2025 13:58:08 +0300, Ioana Ciornei wrote: > This patch set is a combination of small fixes and some cleanup. Some > of the patches were already submitted in the past years but were lost in > the process due to an uncertain maintenance path. > > Ioana Ciornei (3): > bus: fsl-mc:

Re: [PATCH] soc: fsl: qe: Consolidate chained IRQ handler install/remove

2025-05-17 Thread Christophe Leroy
On Thu, 15 May 2025 16:39:19 +0800, Chen Ni wrote: > Chained irq handlers usually set up handler data as well. > irq_set_chained_handler_and_data() can set both under irq_desc->lock. > Replace the two calls with one. > > Applied, thanks! [1/1] soc: fsl: qe: Consolidate chained IRQ handler ins

Re: [PATCH] soc: fsl: Do not enable DPAA2_CONSOLE by default during compile testing

2025-05-17 Thread Christophe Leroy
On Fri, 04 Apr 2025 13:24:07 +0200, Krzysztof Kozlowski wrote: > Enabling the compile test should not cause automatic enabling of such > drivers. > > Applied, thanks! [1/1] soc: fsl: Do not enable DPAA2_CONSOLE by default during compile testing commit: 617a7ed073115016e417b518c68c96057f

Re: [PATCH] KVM: PPC: Book3S HV: Add H_VIRT mapping for tracing exits

2025-05-17 Thread IBM
Gautam Menghani writes: > The macro kvm_trace_symbol_exit is used for providing the mappings > for the trap vectors and their names. Add mapping for H_VIRT so that > trap reason is displayed as string instead of a vector number when using > the kvm_guest_exit tracepoint. > trace_kvm_guest_exit(v

[PATCH v2] powerpc: Fix struct termio related ioctl macros

2025-05-17 Thread Madhavan Srinivasan
Since termio interface is now obsolete, include/uapi/asm/ioctls.h has some constant macros referring to "struct termio", this caused build failure at userspace. In file included from /usr/include/asm/ioctl.h:12, from /usr/include/asm/ioctls.h:5, from tst-ioctls.c:

Re: [PATCH] soc: fsl: qbman: Remove const from portal->cgrs allocation type

2025-05-17 Thread Christophe Leroy
On Fri, 25 Apr 2025 23:20:41 -0700, Kees Cook wrote: > In preparation for making the kmalloc family of allocators type aware, > we need to make sure that the returned type from the allocation matches > the type of the variable being assigned. (Before, the allocator would > always return "void *",

Re: [PATCH] bus: fsl-mc: Use strscpy() instead of strscpy_pad()

2025-05-17 Thread Christophe Leroy
On Sun, 13 Apr 2025 19:29:50 +0200, Thorsten Blum wrote: > Both destination buffers are already zero-initialized, making strscpy() > sufficient for safely copying 'obj_type'. The additional NUL-padding > performed by strscpy_pad() is unnecessary. > > If the destination buffer has a fixed length,

[PATCH] powerpc: Fix indentation and replace typedef with struct name

2025-05-17 Thread Thorsten Blum
Indent several struct members using tabs instead of spaces. Replace the typedef alias AOUTHDR with an explicit struct name to silence a checkpatch warning. Signed-off-by: Thorsten Blum --- arch/powerpc/boot/hack-coff.c | 2 +- arch/powerpc/boot/rs6000.h| 84 +---

Re: [RESEND PATCH] bus: fsl-mc: Use strscpy() instead of strscpy_pad()

2025-05-17 Thread Christophe Leroy
On Tue, 29 Apr 2025 12:41:48 +0200, Thorsten Blum wrote: > Both destination buffers are already zero-initialized, making strscpy() > sufficient for safely copying 'obj_type'. The additional NUL-padding > performed by strscpy_pad() is unnecessary. > > If the destination buffer has a fixed length,

Re: [PATCH] bus: fsl_mc: Fix driver_managed_dma check

2025-05-17 Thread Christophe Leroy
On Fri, 25 Apr 2025 14:39:28 +0100, Robin Murphy wrote: > Since it's not currently safe to take device_lock() in the IOMMU probe > path, that can race against really_probe() setting dev->driver before > attempting to bind. The race itself isn't so bad, since we're only > concerned with dereferenc