Re: [PATCH v2 22/26] selftests/resctrl: Pass write_schemata() resource instead of test name

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Ilpo,

On 11/20/2023 3:13 AM, Ilpo Järvinen wrote:
> write_schemata() takes the test name as an argument and determines the
> relevant resource based on the test name. Such mapping from name to
> resource does not really belong to resctrlfs.c that should provide
> only generic, test-independent functions.
> 
> Pass the resource stored in the test information structure to
> write_schemata() instead of the test name. The new API is also more
> flexible as it enables to use write_schemata() for more than one
> resource within a test.
> 
> While touching the sprintf(), move the unnecessary %c that is always
> '=' directly into the format string.
> 
> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@xxxxxxxxxxxxxxx>
> ---

...

>  			break;
> diff --git a/tools/testing/selftests/resctrl/resctrlfs.c b/tools/testing/selftests/resctrl/resctrlfs.c
> index b711326b2141..fda5ad812faa 100644
> --- a/tools/testing/selftests/resctrl/resctrlfs.c
> +++ b/tools/testing/selftests/resctrl/resctrlfs.c
> @@ -502,23 +502,17 @@ int write_bm_pid_to_resctrl(pid_t bm_pid, char *ctrlgrp, char *mongrp,
>   * @ctrlgrp:		Name of the con_mon grp
>   * @schemata:		Schemata that should be updated to
>   * @cpu_no:		CPU number that the benchmark PID is binded to
> - * @resctrl_val:	Resctrl feature (Eg: mbm, mba.. etc)
> + * @resource:		Resctrl resource (Eg: MB, L3, L2, etc.)
>   *
>   * Update schemata of a con_mon grp *only* if requested resctrl feature is
>   * allocation type
>   *

Note above there remains a usage of "feature" that has just been changed to "resource".

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

Reinette




[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux