mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Manfred Spraul <manfred@colorfullife.com>
Cc: LKML <linux-kernel@vger.kernel.org>, Yuriy Yevtukhov <yuriy@ucoz.com>
Subject: Re: [PATCH] [ipc/sem.c] fix race with concurrent semtimedop() timeouts and IPC_RMID
Date: Wed, 20 Jul 2011 23:58:36 -0700	[thread overview]
Message-ID: <20110720235836.c40ec351.akpm@linux-foundation.org> (raw)
In-Reply-To: <1311230573-6244-1-git-send-email-manfred@colorfullife.com>

On Thu, 21 Jul 2011 08:42:53 +0200 Manfred Spraul <manfred@colorfullife.com> wrote:

> If a semaphore array is removed and in parallel a sleeping task is woken up
> (signal or timeout, does not matter), then the woken up task does not wait
> until wake_up_sem_queue_do() is completed. This will cause crashes, because
> wake_up_sem_queue_do() will read from a stale pointer.
> 
> The fix is simple: Regardless of anything, always call get_queue_result().
> This function waits until wake_up_sem_queue_do() has finished it's task.
> 
> Andrew, could you please take care of merging the patch?

yup, thanks for this.  It's good to hear from you, and that you've
still got what it takes :)

Do you know how long this bug has been around for?  Somewhere between
2.6.32 and 2.6.36, but that a large interval!

  reply	other threads:[~2011-07-21  6:58 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-21  6:42 Manfred Spraul
2011-07-21  6:58 ` Andrew Morton [this message]
2011-07-21  8:12   ` Eric Dumazet

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=20110720235836.c40ec351.akpm@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=manfred@colorfullife.com \
    --cc=yuriy@ucoz.com \
    /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®