linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: "linux-bluetooth@vger.kernel.org" <linux-bluetooth@vger.kernel.org>
Cc: Yunhan Wang <yunhanw@google.com>, Sukesh Srikakula <sukeshs@google.com>
Subject: Re: [PATCH v3 1/3] shared/att: Reset fd when disconnected
Date: Tue, 2 Oct 2018 14:29:24 +0300	[thread overview]
Message-ID: <CABBYNZJPcxQ+1FBU4Gc1qj_Gf7yDcEx84ft6BRksJrgbEE85+g@mail.gmail.com> (raw)
In-Reply-To: <20181002082442.20802-1-luiz.dentz@gmail.com>

On Tue, Oct 2, 2018 at 11:24 AM Luiz Augusto von Dentz
<luiz.dentz@gmail.com> wrote:
>
> From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
>
> Set att->fd to -1 when considered disconnected.
> ---
> v3: Pass btd_device instead of bt_att since the later may have been
> disconnected already.
>
>  src/shared/att.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/src/shared/att.c b/src/shared/att.c
> index 8bf3f4611..04577eddd 100644
> --- a/src/shared/att.c
> +++ b/src/shared/att.c
> @@ -570,6 +570,7 @@ static bool disconnect_cb(struct io *io, void *user_data)
>
>         io_destroy(att->io);
>         att->io = NULL;
> +       att->fd = -1;
>
>         /* Notify request callbacks */
>         queue_remove_all(att->req_queue, NULL, NULL, disc_att_send_op);
> --
> 2.17.1
>


-- 
Luiz Augusto von Dentz

  parent reply	other threads:[~2018-10-02 11:29 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-02  8:24 [PATCH v3 1/3] shared/att: Reset fd when disconnected Luiz Augusto von Dentz
2018-10-02  8:24 ` [PATCH v3 2/3] gatt: Fix attempting to create device on disconnection Luiz Augusto von Dentz
2018-10-02  8:24 ` [PATCH v3 3/3] gatt: Fix not cleaning up device state properly Luiz Augusto von Dentz
2018-10-02 11:29 ` Luiz Augusto von Dentz [this message]
2018-10-03  7:44   ` [PATCH v3 1/3] shared/att: Reset fd when disconnected Luiz Augusto von Dentz

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=CABBYNZJPcxQ+1FBU4Gc1qj_Gf7yDcEx84ft6BRksJrgbEE85+g@mail.gmail.com \
    --to=luiz.dentz@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=sukeshs@google.com \
    --cc=yunhanw@google.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;
as well as URLs for NNTP newsgroup(s).