]> err.no Git - linux-2.6/blobdiff - drivers/bluetooth/hci_ldisc.c
Add documentation for extended crashkernel syntax
[linux-2.6] / drivers / bluetooth / hci_ldisc.c
index 75c15085f81f9a68735ad384705981d1a6407386..6055b9c0ac0f0b2f96380bebbb227b1fcaad055f 100644 (file)
@@ -307,7 +307,9 @@ static void hci_uart_tty_close(struct tty_struct *tty)
 
        if (hu) {
                struct hci_dev *hdev = hu->hdev;
-               hci_uart_close(hdev);
+
+               if (hdev)
+                       hci_uart_close(hdev);
 
                if (test_and_clear_bit(HCI_UART_PROTO_SET, &hu->flags)) {
                        hu->proto->close(hu);
@@ -473,6 +475,7 @@ static int hci_uart_tty_ioctl(struct tty_struct *tty, struct file * file,
                        tty->low_latency = 1;
                } else
                        return -EBUSY;
+               break;
 
        case HCIUARTGETPROTO:
                if (test_bit(HCI_UART_PROTO_SET, &hu->flags))