[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b6fcc0a1003292331n4fd0ce03v6d75a1a20ce14f0f@mail.gmail.com>
Date: Tue, 30 Mar 2010 09:31:33 +0300
From: Alexey Dobriyan <adobriyan@...il.com>
To: Frederic Weisbecker <fweisbec@...il.com>
Cc: LKML <linux-kernel@...r.kernel.org>, Arnd Bergmann <arnd@...db.de>,
Thomas Gleixner <tglx@...utronix.de>,
Andrew Morton <akpm@...ux-foundation.org>,
John Kacur <jkacur@...hat.com>,
KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>,
Al Viro <viro@...iv.linux.org.uk>, Ingo Molnar <mingo@...e.hu>
Subject: Re: [PATCH 5/6] procfs: Push down the bkl from ioctl
On Tue, Mar 30, 2010 at 9:20 AM, Frederic Weisbecker <fweisbec@...il.com> wrote:
> --- a/net/sunrpc/cache.c
> +++ b/net/sunrpc/cache.c
> @@ -1331,12 +1331,22 @@ static unsigned int cache_poll_procfs(struct file *filp, poll_table *wait)
> return cache_poll(filp, wait, cd);
> }
>
> -static int cache_ioctl_procfs(struct inode *inode, struct file *filp,
> - unsigned int cmd, unsigned long arg)
> +static long cache_ioctl_procfs(struct file *filp,
> + unsigned int cmd, unsigned long arg)
> {
> - struct cache_detail *cd = PDE(inode)->data;
> + long ret;
> + struct cache_detail *cd;
> + struct inode *inode = filp->f_path.dentry->d_inode;
>
> - return cache_ioctl(inode, filp, cmd, arg, cd);
> + /* Pushed down from procfs ioctl handler */
> + lock_kernel();
> +
> + cd = PDE(inode)->data;
->data is not under BKL at all.
> + ret = cache_ioctl(inode, filp, cmd, arg, cd);
--
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