From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Andrea Arcangeli <andrea@suse.de>
Cc: oskar@osk.mine.nu, linux-kernel@vger.kernel.org
Subject: Re: directory notifications lost after fork?
Date: Tue, 12 Mar 2002 13:59:49 +1100 [thread overview]
Message-ID: <20020312135949.3be7d9ca.sfr@canb.auug.org.au> (raw)
In-Reply-To: <20020312022046.R10413@dualathlon.random>
In-Reply-To: <20020310210802.GA1695@oskar> <20020311112652.E10413@dualathlon.random> <20020312120452.3038c4bc.sfr@canb.auug.org.au> <20020312022046.R10413@dualathlon.random>
Hi Adrea,
On Tue, 12 Mar 2002 02:20:46 +0100 Andrea Arcangeli <andrea@suse.de> wrote:
>
> If somebody overrides the dnotify on the same file, he should become the
> new owner, that's not handled in the below patch.
My contention is that if some process (not in the same thread group as the
process that originally set up the directory notifier) tries to set up a
directory notifier on the same file descriptor (i.e. they are a child of
the original process), then they should get their own notifier. The
parent can remove their notifier if they want to.
Notice that multiple processes can have notifiers enabled for the same
directory (even with a different set of flags).
My patch makes directory notifiers per thread group instead of per process
tree (which they are now).
> Secondly I prefer to return -EPERM to userspace if somebody tries to
> drop a dnotify that it doesn't own, it gives more information back to
> userspace.
This would be equivalent to returning -EPERM if you tried to remove a
lock on a file when you didn't set it ...
--
Cheers, Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
next prev parent reply other threads:[~2002-03-12 3:01 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-03-10 21:08 Oskar Liljeblad
2002-03-11 7:41 ` Alex Riesen
2002-03-12 12:19 ` Jamie Lokier
2002-03-11 8:50 ` Oskar Liljeblad
2002-03-11 10:20 ` Alex Riesen
2002-03-11 10:26 ` Andrea Arcangeli
2002-03-12 1:04 ` Stephen Rothwell
2002-03-12 1:20 ` Andrea Arcangeli
2002-03-12 2:59 ` Stephen Rothwell [this message]
2002-03-12 4:01 ` Andrea Arcangeli
[not found] <20020311122701.A9718@riesen-pc.gr05.synopsys.com>
2002-03-11 19:34 ` Alex Riesen
2002-03-12 1:47 Malte Starostik
2002-03-12 12:55 ` Jamie Lokier
2002-03-12 16:37 ` Daniel Phillips
2002-03-12 17:21 ` Jamie Lokier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20020312135949.3be7d9ca.sfr@canb.auug.org.au \
--to=sfr@canb.auug.org.au \
--cc=andrea@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=oskar@osk.mine.nu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®