iucode_tool: select scan-system strategy change at runtime
Instead of selecting the scan-system strategy at compile time, enhance the long-version of the --scan-system option to take an optional argument, and select the strategy. Available strategies are: 0 (auto), 1 (fast), and 2 (exact). Fast uses just the cpuid instruction and activates all steppings. Exact will query all processors using the kernel cpuid driver. Auto (the default) is currently the same as fast. The short option -S is equivalent to --scan-system=auto. This way, we don't break backwards command line behavior, and something like "iucode_tool -Sl" will still work. In --scan-system=exact mode, when a /dev/cpu/#/cpuid scan fails, it will use the result from the cpuid instruction and also add every other stepping for any signatures found before the failure. This goes well beyond the required, since it actually means iucode_tool supports multi-signature systems in --scan-system=exact mode...
Showing with 103 additions and 17 deletions