Re: [PATCH net] af_unix: fix struct pid memory leak

2016-01-24 Thread Willy Tarreau
Hi Eric, On Sun, Jan 24, 2016 at 01:53:50PM -0800, Eric Dumazet wrote: > From: Eric Dumazet > > Dmitry reported a struct pid leak detected by a syzkaller program. > > Bug happens in unix_stream_recvmsg() when we break the loop when a > signal is pending, without properly

[PATCH net] af_unix: fix struct pid memory leak

2016-01-24 Thread Eric Dumazet
From: Eric Dumazet Dmitry reported a struct pid leak detected by a syzkaller program. Bug happens in unix_stream_recvmsg() when we break the loop when a signal is pending, without properly releasing scm. Fixes: b3ca9b02b007 ("net: fix multithreaded signal handling in unix

Re: struct pid memory leak

2016-01-24 Thread Eric Dumazet
On Sat, Jan 23, 2016 at 7:04 PM, Willy Tarreau wrote: > On Sat, Jan 23, 2016 at 06:50:11PM -0800, Eric Dumazet wrote: >> On Sat, Jan 23, 2016 at 6:38 PM, Willy Tarreau wrote: >> > On Sun, Jan 24, 2016 at 03:11:45AM +0100, Willy Tarreau wrote: >> >> It doesn't report

Re: struct pid memory leak

2016-01-23 Thread Willy Tarreau
Hi Eric, Dmitry, On Fri, Jan 22, 2016 at 08:50:01AM -0800, Eric Dumazet wrote: > CC netdev, as it looks some af_unix issue ... > > On Fri, 2016-01-22 at 16:08 +0100, Dmitry Vyukov wrote: > > Hello, > > > > The following program causes struct pid memory leak

Re: struct pid memory leak

2016-01-23 Thread Willy Tarreau
On Sat, Jan 23, 2016 at 07:14:33PM +0100, Dmitry Vyukov wrote: > I've attached my .config. > Also run this program in a parallel loop. I think it's leaking not > every time, probably some race is involved. Thank you. Just in order to confirm, am I supposed to see the messages you quoted in dmesg

Re: struct pid memory leak

2016-01-23 Thread Eric Dumazet
On Sat, Jan 23, 2016 at 10:46 AM, Dmitry Vyukov wrote: > On Sat, Jan 23, 2016 at 7:40 PM, Willy Tarreau wrote: >> On Sat, Jan 23, 2016 at 07:14:33PM +0100, Dmitry Vyukov wrote: >>> I've attached my .config. >>> Also run this program in a parallel loop. I think

Re: struct pid memory leak

2016-01-23 Thread Dmitry Vyukov
On Sat, Jan 23, 2016 at 7:40 PM, Willy Tarreau wrote: > On Sat, Jan 23, 2016 at 07:14:33PM +0100, Dmitry Vyukov wrote: >> I've attached my .config. >> Also run this program in a parallel loop. I think it's leaking not >> every time, probably some race is involved. > > Thank you. Just

Re: struct pid memory leak

2016-01-23 Thread Willy Tarreau
On Sat, Jan 23, 2016 at 07:46:45PM +0100, Dmitry Vyukov wrote: > On Sat, Jan 23, 2016 at 7:40 PM, Willy Tarreau wrote: > > On Sat, Jan 23, 2016 at 07:14:33PM +0100, Dmitry Vyukov wrote: > >> I've attached my .config. > >> Also run this program in a parallel loop. I think it's leaking

Re: struct pid memory leak

2016-01-23 Thread Willy Tarreau
On Sat, Jan 23, 2016 at 06:50:11PM -0800, Eric Dumazet wrote: > On Sat, Jan 23, 2016 at 6:38 PM, Willy Tarreau wrote: > > On Sun, Jan 24, 2016 at 03:11:45AM +0100, Willy Tarreau wrote: > >> It doesn't report this on 3.10. > > > > To be more precise, kmemleak reports the issue on 3.13

Re: struct pid memory leak

2016-01-23 Thread Willy Tarreau
On Sun, Jan 24, 2016 at 03:11:45AM +0100, Willy Tarreau wrote: > It doesn't report this on 3.10. To be more precise, kmemleak reports the issue on 3.13 and not on 3.12. I'm not sure if it's reliable enough to run a bisect though. Willy

Re: struct pid memory leak

2016-01-23 Thread Eric Dumazet
On Sat, Jan 23, 2016 at 6:38 PM, Willy Tarreau wrote: > On Sun, Jan 24, 2016 at 03:11:45AM +0100, Willy Tarreau wrote: >> It doesn't report this on 3.10. > > To be more precise, kmemleak reports the issue on 3.13 and not on 3.12. > I'm not sure if it's reliable enough to run a bisect

Re: struct pid memory leak

2016-01-22 Thread Eric Dumazet
CC netdev, as it looks some af_unix issue ... On Fri, 2016-01-22 at 16:08 +0100, Dmitry Vyukov wrote: > Hello, > > The following program causes struct pid memory leak: > > // autogenerated by syzkaller (http://github.com/google/syzkaller) > #include > #include &