Re: [patch] kjournald locking fix
Robert Love (firstname.lastname@example.org)
04 Apr 2002 13:40:22 -0500
On Thu, 2002-04-04 at 17:02, Ishan O. Jayawardena wrote:
> kjournald seems to be missing an unlock_kernel() for a matching
> lock_kernel(). A posting by Dennis Vadura to l-k mentions (among other
> things) a kernel message that says kjournald exited with preempt_count ==
> 1. The attached patch (text/plain) adds the necessary
> unlock_kernel(). [But I haven't been able to reproduce the hang that
> Dennis experiences...]
> Tested only on UP. Patch is for 2.4.19-pre5 + prempt-kernel, _no_
> lock-break. I hope the positioning of unlock_kernel() is correct... please
> correct me if I'm wrong.
The unlock_kernel is correct, thanks.
In this case, the messae about the nonzero preempt_count is not a
problem - kjournald just exits without dropping the BKL because it knows
schedule will do it for you. It is cleaner, however, to explicitly
relinquish the lock, and it removes the preempt_count debug whining.
So the patch is good - thanks,
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to email@example.com
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/