[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <52cc1865-b86c-2b07-38b1-04d053e52f36@colorfullife.com>
Date: Sun, 21 May 2017 16:09:41 +0200
From: Manfred Spraul <manfred@...orfullife.com>
To: valdis.kletnieks@...edu, Kees Cook <keescook@...omium.org>
Cc: linux-kernel@...r.kernel.org,
Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: linux-next 20170519 - semaphores broken
Hi valdis,
On 05/20/2017 10:18 PM, valdis.kletnieks@...edu wrote:
> Seeing problems with programs that use semaphores. The one
> that I'm getting bit by is jackd. strace says:
>
> getuid() = 967
> semget(0x282929, 0, 000) = 229376
> semop(229376, [{0, -1, SEM_UNDO}], 1) = -1 EIDRM (Identifier removed)
> write(2, "JACK semaphore error: semop (Ide"..., 49JACK semaphore error: semop (Identifier removed)
> ) = 49
>
> Bisects down to this commit, and reverting it from 20170519 makes things work
> again. No idea why this causes indigestion, there's probably something subtly
> wrong here....
Duh, thanks.
There was another report that got a 99% improvement, which I did not
understand.
Probable root cause:
> sma = container_of(ipc_rcu_alloc(size), struct sem_array,
> sem_perm);
> if (!sma)
> return -ENOMEM;
>
> memset(sma, 0, size);
>
sma->sem_perm.refcount was initialized by ipc_rcu_alloc.
And due to the SEM_UNDO, the refcount is relevant.
Thanks for bisecting it, I'll update the patch.
--
Manfred
Powered by blists - more mailing lists