summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartijn Coenen <maco@google.com>2013-04-25 17:27:48 -0700
committerMartijn Coenen <maco@google.com>2013-04-25 17:27:48 -0700
commit42f5b41d22bbbad1b16b9cd3aba0512a399f32a6 (patch)
tree4b2e769ad15695188332d89e425e43ef809b4aa0
parentd508d9900a7d318073bd7b308d094755df316527 (diff)
downloadlibnfc-nxp-42f5b41d22bbbad1b16b9cd3aba0512a399f32a6.tar.gz
This allows the caller to recovery by trying again. Bug: 8552749 Change-Id: Iff979c097d33f9adda06654de9e588595daf89a3
-rw-r--r--src/phHciNfc_Sequence.c2
-rw-r--r--src/phLibNfc_discovery.c9
2 files changed, 9 insertions, 2 deletions
diff --git a/src/phHciNfc_Sequence.c b/src/phHciNfc_Sequence.c
index 1ef7265..6d0bf13 100644
--- a/src/phHciNfc_Sequence.c
+++ b/src/phHciNfc_Sequence.c
@@ -456,7 +456,7 @@ phHciNfc_FSM_Validate(
} /* End of State Validation Switch */
if( NFC_FSM_IN_PROGRESS == psHciContext->hci_state.transition )
{
- status = PHNFCSTVAL(CID_NFC_HCI, NFCSTATUS_INVALID_STATE);
+ status = PHNFCSTVAL(CID_NFC_HCI, NFCSTATUS_BUSY);
}
break;
}
diff --git a/src/phLibNfc_discovery.c b/src/phLibNfc_discovery.c
index 1fe4d8f..c512f73 100644
--- a/src/phLibNfc_discovery.c
+++ b/src/phLibNfc_discovery.c
@@ -194,7 +194,14 @@ NFCSTATUS phLibNfc_Mgt_ConfigureDiscovery (
}
else
{
- RetVal=NFCSTATUS_FAILED;
+ if (PHNFCSTATUS(RetVal) == NFCSTATUS_BUSY)
+ {
+ RetVal = NFCSTATUS_BUSY;
+ }
+ else
+ {
+ RetVal=NFCSTATUS_FAILED;
+ }
}
}