i had the idea to implement an expiration date for flashrom binaries (i.e. a time bomb). in the case distributions ship ancient binaries (in the future) this may save a bunch of hardware.
i noted two reactions back then when i proposed this idea on IRC in my todo.txt: <twice11> If I validated software to work on some system, I don't want it to suddenly break one year later. <agaran> twice11: but kind notify that version you use is %d days old (and repeated every multiple of time or 100days or so) could be nice
this proof of concept is probably not mergeable - especially the strptime() might be a problem (alternatives welcome), but i still think it is worth to think about something like this. comments?
Am 08.07.2011 13:35 schrieb Stefan Tauner:
i had the idea to implement an expiration date for flashrom binaries (i.e. a time bomb). in the case distributions ship ancient binaries (in the future) this may save a bunch of hardware.
i noted two reactions back then when i proposed this idea on IRC in my todo.txt: <twice11> If I validated software to work on some system, I don't want it to suddenly break one year later. <agaran> twice11: but kind notify that version you use is %d days old (and repeated every multiple of time or 100days or so) could be nice
this proof of concept is probably not mergeable - especially the strptime() might be a problem (alternatives welcome), but i still think it is worth to think about something like this. comments?
Good idea, but we will have to make sure this won't cause problems for users of live CDs and FreeDOS distributions etc...
Regards, Carl-Daniel
Op 8-7-2011 19:12, Carl-Daniel Hailfinger schreef:
Am 08.07.2011 13:35 schrieb Stefan Tauner: Good idea, but we will have to make sure this won't cause problems for users of live CDs and FreeDOS distributions etc...
What is the warning you want to give out, in which situations/conditions and is there any way/option/parameter to override it on the commandline in a automated/scripted way?
flashrom -r bios.bin -usingoutdatedversionatmyownrisk
So, does it make sense to warn if all operations already succeed? If reads even already fail, then upgrading definately is in order, hoping flashrom code has progressed far enough meanwhile to succesfully perform the read.
Am 08.07.2011 19:25 schrieb Bernd Blaauw:
Op 8-7-2011 19:12, Carl-Daniel Hailfinger schreef:
Am 08.07.2011 13:35 schrieb Stefan Tauner: Good idea, but we will have to make sure this won't cause problems for users of live CDs and FreeDOS distributions etc...
What is the warning you want to give out, in which situations/conditions and is there any way/option/parameter to override it on the commandline in a automated/scripted way?
Uh oh, not what I meant.
A warning message is OK under certain circumstances. Changing program behaviour is NOT OK (and will be vetoed).
That said, you're right that a warning message for a perfectly working flashrom does not really make sense. OTOH, warning the user before he/she trashes the system is a good idea, and that is best done during read, not only if everything already failed.
Regards, Carl-Daniel
On Fri, Jul 8, 2011 at 4:35 AM, Stefan Tauner < stefan.tauner@student.tuwien.ac.at> wrote:
i had the idea to implement an expiration date for flashrom binaries (i.e. a time bomb). in the case distributions ship ancient binaries (in the future) this may save a bunch of hardware.
i noted two reactions back then when i proposed this idea on IRC in my todo.txt: <twice11> If I validated software to work on some system, I don't want it to suddenly break one year later. <agaran> twice11: but kind notify that version you use is %d days old (and repeated every multiple of time or 100days or so) could be nice
Interesting idea, but I have to agree with twice11 here. I do not want a version of flashrom that works fine on the systems I'm supporting to suddenly start breaking scripts or throwing superfluous warnings to users and testers. This will definitely cause headaches for ODMs/OEMs and commercial Linux system vendors :-(
IMHO it would be more useful to try and get generic distros to a) not include a flashrom binary by default and b) when a user installs it manually, fetch and compile sources from SVN.
As for the patch itself, if this idea moves forward then it would be nice to isolate the code a bit more so it can be easily removed. Rather than placing it in print_version(), I recommend creating another function which would be called from cli_classic(). Something like: --- cli_classic.c (revision 1367) +++ cli_classic.c (working copy) @@ -146,6 +146,7 @@
print_version(); print_banner(); + print_expiration();
if (selfcheck()) exit(1);
where print_expiration() contains the code that prints warning.