[PATCH 3/5] perf/arm-cmn: Refactor event filter data
Leo Yan
leo.yan at arm.com
Sun Jul 5 08:44:38 PDT 2026
On Tue, Jun 30, 2026 at 04:19:18PM +0100, Robin Murphy wrote:
[...]
> +struct arm_cmn_filter_attr {
> + enum cmn_filter_select sel;
> + u8 val;
> +};
> -#define _CMN_EVENT_ATTR(_model, _name, _type, _eventid, _filter, _fsel)\
> +#define _CMN_EVENT_ATTR(_model, _name, _type, _eventid, _filter, ...) \
> (&((struct arm_cmn_event_attr[]) {{ \
> .attr = __ATTR(_name, 0444, arm_cmn_event_show, NULL), \
> .model = _model, \
> .type = _type, \
> .eventid = _eventid, \
> - .filter = _filter, \
> - .fsel = _fsel, \
> + .filter = {{_filter}}, \
This patch might break as the "val" field is never initialized. Should
it use two parameters "_fa, _fb" instead?
#define _CMN_EVENT_ATTR(_model, _name, _type, _eventid, _fa, _fb, ...) \
(&((struct arm_cmn_event_attr[]) {{ \
... \
.filter = {{_fa, _fb}}, \
Although the issue is fixed by a later patch, I think it is good to
correct this patch for bisection.
Thanks,
Leo
More information about the linux-arm-kernel
mailing list