From: Zhao Li <enderaoelyther@gmail.com>
To: Michael McAllister <me@michaelmcallister.org>
Cc: Marcel Holtmann <marcel@holtmann.org>,
Luiz Augusto von Dentz <luiz.dentz@gmail.com>,
brgl@kernel.org, linux-bluetooth@vger.kernel.org,
linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
quic_bgodavar@quicinc.com, lumag@kernel.org, mka@chromium.org,
markus.probst@posteo.de, shuai.zhang@oss.qualcomm.com
Subject: Re: [PATCH v3 2/5] Bluetooth: hci_serdev: Track whether the serial port is open
Date: Wed, 18 Nov 2026 20:47:27 +0800 [thread overview]
Message-ID: <20261118124727.2330-1-enderaoelyther@gmail.com> (raw)
In-Reply-To: <179484638195.54009.8903355214693287470.wcn3950-poweroff-v3-2@michaelmcallister.org>
Hi Michael,
The hci_uart_close() hunk touches the quirk branch that clears
HCI_UART_PROTO_READY and closes the port. That branch has a separate
race: it clears the flag without hu->proto_lock and closes the port
without waiting for write_work, so a transmit that is still queued can
reach the tty while the port is being closed.
hci_uart_unregister_device() already clears the flag under
percpu_down_write() and calls cancel_work_sync() first.
Your patch does not change the ordering, so I think it is better kept
as is. I will send a separate fix for the close path. It changes one
context line of your hunk (the close call), so it will need a trivial
rebase on whichever series lands first. If you prefer, fold it into
your series and I will send it to you.
Zhao Li
next prev parent reply other threads:[~2026-11-18 12:48 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-16 16:26 [PATCH v3 0/5] Bluetooth: qca: Power off WCN3950 Michael McAllister
2026-11-16 16:26 ` [PATCH v3 1/5] Bluetooth: hci_serdev: Unregister HCI before freeing the TX buffer Michael McAllister
2026-11-16 19:44 ` Bluetooth: qca: Power off WCN3950 bluez.test.bot
2026-11-16 16:26 ` [PATCH v3 5/5] " Michael McAllister
2026-11-16 16:26 ` [PATCH v3 2/5] Bluetooth: hci_serdev: Track whether the serial port is open Michael McAllister
2026-11-18 12:47 ` Zhao Li [this message]
2026-11-16 16:26 ` [PATCH v3 3/5] Bluetooth: qca: Power off after unregistering the HCI device Michael McAllister
2026-11-16 16:26 ` [PATCH v3 4/5] Bluetooth: qca: Handle failed power-pulse writes Michael McAllister
2026-11-23 15:38 ` [PATCH v3 0/5] Bluetooth: qca: Power off WCN3950 Bartosz Golaszewski
2026-11-26 18:59 ` [PATCH v4 0/4] Bluetooth: qca: Power off WCN3950 safely Michael McAllister
2026-11-26 18:59 ` [PATCH v4 4/4] Bluetooth: qca: Power off WCN3950 Michael McAllister
2026-11-26 18:59 ` [PATCH v4 3/4] Bluetooth: qca: Handle failed power-pulse writes Michael McAllister
2026-11-26 18:59 ` [PATCH v4 2/4] Bluetooth: qca: Power off after unregistering the HCI device Michael McAllister
2026-11-26 18:59 ` [PATCH v4 1/4] Bluetooth: hci_serdev: Track whether the serial port is open Michael McAllister
2026-11-26 21:38 ` Bluetooth: qca: Power off WCN3950 safely bluez.test.bot
2026-12-02 2:55 ` bluez.test.bot
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=20261118124727.2330-1-enderaoelyther@gmail.com \
--to=enderaoelyther@gmail.com \
--cc=brgl@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-bluetooth@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luiz.dentz@gmail.com \
--cc=lumag@kernel.org \
--cc=marcel@holtmann.org \
--cc=markus.probst@posteo.de \
--cc=me@michaelmcallister.org \
--cc=mka@chromium.org \
--cc=quic_bgodavar@quicinc.com \
--cc=shuai.zhang@oss.qualcomm.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.