Linux bluetooth development
 help / color / mirror / Atom feed
From: Gustavo Padovan <padovan@profusion.mobi>
To: David Herrmann <dh.herrmann@googlemail.com>
Cc: linux-bluetooth@vger.kernel.org, marcel@holtmann.org
Subject: Re: [PATCH v2] Bluetooth: bcm203x: Fix race condition on disconnect
Date: Mon, 31 Oct 2011 17:54:39 -0200	[thread overview]
Message-ID: <20111031195439.GJ10164@joana> (raw)
In-Reply-To: <1319620393-11127-1-git-send-email-dh.herrmann@googlemail.com>

Hi David,

* David Herrmann <dh.herrmann@googlemail.com> [2011-10-26 11:13:13 +0200]:

> When disconnecting a bcm203x device we kill and destroy the usb-urb, however,
> there might still be a pending work-structure which resubmits the now invalid
> urb. To avoid this race condition, we simply set a shutdown-flag and
> synchronously kill the worker first.
> 
> This also adds a comment to all schedule_work()s, as it is really not clear
> that they are used as replacement for short timers (which can be seen in the git
> history).
> 
> Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
> ---
> V2: Remove memory barriers
> 
>  drivers/bluetooth/bcm203x.c |   10 ++++++++++
>  1 files changed, 10 insertions(+), 0 deletions(-)

Applied, thanks.

	Gustavo

      parent reply	other threads:[~2011-10-31 19:54 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-25 19:13 [PATCH 1/2] Bluetooth: bcm203x: Fix race condition on disconnect David Herrmann
2011-10-25 19:13 ` [PATCH 2/2] Bluetooth: bcm203x: Use GFP_KERNEL in workqueue David Herrmann
2011-10-26  8:54   ` Marcel Holtmann
2011-10-31 19:55   ` Gustavo Padovan
2011-10-26  8:57 ` [PATCH 1/2] Bluetooth: bcm203x: Fix race condition on disconnect Marcel Holtmann
2011-10-26  9:03   ` David Herrmann
2011-10-26  9:04     ` Marcel Holtmann
2011-10-26  9:13       ` [PATCH v2] " David Herrmann
2011-10-26  9:16         ` Marcel Holtmann
2011-10-31 19:54         ` Gustavo Padovan [this message]

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=20111031195439.GJ10164@joana \
    --to=padovan@profusion.mobi \
    --cc=dh.herrmann@googlemail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=marcel@holtmann.org \
    /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