* [PATCH AUTOSEL 6.1 03/19] coresight: tmc-etr: Disable warnings for allocation failures
[not found] <20231018141323.1334898-1-sashal@kernel.org>
@ 2023-10-18 14:13 ` Sasha Levin
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 12/19] irqchip/stm32-exti: add missing DT IRQ flag translation Sasha Levin
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 13/19] dmaengine: ste_dma40: Fix PM disable depth imbalance in d40_probe Sasha Levin
2 siblings, 0 replies; 3+ messages in thread
From: Sasha Levin @ 2023-10-18 14:13 UTC (permalink / raw)
To: linux-kernel, stable
Cc: Suzuki K Poulose, Mike Leach, James Clark, Anshuman Khandual,
Sasha Levin, alexander.shishkin, coresight, linux-arm-kernel
From: Suzuki K Poulose <suzuki.poulose@arm.com>
[ Upstream commit e5028011885a85032aa3c1b7e3e493bcdacb4a0a ]
Running the following command on Juno triggers the warning:
$ perf record -e cs_etm// -m ,128M ...
------------[ cut here ]------------
WARNING: CPU: 1 PID: 412 at mm/page_alloc.c:4453 __alloc_pages+0x334/0x1420
CPU: 1 PID: 412 Comm: perf Not tainted 6.5.0-rc3+ #181
Hardware name: ARM LTD ARM Juno Development Platform/ARM Juno Development Platform, BIOS EDK II Feb 1 2019
pstate: 20000005 (nzCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : __alloc_pages+0x334/0x1420
lr : dma_common_alloc_pages+0x108/0x138
sp : ffffffc087fb7440
x29: ffffffc087fb7440 x28: 0000000000000000 x27: ffffffc07e48fba0
x26: 0000000000000001 x25: 000000000000000f x24: ffffffc081f24880
x23: 0000000000000cc0 x22: ffffff88012b6f08 x21: 0000000008000000
x20: ffffff8801433000 x19: 0000000000000000 x18: 0000000000000000
x17: ffffffc080316e5c x16: ffffffc07e46406c x15: ffffffc0803af580
x14: ffffffc08036b460 x13: ffffffc080025cbc x12: ffffffb8108c3fc4
x11: 1ffffff8108c3fc3 x10: 1ffffff810ff6eac x9 : 00000000f204f204
x8 : 000000000000f204 x7 : 00000000f2f2f2f2 x6 : 00000000f3f3f3f3
x5 : 0000000000000001 x4 : 0000000000000000 x3 : 0000000000000000
x2 : 0000000000000cc0 x1 : 0000000000000000 x0 : ffffffc085333000
Call trace:
__alloc_pages+0x334/0x1420
dma_common_alloc_pages+0x108/0x138
__dma_alloc_pages+0xf4/0x108
dma_alloc_pages+0x18/0x30
tmc_etr_alloc_flat_buf+0xa0/0x190 [coresight_tmc]
tmc_alloc_etr_buf.constprop.0+0x124/0x298 [coresight_tmc]
alloc_etr_buf.constprop.0.isra.0+0x88/0xc8 [coresight_tmc]
tmc_alloc_etr_buffer+0x164/0x2f0 [coresight_tmc]
etm_setup_aux+0x32c/0x520 [coresight]
rb_alloc_aux+0x29c/0x3f8
perf_mmap+0x59c/0xce0
mmap_region+0x340/0x10e0
do_mmap+0x48c/0x580
vm_mmap_pgoff+0x160/0x248
ksys_mmap_pgoff+0x1e8/0x278
__arm64_sys_mmap+0x8c/0xb8
With the flat mode, we only attempt to allocate large memory if there is an IOMMU
connected to the ETR. If the allocation fails, we always have a fallback path
and return an error if nothing else worked. So, suppress the warning for flat
mode allocations.
Cc: Mike Leach <mike.leach@linaro.org>
Cc: James Clark <james.clark@arm.com>
Cc: Anshuman Khandual <anshuman.khandual@arm.com>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Reviewed-by: James Clark <james.clark@arm.com>
Link: https://lore.kernel.org/r/20230817161951.658534-1-suzuki.poulose@arm.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
drivers/hwtracing/coresight/coresight-tmc-etr.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/hwtracing/coresight/coresight-tmc-etr.c b/drivers/hwtracing/coresight/coresight-tmc-etr.c
index 1be0e5e0e80b2..c88a6afb29512 100644
--- a/drivers/hwtracing/coresight/coresight-tmc-etr.c
+++ b/drivers/hwtracing/coresight/coresight-tmc-etr.c
@@ -610,7 +610,8 @@ static int tmc_etr_alloc_flat_buf(struct tmc_drvdata *drvdata,
flat_buf->vaddr = dma_alloc_noncoherent(real_dev, etr_buf->size,
&flat_buf->daddr,
- DMA_FROM_DEVICE, GFP_KERNEL);
+ DMA_FROM_DEVICE,
+ GFP_KERNEL | __GFP_NOWARN);
if (!flat_buf->vaddr) {
kfree(flat_buf);
return -ENOMEM;
--
2.40.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH AUTOSEL 6.1 12/19] irqchip/stm32-exti: add missing DT IRQ flag translation
[not found] <20231018141323.1334898-1-sashal@kernel.org>
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 03/19] coresight: tmc-etr: Disable warnings for allocation failures Sasha Levin
@ 2023-10-18 14:13 ` Sasha Levin
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 13/19] dmaengine: ste_dma40: Fix PM disable depth imbalance in d40_probe Sasha Levin
2 siblings, 0 replies; 3+ messages in thread
From: Sasha Levin @ 2023-10-18 14:13 UTC (permalink / raw)
To: linux-kernel, stable
Cc: Ben Wolsieffer, Marc Zyngier, Sasha Levin, tglx, mcoquelin.stm32,
alexandre.torgue, linux-stm32, linux-arm-kernel
From: Ben Wolsieffer <ben.wolsieffer@hefring.com>
[ Upstream commit 8554cba1d6dbd3c74e0549e28ddbaccbb1d6b30a ]
The STM32F4/7 EXTI driver was missing the xlate callback, so IRQ trigger
flags specified in the device tree were being ignored. This was
preventing the RTC alarm interrupt from working, because it must be set
to trigger on the rising edge to function correctly.
Signed-off-by: Ben Wolsieffer <ben.wolsieffer@hefring.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20231003162003.1649967-1-ben.wolsieffer@hefring.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
drivers/irqchip/irq-stm32-exti.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/irqchip/irq-stm32-exti.c b/drivers/irqchip/irq-stm32-exti.c
index 8bbb2b114636c..dc6f67decb022 100644
--- a/drivers/irqchip/irq-stm32-exti.c
+++ b/drivers/irqchip/irq-stm32-exti.c
@@ -458,6 +458,7 @@ static const struct irq_domain_ops irq_exti_domain_ops = {
.map = irq_map_generic_chip,
.alloc = stm32_exti_alloc,
.free = stm32_exti_free,
+ .xlate = irq_domain_xlate_twocell,
};
static void stm32_irq_ack(struct irq_data *d)
--
2.40.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH AUTOSEL 6.1 13/19] dmaengine: ste_dma40: Fix PM disable depth imbalance in d40_probe
[not found] <20231018141323.1334898-1-sashal@kernel.org>
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 03/19] coresight: tmc-etr: Disable warnings for allocation failures Sasha Levin
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 12/19] irqchip/stm32-exti: add missing DT IRQ flag translation Sasha Levin
@ 2023-10-18 14:13 ` Sasha Levin
2 siblings, 0 replies; 3+ messages in thread
From: Sasha Levin @ 2023-10-18 14:13 UTC (permalink / raw)
To: linux-kernel, stable
Cc: Zhang Shurong, Linus Walleij, Vinod Koul, Sasha Levin,
linux-arm-kernel, dmaengine
From: Zhang Shurong <zhang_shurong@foxmail.com>
[ Upstream commit 0618c077a8c20e8c81e367988f70f7e32bb5a717 ]
The pm_runtime_enable will increase power disable depth. Thus
a pairing decrement is needed on the error handling path to
keep it balanced according to context.
We fix it by calling pm_runtime_disable when error returns.
Signed-off-by: Zhang Shurong <zhang_shurong@foxmail.com>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/r/tencent_DD2D371DB5925B4B602B1E1D0A5FA88F1208@qq.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
drivers/dma/ste_dma40.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/dma/ste_dma40.c b/drivers/dma/ste_dma40.c
index 3b09fdc507e04..594b016e76efc 100644
--- a/drivers/dma/ste_dma40.c
+++ b/drivers/dma/ste_dma40.c
@@ -3697,6 +3697,7 @@ static int __init d40_probe(struct platform_device *pdev)
regulator_disable(base->lcpa_regulator);
regulator_put(base->lcpa_regulator);
}
+ pm_runtime_disable(base->dev);
kfree(base->lcla_pool.alloc_map);
kfree(base->lookup_log_chans);
--
2.40.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-10-18 14:14 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20231018141323.1334898-1-sashal@kernel.org>
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 03/19] coresight: tmc-etr: Disable warnings for allocation failures Sasha Levin
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 12/19] irqchip/stm32-exti: add missing DT IRQ flag translation Sasha Levin
2023-10-18 14:13 ` [PATCH AUTOSEL 6.1 13/19] dmaengine: ste_dma40: Fix PM disable depth imbalance in d40_probe Sasha Levin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).