lkml.org 
[lkml]   [2009]   [Oct]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH RFC] BKL not necessary in cpuid_open
From
Date
On Wed, 2009-10-07 at 21:31 +0200, John Kacur wrote:
>
> On Wed, 7 Oct 2009, Sven-Thorsten Dietrich wrote:
>
> > On Wed, 2009-10-07 at 20:19 +0200, John Kacur wrote:
> > > I've been staring at the BKL lock in cpuid_open, and I can't see what it
> > > is protecting. However, I may have missed something - even something
> > > obvious, so comments are welcome.
> >
> > I have been using this patch to first see if the BKL is being used
> > simply as mutex, which would allow easier break-down.
> >
> > Sven
> >

> Cool! Seems like an excellent experiment. However this is a separate patch
> from the one initially proposed in this thread. I'm willing to risk just
> removing it in this case without any intermediary step. However, if anyone
> points out to me why I'm a knuckle head and missed something obvious - I'll
> listen. Otherwise, let's use your patch as a separate tactic to kill BKL.
>

Yes, I meant to send this out as RFC Monday, but got side-tracked with
catch-up work, so you prompted me to just reply to your patch.

I was also looking at the cycle_kernel_lock() call in
arch/x86/kernel/microcode_core.c, which is not obvious to me.

I converted that to cycle_kernel_mutex() using the patch I sent earlier,
but have not had time to actually boot and test.

In any case, I see bkl accesses all over various driver open() and
ioctl() calls.

I think that a number of these are safe to remove, as I still fail to
understand why its necessary to take BKL during any driver open()
routing.

So if its fine for the cpuid_open() call, then I would assume its ok for
others.

Sven




\
 
 \ /
  Last update: 2009-10-07 22:07    [W:0.044 / U:0.368 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site