On Fri, Dec 06, 2013 at 01:25:04PM -0500, Greg Price wrote:
>
> Sure, that'd be reasonable. I didn't do that mainly because I wanted
> to preserve existing behavior wherever possible in these cleanups, to
> make them easy to read and review.
I'll make that change and apply this patch, thanks.
On Thu, Dec 05, 2013 at 08:13:47PM -0500, Theodore Ts'o wrote:
> On Wed, Nov 13, 2013 at 03:08:41AM -0500, Greg Price wrote:
> > + if (ibytes && cmpxchg(&r->entropy_count, orig, entropy_count) != orig)
> > + goto retry;
>
> I wonder if we would be better dropping the test for ibytes he
On Wed, Nov 13, 2013 at 03:08:41AM -0500, Greg Price wrote:
> + entropy_count = max_t(int, 0,
> + entropy_count - (ibytes << (ENTROPY_SHIFT + 3)));
> + if (ibytes && cmpxchg(&r->entropy_count, orig, entropy_count) != orig)
> + goto retry;
I wonder if w
With this we handle "reserved" in just one place. As a bonus the
code becomes less nested, and the "wakeup_write" flag variable
becomes unnecessary. The variable "flags" was already unused.
This code behaves identically to the previous version except in
two pathological cases that don't occur.
4 matches
Mail list logo