Bluetooth: hci_uart: Use const data pointer for received data
The TTY layer provides its data pointers as const, but the HCI UART callbacks expect them as general data pointers. This is of course wrong and instead of casting them, just fix the individual drivers to actually take a const data pointer. Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This commit is contained in:
@@ -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;
|
||||
|
Reference in New Issue
Block a user