[flashrom] Using libflashrom from fwupd

Patrick Georgi pgeorgi at google.com
Thu Aug 17 08:24:50 CEST 2017


2017-08-17 1:51 GMT+02:00 Stefan Tauner <stefan.tauner at gmx.at>:
> I personally don't like to lie to users even if they beg for it. If
> flashrom does not exit it does useful stuff (of course there are some
> corner cases, e.g., if hardware is broken but these cases should a) be
> fixed by timeouts within flashrom, and b) be covered by timeouts in the
> callers and NOT by the user manually killing anything...). So IMHO a
> message to not worry + a spinner as long as your UI is working
> correctly (+ a timeout that really is the last resort) is way better
> and more honest than a made up progress indicator that can never tell
> the full story...
The problem with a spinner is that (unlike those in older CLI tools)
they run in the UI thread. There are systems where everything but the
UI system can be killed and dead, but the spinner is happily chugging
along.
People came to doubt spinners. Those things still spin, but is
anything still going on really?

So where's the lie in this?

step 1/3: Reading flash for comparison 25%
...
step 2/3: Writing to flash 75%
(this may either be non-monotonous in speed, in which case 75% means
"75% of flash matches input" or monotonous in speed after discounting
the blocks that needn't be written)
...
Error during write phase: checking flash state. Please wait and *KEEP
THE SYSTEM RUNNING*...

That's more complex than a simple progress bar, but today's progress
bars usually allow showing some inline text.


Patrick
-- 
Google Germany GmbH, ABC-Str. 19, 20354 Hamburg
Registergericht und -nummer: Hamburg, HRB 86891, Sitz der Gesellschaft: Hamburg
Geschäftsführer: Paul Manicle, Halimah DeLaine Prado



More information about the flashrom mailing list