mirror of
https://github.com/torvalds/linux.git
synced 2024-12-12 14:12:51 +00:00
e502801188
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 |
||
---|---|---|
.. | ||
coresight-catu.c | ||
coresight-catu.h | ||
coresight-cfg-afdo.c | ||
coresight-cfg-preload.c | ||
coresight-cfg-preload.h | ||
coresight-config.c | ||
coresight-config.h | ||
coresight-core.c | ||
coresight-cpu-debug.c | ||
coresight-cti-core.c | ||
coresight-cti-platform.c | ||
coresight-cti-sysfs.c | ||
coresight-cti.h | ||
coresight-dummy.c | ||
coresight-etb10.c | ||
coresight-etm3x-core.c | ||
coresight-etm3x-sysfs.c | ||
coresight-etm4x-cfg.c | ||
coresight-etm4x-cfg.h | ||
coresight-etm4x-core.c | ||
coresight-etm4x-sysfs.c | ||
coresight-etm4x.h | ||
coresight-etm-cp14.c | ||
coresight-etm-perf.c | ||
coresight-etm-perf.h | ||
coresight-etm.h | ||
coresight-funnel.c | ||
coresight-platform.c | ||
coresight-priv.h | ||
coresight-replicator.c | ||
coresight-self-hosted-trace.h | ||
coresight-stm.c | ||
coresight-syscfg-configfs.c | ||
coresight-syscfg-configfs.h | ||
coresight-syscfg.c | ||
coresight-syscfg.h | ||
coresight-sysfs.c | ||
coresight-tmc-core.c | ||
coresight-tmc-etf.c | ||
coresight-tmc-etr.c | ||
coresight-tmc.h | ||
coresight-tpda.c | ||
coresight-tpda.h | ||
coresight-tpdm.c | ||
coresight-tpdm.h | ||
coresight-tpiu.c | ||
coresight-trace-id.c | ||
coresight-trace-id.h | ||
coresight-trbe.c | ||
coresight-trbe.h | ||
Kconfig | ||
Makefile | ||
ultrasoc-smb.c | ||
ultrasoc-smb.h |