Re: [PATCH 2/3, RFC] watchdog dev BKL pushdown
From: Wim Van Sebroeck
Date: Tue May 20 2008 - 11:47:28 EST
Hi Arnd,
> > Actually I'd prefer to fix this for real. This single open stuff aswell
> > as same set of ioctls are duplicated all over the watchdog drivers. We'd
> > be much better off introducing a simple watchdog layer that handles this
> > plus proper locking and convert drivers over to it gradually.
>
> I fully agree, I thought the same thing when I did the patches. I remember
> that Wim had a git tree doing this, which is still active at
> http://git.kernel.org/?p=linux/kernel/git/wim/linux-2.6-watchdog-experimental.git;a=commitdiff;h=732c54027e6c866f98857c4a6d1c6c466459dcd5
>
> Unfortunately, it hasn't seen much activitity over the last two years, and
> the number of watchdog drivers seems to have exploded: I count 67 of them,
> including some outside of drivers/watchdog.
>
> Wim, was there anything preventing you from integrating the generic
> watchdog layer back then?
check the linux-2.6-watchdog-mm tree. You'll see the patches sitting there
as the uniform watchdog driver. They are thus also in the -mm tree.
I'll need to change it also to an unlocked_ioctl (and add documentation!)
but I'll attach the core code below (This does not seem to be the latest code,
because I know there was a request to change the alloc_watchdogdev code so that
it could also allocate a private data-area/space).
But it gives you an idea where I was going to. Second step would then be to add
a sysfs interface so that we can start handling mutiple devices.
Greetings,
Wim.