summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/nfc/pn533.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/nfc/pn533.c b/drivers/nfc/pn533.c
index 8be0ae626d73..a5766042f0ee 100644
--- a/drivers/nfc/pn533.c
+++ b/drivers/nfc/pn533.c
@@ -904,6 +904,8 @@ static int pn533_target_found(struct pn533 *dev,
if (resp->tg != 1)
return -EPROTO;
+ memset(&nfc_tgt, 0, sizeof(struct nfc_target));
+
target_data_len = resp_len - sizeof(struct pn533_poll_response);
switch (dev->poll_mod_curr) {