[PATCH 04/13] mm: Make HPAGE_PXD_* macros even if !THP

2023-12-18 Thread peterx
From: Peter Xu These macros can be helpful when we plan to merge hugetlb code into generic code. Move them out and define them even if !THP. We actually already defined HPAGE_PMD_NR for other reasons even if !THP. Reorganize these macros. Reviewed-by: Christoph Hellwig Signed-off-by: Peter Xu

[PATCH 03/13] mm: Provide generic pmd_thp_or_huge()

2023-12-18 Thread peterx
From: Peter Xu ARM defines pmd_thp_or_huge(), detecting either a THP or a huge PMD. It can be a helpful helper if we want to merge more THP and hugetlb code paths. Make it a generic default implementation, only exist when CONFIG_MMU. Arch can overwrite it by defining its own version. For exam

[PATCH 02/13] mm/hugetlb: Declare hugetlbfs_pagecache_present() non-static

2023-12-18 Thread peterx
From: Peter Xu It will be used outside hugetlb.c soon. Signed-off-by: Peter Xu --- include/linux/hugetlb.h | 9 + mm/hugetlb.c| 4 ++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/include/linux/hugetlb.h b/include/linux/hugetlb.h index 236ec7b63c54..f8c5

[PATCH 01/13] mm/Kconfig: CONFIG_PGTABLE_HAS_HUGE_LEAVES

2023-12-18 Thread peterx
From: Peter Xu Introduce a config option that will be selected as long as huge leaves are involved in pgtable (thp or hugetlbfs). It would be useful to mark any code with this new config that can process either hugetlb or thp pages in any level that is higher than pte level. Signed-off-by: Pete

[PATCH 00/13] mm/gup: Unify hugetlb, part 2

2023-12-18 Thread peterx
From: Peter Xu This is v1 of the series. The series removes the hugetlb slow gup path after a previous refactor work [1], so that slow gup now uses the exact same path to handle all kinds of memory including hugetlb. It's based on latest mm-unstalbe (c13bdc82ada9). RFC->v1 (use old verion's pa

Re: [RFC PATCH 1/3] powerpc/pseries/fadump: add support for multiple boot memory regions

2023-12-18 Thread Sourabh Jain
Hello Aditya, On 17/12/23 14:11, Aditya Gupta wrote: Hi sourabh, On 06/12/23 01:48, Hari Bathini wrote: From: Sourabh Jain Currently, fadump on pseries assumes a single boot memory region even though f/w supports more than one boot memory region. Add support for more boot memory regions to m

Re: [RESEND PATCH] powerpc/fsl: fix the schema check errors for fsl,tmu-calibration

2023-12-18 Thread Michael Ellerman
David Heidelberg writes: > On 13/12/2023 06:17, Michael Ellerman wrote: >> David Heidelberg writes: >>> fsl,tmu-calibration is in u32-matrix. Use matching property syntax. >>> No functional changes. Fixes warnings as: >>> $ make dtbs_check >>> ... >>> arch/arm64/boot/dts/freescale/imx8mq-librem5-

Re: [PATCH v1 2/2] powerpc/debug: hook to user return notifier infrastructure

2023-12-18 Thread Michael Ellerman
Aneesh Kumar K.V writes: > Luming Yu writes: > >> Before we have powerpc to use the generic entry infrastructure, >> the call to fire user return notifier is made temporarily in powerpc >> entry code. >> > > It is still not clear what will be registered as user return notifier. > Can you summariz

Re: [kvm-unit-tests PATCH v5 10/29] powerpc/sprs: Specify SPRs with data rather than code

2023-12-18 Thread Thomas Huth
On 16/12/2023 14.42, Nicholas Piggin wrote: A significant rework that builds an array of 'struct spr', where each element describes an SPR. This makes various metadata about the SPR like name and access type easier to carry and use. Hypervisor privileged registers are described despite not being

Re: [kvm-unit-tests PATCH v5 09/29] powerpc: Fix interrupt stack alignment

2023-12-18 Thread Thomas Huth
On 16/12/2023 14.42, Nicholas Piggin wrote: ppc64 requires the stack to be 16-byte aligned but the interrupt stack frame has 8-byte aligned size. Add padding to fix. Signed-off-by: Nicholas Piggin --- lib/powerpc/setup.c| 3 +++ lib/ppc64/asm/ptrace.h | 1 + 2 files changed, 4 insertion

Re: [kvm-unit-tests PATCH v5 08/29] powerpc: Require KVM for the TM test

2023-12-18 Thread Thomas Huth
On 16/12/2023 14.42, Nicholas Piggin wrote: QEMU TCG does not support TM. Skip this test gracefully when not on KVM. Signed-off-by: Nicholas Piggin --- powerpc/unittests.cfg | 1 + 1 file changed, 1 insertion(+) diff --git a/powerpc/unittests.cfg b/powerpc/unittests.cfg index dd5f361c..e711

Re: [kvm-unit-tests PATCH v5 07/29] powerpc: Add a migration stress tester

