[PATCH] perf/arm-cmn: Stop claiming entire iomem region

Ben Horgan ben.horgan at arm.com
Tue Feb 24 02:07:56 PST 2026


Hi Robin,

On 2/19/26 17:27, Robin Murphy wrote:
> So far, the PMU has been the only thing of interest in the vast mass
> of CMN registers, so we've gotten away with simply claiming the entire
> iomem region. However, now that we can support other features like MPAM
> controllers for the system caches, the PMU driver needs to stop being
> selfish and learn to share. Similarly to arm-ni, requesting just the
> DTC node(s) should suffice for staking our exclusive claim to the PMU>
features, as requesting hundreds of tiny regions for all the individual
> pmu_event_sel registers is definitely not worth the considerable bother.
> 
> As a consequence, we can also streamline the annoying CMN-600 special
> cases even more. The ACPI binding has in fact always specified a strict
> order for all resources, so we can reasonably drop the ancient pretence
> of swapping base and cfg, which IIRC was more just a moment of doubt on
> my part than anything else.
> 
> Cc: James Morse <james.morse at arm.com>
> Signed-off-by: Robin Murphy <robin.murphy at arm.com>

Without this patch applied and with mpam enabled cmn fails to probe:
dmesg | grep cmn
[   17.409588] arm-cmn ARMHC700:00: error -EBUSY: can't request region
for resource [mem 0x140000000-0x17fffffff]
[   17.409601] arm-cmn ARMHC700:00: probe with driver arm-cmn failed
with error -16

With the patch I don't see any cmn errors and it probes.

$ tree -L 1 /sys/devices/platform/ARMHC700\:00/
/sys/devices/platform/ARMHC700:00/
├── arm_cmn_0
├── driver -> ../../../bus/platform/drivers/arm-cmn
├── driver_override
├── firmware_node -> ../../LNXSYSTM:00/LNXSYBUS:00/ARMHC700:00
├── modalias
├── power
├── subsystem -> ../../../bus/platform
└── uevent

Tested-by: Ben Horgan <ben.horgan at arm.com>

Thanks,

Ben




More information about the linux-arm-kernel mailing list