Skip to contentSkip to conversation

NFC: Increase NCI deactivate timeout

PATCH In review [email protected] 3 participants 4 messages Jan 8, 2012 – Jan 17, 2012

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 NFC: Increase NCI deactivate timeout

From: Ilan Elias <[email protected]>

Increase NCI deactivate timeout from 5 sec to 30 sec. NCI deactivate procedure might take a long time, depending on the local and remote parameters.

---
 include/net/nfc/nci_core.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
include/net/nfc/nci_core.h +1 -1
index bccd89e..f4963ea 100644
@@ -47,7 +47,7 @@ enum {
 #define NCI_RESET_TIMEOUT			5000
 #define NCI_INIT_TIMEOUT			5000
 #define NCI_RF_DISC_TIMEOUT			5000
-#define NCI_RF_DEACTIVATE_TIMEOUT		5000
+#define NCI_RF_DEACTIVATE_TIMEOUT		30000
 #define NCI_CMD_TIMEOUT				5000
 
 struct nci_dev;
Signature · 1 line
1.7.0.4
#1 lore raw

Hi Ilan,

Quoted 5 lines · On Sun, 2012-01-08 at 13:43 +0200, [email protected] wrote:

From: Ilan Elias <[email protected]>

Increase NCI deactivate timeout from 5 sec to 30 sec. NCI deactivate procedure might take a long time, depending on the local and remote parameters.

30 seconds sounds like a huge delay for receiving a reply to such command. Would you care explaining how we can get that long of a timeout ?

Cheers,
Samuel.

#2 lore raw

Hi Samuel,

Quoted 6 lines
Quoted 3 lines

Increase NCI deactivate timeout from 5 sec to 30 sec. NCI deactivate procedure might take a long time, depending on the local and remote parameters.

30 seconds sounds like a huge delay for receiving a reply to such command.
Would you care explaining how we can get that long of a timeout ?

The controller in the Reader side uses a value called nRETRY (see NFC Forum Digital spec). This value is an internal implementation, valid range is 2 to 5.
This value determines the number of re-transmissions.

The controller in the Tag side uses a value called FWI - Frame Waiting time Integer (see NFC Forum Digital spec). This value is an internal implementation, valid range is 1 to 14.
This value determines (via some formula) the FWT - Frame Waiting Time, which is a timout.
Max FWT value can be almost 5sec.

So, the total max timeout can be 5sec for the first packet + 5sec for each of the 5 re-transmissions = 5 + 5x5 = 30 sec.

Quoted 2 lines

Cheers,
Samuel.

Thanks & BR,
Ilan