public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
From: Johan Hedberg <johan.hedberg@nokia.com>
To: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
Cc: "Daniel Örstadius" <daniel.orstadius@gmail.com>,
	linux-bluetooth@vger.kernel.org
Subject: Re: [PATCH] AVDTP start/stop handling during disconnection
Date: Tue, 1 Sep 2009 10:02:04 +0300	[thread overview]
Message-ID: <20090901070204.GA27211@jh-x301> (raw)
In-Reply-To: <2d5a2c100908271008v67bb1b86xa5ad5ef6e95ba49a@mail.gmail.com>

Hi Daniel & Luiz,

On Thu, Aug 27, 2009, Luiz Augusto von Dentz wrote:
> On Thu, Aug 27, 2009 at 12:24 PM, Daniel
> Örstadius<daniel.orstadius@gmail.com> wrote:
> > A suggested patch for rejecting AVDTP CLOSE and START requests when a
> > CLOSE request has been initiated. The check is done by testing the
> > close_int flag in the avdtp_stream struct. The flag is reset when
> > receiving a timeout or rejection from the remote.
> >
> > Changes in unix.c were made to call avdtp_unref() in case an AVDTP
> > session was marked by avdtp_ref(), but no SEP was found. This could
> > happen if START is called on a session being disconnected.
> >
> > We found that these changes help to improve behavior both in case the
> > audio streaming application tries to start the stream during a
> > disconnection procedure, and if avdtp_close() is called twice.
> 
> It probably works better if you place it on avdtp struct so it works
> even if we don't have a stream configured,

But a stream can't be in OPEN state if it hasn't been configured (i.e. we
have a stream struct for it). So this part of the patch looks good to me.

> I also prefer closing instead of close_int.

That would have a different meaning though. To me closing means we're
closing but doesn't say anything about who initiated the close. close_int
otoh tells us that we initiated the close. Also, since this variable
already exists and is needed I think reusing it is fine.

So Daniel, could you split out the first part of your patch and resend it?
Thanks.

Johan

  reply	other threads:[~2009-09-01  7:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-27 15:24 [PATCH] AVDTP start/stop handling during disconnection Daniel Örstadius
2009-08-27 17:08 ` Luiz Augusto von Dentz
2009-09-01  7:02   ` Johan Hedberg [this message]
2009-09-01 11:09     ` Daniel Örstadius
2009-09-02 10:06       ` Johan Hedberg

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=20090901070204.GA27211@jh-x301 \
    --to=johan.hedberg@nokia.com \
    --cc=daniel.orstadius@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=luiz.dentz@gmail.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