2023-12-18 Thread Thomas Huth
On 16/12/2023 14.42, Nicholas Piggin wrote: This performs 1000 migrations a tight loop to flush out simple issues in the multiple-migration code. Signed-off-by: Nicholas Piggin --- powerpc/Makefile.common | 1 + powerpc/migrate.c | 64 + 2 file

Re: [kvm-unit-tests PATCH v5 06/29] powerpc: Quiet QEMU TCG pseries capability warnings

2023-12-18 Thread Thomas Huth
On 16/12/2023 14.42, Nicholas Piggin wrote: Quieten this console spam. Signed-off-by: Nicholas Piggin --- powerpc/run | 5 + 1 file changed, 5 insertions(+) diff --git a/powerpc/run b/powerpc/run index b353169f..e469f1eb 100755 --- a/powerpc/run +++ b/powerpc/run @@ -21,6 +21,11 @@ fi

[PATCH v2] ASoC: fsl_sai: Fix channel swap issue on i.MX8MP

2023-12-18 Thread Shengjiu Wang
When flag mclk_with_tere and mclk_direction_output enabled, The SAI transmitter or receiver will be enabled in very early stage, that if FSL_SAI_xMR is set by previous case, for example previous case is one channel, current case is two channels, then current case started with wrong xMR in the begin

Re: [PATCH v5 0/6] DCP as trusted keys backend

2023-12-18 Thread Paul Moore
On Fri, Dec 15, 2023 at 6:07 AM David Gstir wrote: > > This is a revival of the previous patch set submitted by Richard Weinberger: > https://lore.kernel.org/linux-integrity/20210614201620.30451-1-rich...@nod.at/ > > v4 is here: > https://lore.kernel.org/keyrings/20231024162024.51260-1-da...@sigma

[PATCHv3 RESEND 03/10] ASoC: fsl-asoc-card: add compatibility to use 2 codecs in dai-links

2023-12-18 Thread Elinor Montmasson
Adapt the driver to work with configurations using two codecs or more. Modify fsl_asoc_card_probe() to handle use cases where 2 codecs are given in the device tree. This will be needed for the generic codec case. Use cases using one codec will ignore any given codecs other than the first. Signed-

[PATCHv3 RESEND 08/10] ASoC: fsl-asoc-card: add dts properties "cpu-sysclk-freq"

2023-12-18 Thread Elinor Montmasson
Add new optional dts property "cpu-sysclk-freq" to set custom sysclk frequencies for the CPU DAI with the generic codec. The way values are used is up to the CPU DAI driver implementation. Signed-off-by: Elinor Montmasson Co-authored-by: Philip-Dylan Gleonec --- sound/soc/fsl/fsl-asoc-card.c |

[PATCHv3 RESEND 00/10] ASoC: fsl-asoc-card: compatibility integration of a generic codec use case for use with S/PDIF controller

2023-12-18 Thread Elinor Montmasson
Hello, This is the v3 of the series of patch aiming to make the machine driver "fsl-asoc-card" compatible with use cases where there is no real codec driver. It proposes to use the "spdif_receiver" and "spdif_transmitter" drivers instead of the dummy codec. This is a first step in using the S/PDIF

[PATCHv3 RESEND 01/10] ASoC: fsl-asoc-card: add support for dai links with multiple codecs

2023-12-18 Thread Elinor Montmasson
Add support for dai links using multiple codecs for multi-codec use cases. Signed-off-by: Elinor Montmasson Co-authored-by: Philip-Dylan Gleonec --- sound/soc/fsl/fsl-asoc-card.c | 22 ++ 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/sound/soc/fsl/fsl-asoc-c

[PATCHv3 RESEND 05/10] ASoC: fsl-asoc-card: set generic codec as clock provider

2023-12-18 Thread Elinor Montmasson
The default dai format defined by DAI_FMT_BASE doesn't set if the codec is consumer or provider of the bit and frame clocks. S/PDIF DIR usually converts audio signal to an asynchronous I2S/PCM stream, and doesn't consume a bit or frame clock. As S/PDIF DIR and DIT are used as codecs for the gener

[PATCHv3 RESEND 07/10] ASoC: fsl-asoc-card: add dts property "cpu-slot-num"

2023-12-18 Thread Elinor Montmasson
Add new optional dts property "cpu-slot-num", which allows setting a custom number of TDM slots for the CPU DAI when using the generic codec. Signed-off-by: Elinor Montmasson Co-authored-by: Philip-Dylan Gleonec --- sound/soc/fsl/fsl-asoc-card.c | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCHv3 RESEND 06/10] ASoC: fsl-asoc-card: add dts property "cpu-slot-width"

2023-12-18 Thread Elinor Montmasson
Add new optional dts property "cpu-slot-width", which allows setting a custom TDM slot width in bits for the CPU DAI when using the generic codec. Signed-off-by: Elinor Montmasson Co-authored-by: Philip-Dylan Gleonec --- sound/soc/fsl/fsl-asoc-card.c | 1 + 1 file changed, 1 insertion(+) diff

[PATCHv3 RESEND 02/10] ASoC: fsl-asoc-card: add second dai link component for codecs

