[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1415815173.25389.2@mail.thefacebook.com>
Date: Wed, 12 Nov 2014 12:59:33 -0500
From: Chris Mason <clm@...com>
To: Martin Kepplinger <martink@...teo.de>
CC: <linux-btrfs@...r.kernel.org>, <gregkh@...uxfoundation.org>,
<linux-kernel@...r.kernel.org>,
Martin Kepplinger <martink@...teo.de>
Subject: Re: [PATCH] btrfs: Don't check for file->private_data on open(). It
is set by the core.
On Wed, Nov 12, 2014 at 11:38 AM, Martin Kepplinger <martink@...teo.de>
wrote:
> The miscdevice core now sets file->private_data to the struct
> miscdevice
> so don't fail when this is not NULL.
>
> Signed-off-by: Martin Kepplinger <martink@...teo.de>
> ---
> This is a question: what does this check provide and does overwriting
> file->private_data make any difference?
>
> Is miscdevice's open() by the user not allowed here, if
> file->private_data
> is set?
>
> thanks!!
Btrfs uses this in the transaction start ioctl to record the
transaction handle being started. Ceph is the main user of the ioctl,
and we could setup a hash table if needed. But which call path in
miscdevice is doing this?
With your patch in place, btrfs would end up overwriting the miscdevice
private_data field, which would probably cause problems.
-chris
--
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