Re: [PATCH v5 13/16] selftests/resctrl: Convert ctrlgrp & mongrp to pointers
From: Ilpo Järvinen
Date: Mon Jun 03 2024 - 02:43:40 EST
On Fri, 31 May 2024, Reinette Chatre wrote:
> On 5/31/24 6:11 AM, Ilpo Järvinen wrote:
> > The struct resctrl_val_param has control and monitor groups as char
> > arrays but they are not supposed to be mutated within resctrl_val().
> >
> > Convert the ctrlgrp and mongrp char array within resctrl_val_param to
> > plain const char pointers and adjust the strlen() based checks to
> > check NULL instead.
> >
> > Convert !grp_name check in create_grp() into internal sanity check by
> > returning error if the caller asked to create a group but doesn't
> > provide a name for the group. The existing code already abides this by
> > only calling create_grp() if mongrp is non-NULL so the error should
> > never be returned with the current selftests (ctrlgrp is never NULL).
>
> This paragraph is no longer relevant and can be dropped.
Thanks for catching this. I'm absolutely sure I had this open one in
my editor and removed it but it seems I did not, no idea what happened.
--
i.