Re: [PATCH v2 16/26] selftests/resctrl: Open perf fd before start & add error handling

From: Reinette Chatre
Date: Tue Nov 28 2023 - 17:16:32 EST


Hi Ilpo,

On 11/20/2023 3:13 AM, Ilpo Järvinen wrote:
> Perf fd (pe_fd) is opened, reset, and enabled during every test the CAT
> selftest runs. Also, ioctl(pe_fd, ...) calls are not error checked even
> if ioctl() could return an error.
>
> Open perf fd only once before the tests and only reset and enable the
> counter within the test loop. Add error checking to pe_fd ioctl()
> calls.
>
> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@xxxxxxxxxxxxxxx>
> ---

Reviewed-by: Reinette Chatre <reinette.chatre@xxxxxxxxx>

Reinette