Merge tag 'sound-4.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai...
[firefly-linux-kernel-4.4.55.git] / drivers / bluetooth / hci_ll.c
index 69a90b1b5ff56131aa7a2e51b7d18aabba28b560..9ee24b075f7973e7578043c74e7421ddd535b7b5 100644 (file)
@@ -370,10 +370,10 @@ static inline int ll_check_data_len(struct hci_dev *hdev, struct ll_struct *ll,
 }
 
 /* Recv data */
-static int ll_recv(struct hci_uart *hu, void *data, int count)
+static int ll_recv(struct hci_uart *hu, const void *data, int count)
 {
        struct ll_struct *ll = hu->priv;
-       char *ptr;
+       const char *ptr;
        struct hci_event_hdr *eh;
        struct hci_acl_hdr   *ah;
        struct hci_sco_hdr   *sh;
@@ -505,8 +505,9 @@ static struct sk_buff *ll_dequeue(struct hci_uart *hu)
        return skb_dequeue(&ll->txq);
 }
 
-static struct hci_uart_proto llp = {
+static const struct hci_uart_proto llp = {
        .id             = HCI_UART_LL,
+       .name           = "LL",
        .open           = ll_open,
        .close          = ll_close,
        .recv           = ll_recv,
@@ -517,14 +518,7 @@ static struct hci_uart_proto llp = {
 
 int __init ll_init(void)
 {
-       int err = hci_uart_register_proto(&llp);
-
-       if (!err)
-               BT_INFO("HCILL protocol initialized");
-       else
-               BT_ERR("HCILL protocol registration failed");
-
-       return err;
+       return hci_uart_register_proto(&llp);
 }
 
 int __exit ll_deinit(void)