Re: [PATCH v4 0/2] selftests/resctrl: Bug fix and optimization

2023-09-27 Thread Maciej Wieczór-Retman
Thanks for catching these, I'll remember to do that the next time. On 2023-09-27 at 15:16:18 -0700, Reinette Chatre wrote: >Hi Maciej, > >On 9/22/2023 1:09 AM, Maciej Wieczor-Retman wrote: >> The resctrlfs.c file defines functions that interact with the resctrl FS >> while resctrl_val.c file defin

Re: [PATCH v4 0/2] selftests/resctrl: Bug fix and optimization

2023-09-27 Thread Reinette Chatre
Hi Maciej, On 9/22/2023 1:09 AM, Maciej Wieczor-Retman wrote: > The resctrlfs.c file defines functions that interact with the resctrl FS > while resctrl_val.c file defines functions that perform measurements on > the cache. Run_benchmark() fits logically into the second file before > resctrl_val()

[PATCH v4 0/2] selftests/resctrl: Bug fix and optimization

2023-09-22 Thread Maciej Wieczor-Retman
Write_schemata() uses fprintf() to write a bitmask into a schemata file inside resctrl FS. It checks fprintf() return value but it doesn't check fclose() return value. Error codes from fprintf() such as write errors, are buffered and flushed back to the user only after fclose() is executed which me