Re: [PATCH v4] s390/pai: Handle multiple PMU stop callback invocations
Thomas Richter <[email protected]>
| Newsgroups | dev.linux.lists.sashiko-reviews,org.kernel.vger.linux-s390 |
|---|---|
| Organization | IBM |
| Message-ID | <[email protected]> |
On 8/19/26 08:11, [email protected] wrote: > Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider: > > Pre-existing issues: > - [Medium] `list_for_each_entry_safe` in `pai_have_samples()` is insufficient to prevent list corruption (dereferencing `LIST_POISON1`) when group throttling removes sibling events concurrently. perf_event_throttle_group() walks a different list anchored by perf_event::sibling_list. The list anchored by cpuhw::syswide is a complete different list using different nodes. Since events CRYPTO_ALL and NNPA_ALL are single sampling events and the only sampling event for each PAI PMU, it makes no sense to group the same event. Events of different PMUS can not be grouped anyway. > - [Medium] The patch fails to prohibit setting `event_limit`, leaving the unsupported `pai_stop()` invocation pathway open via `PERF_EVENT_IOC_REFRESH`. > -- > This needs to be addressed in a follow-on patch, the invocation of perf_event_refresh() can not be blocked right now. Maybe add a new PMU call back. -- Thomas Richter, Dept 3303, IBM s390 Linux Development, Boeblingen, Germany -- IBM Deutschland Research & Development GmbH Vorsitzender des Aufsichtsrats: Wolfgang Wendt Geschäftsführung: David Faller Sitz der Gesellschaft: Böblingen / Registergericht: Amtsgericht Stuttgart, HRB 243294