From: Mathias Jeppsson Date: Fri, 6 Jul 2012 22:53:19 +0000 (+0200) Subject: NFC: Fix order of arguments to list_add_tail() when queueing HCP frames X-Git-Tag: v3.6-rc2~24^2~30^2~14 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=f8bf65bf3688835f95f7c74f5c844a64b2743a42;p=~emulex%2Finfiniband.git NFC: Fix order of arguments to list_add_tail() when queueing HCP frames The HCP message should be added to transmit queue, not the other way around. Signed-off-by: Mathias Jeppsson Signed-off-by: Samuel Ortiz Signed-off-by: John W. Linville --- diff --git a/net/nfc/hci/hcp.c b/net/nfc/hci/hcp.c index 7212cf2c578..f4dad1a8974 100644 --- a/net/nfc/hci/hcp.c +++ b/net/nfc/hci/hcp.c @@ -105,7 +105,7 @@ int nfc_hci_hcp_message_tx(struct nfc_hci_dev *hdev, u8 pipe, } mutex_lock(&hdev->msg_tx_mutex); - list_add_tail(&hdev->msg_tx_queue, &cmd->msg_l); + list_add_tail(&cmd->msg_l, &hdev->msg_tx_queue); mutex_unlock(&hdev->msg_tx_mutex); queue_work(hdev->msg_tx_wq, &hdev->msg_tx_work);