lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 26 May 2008 13:39:22 -0300
From:	Mauro Carvalho Chehab <mchehab@...radead.org>
To:	Hans Verkuil <hverkuil@...all.nl>
Cc:	video4linux-list@...hat.com, linux-kernel@...r.kernel.org,
	Alan Cox <alan@...rguk.ukuu.org.uk>
Subject: Re: [PATCH] video4linux: Push down the BKL

On Fri, 23 May 2008 08:16:05 +0200
Hans Verkuil <hverkuil@...all.nl> wrote:

> On Friday 23 May 2008 04:08:04 Andy Walls wrote:
> > On Thu, 2008-05-22 at 22:37 +0100, Alan Cox wrote:
> > > For most drivers the generic ioctl handler does the work and we
> > > update it and it becomes the unlocked_ioctl method. Older drivers
> > > use the usercopy method so we make it do the work. Finally there
> > > are a few special cases.
> > >
> > > Signed-off-by: Alan Cox <alan@...hat.com>
> >
> > I'd like to start planning out the changes to eliminate the BKL from
> > cx18.
> >
> > Could someone give me a brief education as to what elements of
> > cx18/ivtv_v4l2_do_ioctl() would be forcing the use of the BKL for
> > these drivers' ioctls?   I'm assuming it's not the
> > mutex_un/lock(&....->serialize_lock) and that the answer's not in the
> > diff.
> 
> To the best of my knowledge there is no need for a BKL in ivtv or cx18. 
> It was just laziness on my part that I hadn't switched to 
> unlocked_ioctl yet.

I suspect that this is true with almost all drivers. Yet, we may need to enable
BKL or add other locks on a few places. For example, the old tuner i2c probing
method relies on a global and unique static var to identify radio and tv
tuners. I can foresee a race condition there, if you have two boards probing
tuners at the same time.

Of course, we need to do several tests, since probably there are some issues
that we cannot foresee.

Cheers,
Mauro
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