Re: [PATCH 04/16] perf, mmap: Factor out perf_get_fd()

2014-04-29 Thread Robert Richter
On 25.04.14 16:52:05, Peter Zijlstra wrote: > But no, I don't think that helps, its still true that the moment you get > a fd another thread can immediately close(). That would drop the last > ref and free it, meanwhile perf_event_open() is happily poking at it. > > Now I think you could cure this

Re: [PATCH 04/16] perf, mmap: Factor out perf_get_fd()

2014-04-25 Thread Peter Zijlstra
On Fri, Apr 25, 2014 at 04:43:01PM +0200, Peter Zijlstra wrote: > On Fri, Apr 25, 2014 at 03:54:13PM +0200, Robert Richter wrote: > > I guess its this patch from Al you referring to: > > > > ea635c6 Fix racy use of anon_inode_getfd() in perf_event.c > > > > I think we do not introduce it back du

Re: [PATCH 04/16] perf, mmap: Factor out perf_get_fd()

2014-04-25 Thread Peter Zijlstra
On Fri, Apr 25, 2014 at 03:54:13PM +0200, Robert Richter wrote: > I guess its this patch from Al you referring to: > > ea635c6 Fix racy use of anon_inode_getfd() in perf_event.c > > I think we do not introduce it back due to: > > a6fa941 perf_event: Switch to internal refcount, fix race with c

Re: [PATCH 04/16] perf, mmap: Factor out perf_get_fd()

2014-04-25 Thread Robert Richter
On 22.04.14 16:27:59, Peter Zijlstra wrote: > On Mon, Apr 07, 2014 at 05:04:26PM +0200, Jean Pihet wrote: > > From: Robert Richter > > > > This new function creates a new fd for an event. We need this later to > > get a fd from a persistent event. > > > > Signed-off-by: Robert Richter > > Signe

Re: [PATCH 04/16] perf, mmap: Factor out perf_get_fd()

2014-04-22 Thread Peter Zijlstra
On Mon, Apr 07, 2014 at 05:04:26PM +0200, Jean Pihet wrote: > From: Robert Richter > > This new function creates a new fd for an event. We need this later to > get a fd from a persistent event. > > Signed-off-by: Robert Richter > Signed-off-by: Robert Richter > Signed-off-by: Jean Pihet > ---