2023-12-18 Thread Elinor Montmasson
Add a second dai link component for codecs that will be used for the generic codec use case. It will use spdif_receiver and spdif_transmitter drivers as dummy codec drivers, needing 2 codecs slots for the links. To prevent deferring in use cases using only one codec, also set by default the number

[PATCHv3 RESEND 04/10] ASoC: fsl-asoc-card: add new compatible for a generic codec use case

2023-12-18 Thread Elinor Montmasson
Add the new compatible "fsl,imx-audio-generic" for a generic codec use case. It allows using the fsl-asoc-card driver with the spdif_receiver and spdif_transmitter codec drivers used as dummy codecs. It can be used for cases where there is no real codec or codecs which do not require declaring cont

[PATCHv3 RESEND 10/10] ASoC: dt-bindings: fsl-asoc-card: add compatible for generic codec

2023-12-18 Thread Elinor Montmasson
Add documentation about new dts bindings following new support for compatible "fsl,imx-audio-generic". Some CPU DAI don't require a real audio codec. The new compatible "fsl,imx-audio-generic" allows using the driver with codec drivers SPDIF DIT and SPDIF DIR as dummy codecs. It also allows using

[PATCHv3 RESEND 09/10] ASoC: fsl-asoc-card: add dts properties "cpu-sysclk-dir-out"

2023-12-18 Thread Elinor Montmasson
Add new optional dts properties "cpu-sysclk-dir-out" to set sysclk directions as "out" for the CPU DAI when using the generic codec. This can be set for Tx and Rx. If not set, the direction is "in". The way values are used is up to the CPU DAI driver implementation. Signed-off-by: Elinor Montmasso

Re: powerpc: several early boot regressions on MPC52xx

2023-12-18 Thread Christophe Leroy
Hi Matthias, Le 18/12/2023 à 14:48, Matthias Schiffer a écrit : > Hi all, > > I'm currently in the process of porting our ancient TQM5200 SoM to a modern > kernel, and I've > identified a number of regressions that cause early boot failures (before the > UART console has been > initialized) wit

Re: [PATCHv3 RESEND 00/10] ASoC: fsl-asoc-card: compatibility integration of a generic codec use case for use with S/PDIF controller

2023-12-18 Thread Daniel Baluta
> > * fsl-asoc-card.txt currently follows the old dt-bindings format. > Should we update it to DT schema format in this patch series > before adding my new properties? > > I know this is extra-work but we would greatly appreciate if you first convert fsl-asoc-card.txt to yml format and then add yo

powerpc: several early boot regressions on MPC52xx

2023-12-18 Thread Matthias Schiffer
Hi all, I'm currently in the process of porting our ancient TQM5200 SoM to a modern kernel, and I've identified a number of regressions that cause early boot failures (before the UART console has been initialized) with arch/powerpc/configs/52xx/tqm5200_defconfig. Issue 1) Boot fails with CONFIG

Re: [PATCH v4 02/10] locking: introduce devm_mutex_init

2023-12-18 Thread George Stark
Hello Christophe On 12/17/23 12:31, Christophe Leroy wrote: ... ---     include/linux/mutex.h    | 23 +++     kernel/locking/mutex-debug.c | 22 ++     2 files changed, 45 insertions(+) diff --git a/include/linux/mutex.h b/include/linux/mutex.h in

Re: [PATCHv3 RESEND 00/10] ASoC: fsl-asoc-card: compatibility integration of a generic codec use case for use with S/PDIF controller

2023-12-18 Thread Krzysztof Kozlowski
On 18/12/2023 13:40, Elinor Montmasson wrote: > Hello, > > This is the v3 of the series of patch aiming to make the machine driver > "fsl-asoc-card" compatible with use cases where there is no real codec > driver. > It proposes to use the "spdif_receiver" and "spdif_transmitter" > drivers instead

Re: [PATCH] ASoC: fsl_sai: Fix channel swap issue on i.MX8MP

2023-12-18 Thread Fabio Estevam
On Mon, Dec 18, 2023 at 7:10 AM Shengjiu Wang wrote: > > When flag mclk_with_tere and mclk_direction_output enabled, > The SAI transmitter or receiver will be enabled in very early > stage, that if FSL_SAI_xMR is set by previous case, > for example previous case is one channel, current case is > t

[PATCH] ASoC: fsl_sai: Fix channel swap issue on i.MX8MP

2023-12-18 Thread Shengjiu Wang
When flag mclk_with_tere and mclk_direction_output enabled, The SAI transmitter or receiver will be enabled in very early stage, that if FSL_SAI_xMR is set by previous case, for example previous case is one channel, current case is two channels, then current case started with wrong xMR in the begin

Re: [PATCH v1 2/2] powerpc/debug: hook to user return notifier infrastructure

2023-12-18 Thread Aneesh Kumar K . V
Luming Yu writes: > Before we have powerpc to use the generic entry infrastructure, > the call to fire user return notifier is made temporarily in powerpc > entry code. > It is still not clear what will be registered as user return notifier. Can you summarize that here? > > Signed-off-by: Lumin