Messages in this thread | | | Date | Sat, 16 Jul 2016 00:03:52 +0900 | From | Wolfram Sang <> | Subject | Re: [RESEND PATCH 05/14] eeprom: at24: hide the read/write loop behind a macro |
| |
> >> +#define loop_until_timeout(tout, op_time) \ > >> + for (tout = jiffies + msecs_to_jiffies(write_timeout), \ > >> + op_time = jiffies; \ > >> + time_before(op_time, tout); \ > >> + usleep_range(1000, 1500), op_time = jiffies) > > > > There is one subtle change coming with this change: the do-while loop is > > guaranteed to run at least once while the for-loop doesn't. > > > > While it's technically possible, it will never happen as long as > write_timeout is set to some sensible value.
I know that. I prefer Linux to be rock-stable, though, even when slightly misconfigured (or under extreme load for that matter). An incremental patch would be enough, no need to resend.
[unhandled content-type:application/pgp-signature]
| |