RE: [RFC 08/10] platform/x86/intel/ifs: Add IFS sysfs interface

Luck, Tony
2022-03-04T16:51:21Z

> Dynamic creation of sysfs attributes sometime after the driver loads is
> not friendly for something that likely only needs the module loaded for
> a test run and then unloaded again. I think this effort would be better
> served by building a sysfs topology registered underneath an ifs
> platform device.

Ah. Another gap in the Documentation/x86/ifs.rst that I need to fix.

Expected use case isn't just "run this test once to check your system
for signs of silicon aging". It is load this and run the tests at regular
intervals to catch developing problems as soon as possible.

I'll see if I can get the architects of the feature to give some input
on what they expect to be a "regular interval" to be included in
the documentation.

Note that even if a user only plans to run infrequently, there isn't
much benefit from unloading the module. The kernel memory used
by this driver is dwarfed by the memory reserved by BIOS to hold
the validated copies of the scan tests. Reloading the tests from the
file takes longer than a single run of the tests (though perhaps
that can be avoided if reading the MSRs can confirm that the
tests already loaded in reserved memory).

-Tony