summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartijn Coenen <maco@google.com>2012-02-05 20:32:21 +0100
committerMartijn Coenen <maco@google.com>2012-02-06 22:47:42 +0100
commit6bd5058796097ae40ed41c283a69e7874f2e9db2 (patch)
treed8fe0872b48324f23f19ce4a0adb7bd19d097b3e
parent146a80875c2f5f93ab550feaaf793c1b327ba6e1 (diff)
downloadexternal_libnfc-nxp-6bd5058796097ae40ed41c283a69e7874f2e9db2.zip
external_libnfc-nxp-6bd5058796097ae40ed41c283a69e7874f2e9db2.tar.gz
external_libnfc-nxp-6bd5058796097ae40ed41c283a69e7874f2e9db2.tar.bz2
Fix NFCSTATUS_BUSY responses after doing p2p.
LLCP state was not reset properly. Bug: 5971895 Change-Id: I4fda6ef7c78ae2730359cf5c90d887d205e57799
-rw-r--r--src/phFriNfc_Llcp.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/phFriNfc_Llcp.c b/src/phFriNfc_Llcp.c
index 1f66216..8138cd3 100644
--- a/src/phFriNfc_Llcp.c
+++ b/src/phFriNfc_Llcp.c
@@ -627,7 +627,7 @@ static void phFriNfc_Llcp_HandleMACLinkDeactivated( phFriNfc_Llcp_t *Llcp )
}
/* Reset state */
- Llcp->state = PHFRINFC_LLCP_STATE_DEACTIVATION;
+ Llcp->state = PHFRINFC_LLCP_STATE_RESET_INIT;
switch (state)
{
@@ -717,7 +717,8 @@ static void phFriNfc_Llcp_ResetLTO( phFriNfc_Llcp_t *Llcp )
{
Llcp->state = PHFRINFC_LLCP_STATE_OPERATION_RECV;
}
- else if (Llcp->state != PHFRINFC_LLCP_STATE_DEACTIVATION)
+ else if (Llcp->state != PHFRINFC_LLCP_STATE_DEACTIVATION &&
+ Llcp->state != PHFRINFC_LLCP_STATE_RESET_INIT)
{
/* Not yet in OPERATION state, perform first reset */
if (Llcp->eRole == phFriNfc_LlcpMac_ePeerTypeInitiator)