From: Fabian Frederick Date: Sat, 25 Oct 2014 08:48:58 +0000 (+0200) Subject: Bluetooth: fix shadow warning in hci_disconnect() X-Git-Tag: v5.15~16721^2~28^2~129^2~101 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4f639edef73c15ddb1534e39f4bd6234ee04e4f8;p=platform%2Fkernel%2Flinux-starfive.git Bluetooth: fix shadow warning in hci_disconnect() use clkoff_cp for hci_cp_read_clock_offset instead of cp (already defined above). Suggested-by: Marcel Holtmann Signed-off-by: Fabian Frederick Signed-off-by: Marcel Holtmann --- diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c index 11aac06..6a3225b 100644 --- a/net/bluetooth/hci_conn.c +++ b/net/bluetooth/hci_conn.c @@ -141,10 +141,11 @@ int hci_disconnect(struct hci_conn *conn, __u8 reason) */ if (conn->type == ACL_LINK && conn->role == HCI_ROLE_MASTER) { struct hci_dev *hdev = conn->hdev; - struct hci_cp_read_clock_offset cp; + struct hci_cp_read_clock_offset clkoff_cp; - cp.handle = cpu_to_le16(conn->handle); - hci_send_cmd(hdev, HCI_OP_READ_CLOCK_OFFSET, sizeof(cp), &cp); + clkoff_cp.handle = cpu_to_le16(conn->handle); + hci_send_cmd(hdev, HCI_OP_READ_CLOCK_OFFSET, sizeof(clkoff_cp), + &clkoff_cp); } conn->state = BT_DISCONN;