Commit 24d48e0
committed
WORKAROUND: Bluetooth: support Bluetooth over both USB and UART
This is a temporary workaround.
On Hamoa boards, a single M.2 slot may host either a UART-based
Bluetooth card or a USB-based Bluetooth card. As a result, the UART
controller node is always present in the device tree, while the USB
Bluetooth path is hot-pluggable.
When Bluetooth is actually used over USB, the hci_qca UART driver still
probes due to the DT node being present. During probe and power
sequencing, it drives BT_EN low (either directly or via the WCN power
sequencer), which can cut power to the shared Bluetooth device and cause
the USB Bluetooth interface to disconnect.
Model BT_EN as an always-on fixed regulator and ensure that the UART
path does not claim power control when BT_EN is not described for that
consumer:
- Describe BT_EN as a fixed regulator (GPIO 116) that is boot-on and
always-on, so it cannot be inadvertently deasserted by the UART probe.
- Remove bt-enable-gpios from the WCN7850 power sequencer node and drop
its BT pinctrl entry.
- Wire the Bluetooth DT supplies to the always-on 3.3V rail so the UART
driver can acquire its regulators without depending on the WCN PMU
regulators in this dual-path configuration.
- Treat WCN7850 like WCN6750/WCN6855 in hci_qca: if no bt_en GPIO is
provided for the UART device, disable power control for that instance.
- In pwrseq-qcom-wcn, do not match a "bluetooth" consumer if the
sequencer has no bt-enable GPIO configured. This prevents the
sequencer from binding to a Bluetooth consumer node in the
"BT_EN tied high / absent from DT" case and allows the consumer to
fall back accordingly.
With these changes, probing the UART path no longer deasserts BT_EN when
Bluetooth is operating over USB, avoiding unexpected USB disconnects.
Signed-off-by: Shuai Zhang <shuai.zhang@oss.qualcomm.com>1 parent 18e0821 commit 24d48e0
File tree
3 files changed
+45
-14
lines changed- arch/arm64/boot/dts/qcom
- drivers
- bluetooth
- power/sequencing
3 files changed
+45
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
470 | 470 | | |
471 | 471 | | |
472 | 472 | | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
473 | 490 | | |
474 | 491 | | |
475 | 492 | | |
| |||
1330 | 1347 | | |
1331 | 1348 | | |
1332 | 1349 | | |
1333 | | - | |
1334 | | - | |
1335 | | - | |
1336 | | - | |
1337 | | - | |
1338 | | - | |
| 1350 | + | |
| 1351 | + | |
| 1352 | + | |
| 1353 | + | |
| 1354 | + | |
1339 | 1355 | | |
1340 | 1356 | | |
1341 | 1357 | | |
| |||
1376 | 1392 | | |
1377 | 1393 | | |
1378 | 1394 | | |
1379 | | - | |
1380 | | - | |
1381 | | - | |
1382 | | - | |
1383 | | - | |
1384 | | - | |
1385 | | - | |
| 1395 | + | |
| 1396 | + | |
| 1397 | + | |
| 1398 | + | |
| 1399 | + | |
| 1400 | + | |
| 1401 | + | |
1386 | 1402 | | |
1387 | 1403 | | |
1388 | 1404 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2467 | 2467 | | |
2468 | 2468 | | |
2469 | 2469 | | |
2470 | | - | |
| 2470 | + | |
| 2471 | + | |
2471 | 2472 | | |
2472 | 2473 | | |
2473 | 2474 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
357 | 357 | | |
358 | 358 | | |
359 | 359 | | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
360 | 374 | | |
361 | 375 | | |
362 | 376 | | |
| |||
0 commit comments