Commit e200f008 authored by Thierry Escande's avatar Thierry Escande Committed by Samuel Ortiz

NFC: digital: Free supervisor PDUs

This patch frees the RTOX resp sk_buff in initiator mode. It also makes
use of the free_resp exit point for ATN supervisor PDUs in both
initiator and target mode.
Signed-off-by: default avatarThierry Escande <thierry.escande@collabora.com>
Signed-off-by: default avatarSamuel Ortiz <sameo@linux.intel.com>
parent e073eb67
...@@ -823,15 +823,14 @@ static void digital_in_recv_dep_res(struct nfc_digital_dev *ddev, void *arg, ...@@ -823,15 +823,14 @@ static void digital_in_recv_dep_res(struct nfc_digital_dev *ddev, void *arg,
if (rc) if (rc)
goto error; goto error;
return; goto free_resp;
} }
rc = digital_in_send_rtox(ddev, data_exch, resp->data[0]); rc = digital_in_send_rtox(ddev, data_exch, resp->data[0]);
if (rc) if (rc)
goto error; goto error;
kfree_skb(resp); goto free_resp;
return;
} }
exit: exit:
...@@ -1225,8 +1224,7 @@ static void digital_tg_recv_dep_req(struct nfc_digital_dev *ddev, void *arg, ...@@ -1225,8 +1224,7 @@ static void digital_tg_recv_dep_req(struct nfc_digital_dev *ddev, void *arg,
ddev->atn_count++; ddev->atn_count++;
kfree_skb(resp); goto free_resp;
return;
} }
rc = nfc_tm_data_received(ddev->nfc_dev, resp); rc = nfc_tm_data_received(ddev->nfc_dev, resp);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment