diff options
author | Paul Gortmaker <paul.gortmaker@windriver.com> | 2018-07-23 16:29:56 -0400 |
---|---|---|
committer | Paul Gortmaker <paul.gortmaker@windriver.com> | 2018-07-23 16:29:56 -0400 |
commit | 328d7a1d6d5b6320459f2e932781c07bc081518b (patch) | |
tree | c4b54bc8ee4318daca757f9e57e96f25f494bb3a | |
parent | 0510d599d2f72de274938a573e4f69d2d3162d4a (diff) | |
download | longterm-queue-4.12-328d7a1d6d5b6320459f2e932781c07bc081518b.tar.gz |
bluetooth: ctxt refresh
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
-rw-r--r-- | queue/Bluetooth-hci_ldisc-Fix-another-race-when-closing-th.patch | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/queue/Bluetooth-hci_ldisc-Fix-another-race-when-closing-th.patch b/queue/Bluetooth-hci_ldisc-Fix-another-race-when-closing-th.patch index 5442407..8aed350 100644 --- a/queue/Bluetooth-hci_ldisc-Fix-another-race-when-closing-th.patch +++ b/queue/Bluetooth-hci_ldisc-Fix-another-race-when-closing-th.patch @@ -1,4 +1,4 @@ -From 0338b1b393ec7910898e8f7b25b3bf31a7282e16 Mon Sep 17 00:00:00 2001 +From 63d8a124a0e25ba0af4eafa7c75e2a7305a99d6e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ronald=20Tschal=C3=A4r?= <ronald@innovation.ch> Date: Wed, 25 Oct 2017 22:15:19 -0700 Subject: [PATCH] Bluetooth: hci_ldisc: Fix another race when closing the tty. @@ -29,22 +29,19 @@ detect that and not schedule further work. Signed-off-by: Ronald Tschalär <ronald@innovation.ch> Reviewed-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> diff --git a/drivers/bluetooth/hci_ldisc.c b/drivers/bluetooth/hci_ldisc.c -index 31def781a562..c823914b3a80 100644 +index 2edd30556956..e0590e456eb5 100644 --- a/drivers/bluetooth/hci_ldisc.c +++ b/drivers/bluetooth/hci_ldisc.c -@@ -523,13 +523,13 @@ static void hci_uart_tty_close(struct tty_struct *tty) +@@ -488,9 +488,9 @@ static void hci_uart_tty_close(struct tty_struct *tty) if (hdev) hci_uart_close(hdev); - cancel_work_sync(&hu->write_work); - - if (test_bit(HCI_UART_PROTO_READY, &hu->flags)) { - percpu_down_write(&hu->proto_lock); - clear_bit(HCI_UART_PROTO_READY, &hu->flags); - percpu_up_write(&hu->proto_lock); - + if (test_and_clear_bit(HCI_UART_PROTO_READY, &hu->flags)) { + cancel_work_sync(&hu->write_work); + if (hdev) { |