summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2011-09-20Manual port of 6900b4 from gingerbread:Rob von Behren
Patch to add Secure Download Mechanism in the libnfc This patch permit to support secure download update and also to avoid locking states in case of download failures Bug: 5331837 Change-Id: Ia5b6d9baf57231b0193bbbe85c88c7df557017c6
2011-09-13Merge commit 'df34eb0e' into manualmergeJeff Hamilton
Change-Id: I9807e540bad19933452f4a9f86b74021265f29cf
2011-09-09am df82c4dd: Patch to add an API to load a FW image in the libnfcDaniel TOMAS
* commit 'df82c4dd7c6d5ad232b5628edf73aa9ea3f8c2c0': Patch to add an API to load a FW image in the libnfc
2011-09-09Patch to add an API to load a FW image in the libnfcDaniel TOMAS
This new API permit to load the PN544 FW image when a download is needed at boot time. Change-Id: I2b3406d7ae0f0211123bd680ef914e9948c81eef
2011-09-01Merge "Felica system code related changes"Martijn Coenen
2011-08-24Add the NXP_EVT_SE_SWITCH_MODE event support in the libnfc.Daniel Tomas
This event is used in the SE SetMode API to be able to enable/disable card emulation with not writting the EEPROM area. Change-Id: I80047d678f683c4dd364544c690440eb8d807793
2011-08-24Fix for removing unnecessary DESELECT before P2P activation in caseSunil Jogi
devices are moving in to the range and moving out of the range quickly Change-Id: I090367ad17de443c6af41c9ad507557e3eaaf7f9
2011-08-18Revert "Add the NXP_EVT_SE_SWITCH_MODE event support in the libnfc."Nick Pelly
This reverts commit 39038381fd4a9922cdd07251ce1a0a8840681bcd.
2011-08-16Add the NXP_EVT_SE_SWITCH_MODE event support in the libnfc.Daniel Tomas
This event is used in the SE SetMode API to be able to enable/disable card emulation with not writting the EEPROM area. Change-Id: Iace438c3625f6a084c8bcc66d787a7a60d56b8f8
2011-08-08Felica system code related changesSunil Jogi
Modified implementation for Felica card handling includes following: - SENSF_REQ with RC=0x00 during discovery - T3T NDEF detection with SC = 0x12FC - If card is not NDEF then poll for primary SC - NFC-F presence check with check for expected IDm Change-Id: I8e7e83a36ec2c6e8e423df751c4bc73badb6edb5
2011-08-02ISO15693 Format fixSunil Jogi
Added for check of first 4 bytes 0x00 before performing NDEF format of ISO15693 tag. Updated with usage of Read one block. Change-Id: I7a5299edb67ca70f7af5ef5a0909225c0bdf8cb0
2011-07-27Print a warning message on NXP_EVT_INFO_MEM_VIOLATION.Nick Pelly
This indicates the pn544 trim values were over-written by the faulty FW procedure, I have a FW to reset trim values to default. Revert this commit before ship. It should only be needed for dev phones. Change-Id: I77d3d66b6937f181c83022a0e0791a44974c51ae
2011-07-27Merge "Don't wait for timeout to send SYMM PDU's."Martijn Coenen
2011-07-27Don't wait for timeout to send SYMM PDU's.Martijn Coenen
The LLCP stack was holding onto the "I'm allowed to send" token for the full link time-out, even if there was nothing to send. This caused very bad round-trip delays. This fix just gives the token back immediately if there's nothing to send. Change-Id: Ib7bf87bd5fada2b682d28c9502b5ef010cd39815
2011-07-26Add the ability to enable LLCP logging.Jeff Hamilton
Change-Id: I94f16770d1803f89370df5a798a6c76670581a63
2011-07-26Merge "Fixed LLCP receive function when accessing RW."Martijn Coenen
2011-07-26Merge "Deal with LLCP send errors properly (part 1)."Martijn Coenen
2011-07-25Fixed LLCP receive function when accessing RW.Sylvain Fonteneau
In some situations, the working buffer may be full and some packets are stored in the receive window when trying to read from upper layer. In this case, the receive function first reads data from the working buffer and if possible, also tries to read data stored in the receive window. The previous receive window data extraction algorithm could lead to an infinite loop. With this fix, we can ensure that this won't happen any more. Change-Id: Iddb412213f4e9cb5fb42691bd282dbf0a21a936e
2011-07-25am 0c4a5508: am d8b82bee: am 34caeca8: Patch to support multiple connection ↵Daniel Tomas
on Multiple protocol TAG * commit '0c4a5508f22e067ab9b31581807b53406d161501': Patch to support multiple connection on Multiple protocol TAG
2011-07-25Deal with LLCP send errors properly (part 1).Martijn Coenen
Send failures on LLCP sockets were not dealt with at all - the transport was just left in a state where it thought there was a pending send and a pending callback. Before we typically only did one send and it didn't bite us so much, but now with multiple sockets we run into this frequently. This really just fixes part of the problem - we should also look if state rollbacks are necessary, as those are not done either on send failures. Change-Id: I484ca598e043ead835251aedaabe47d3a1da7a8f
2011-07-25Factorized and fixed code for automatic LLCP socket binding.Sylvain Fonteneau
Fixed the SAP automatic allocation algorithm which could previously allocate the same SAP twice in some situations (e.g.: if first socket in socket table was bound to SAP 0x21 and second socket to 0x20, then autobind was allocating SAP 0x21 again). Change-Id: Ic94bbc7eaca260c69cb0ce22931e9241f459bbf5
2011-07-21am 34caeca8: Patch to support multiple connection on Multiple protocol TAGDaniel Tomas
* commit '34caeca8a5ec2aedade68a77393d0aff03f9bd72': Patch to support multiple connection on Multiple protocol TAG
2011-07-21Merge "getTimeout() support in libnfc-nxp."Martijn Coenen
2011-07-20getTimeout() support in libnfc-nxp.Martijn Coenen
Bug: 4492175 Change-Id: I7f85fc32bfaabeac8fa4da6c1509992d5523afa3
2011-07-19Latest phDnldNfc.c code from NXP.Nick Pelly
This is to support 32 byte FW download. Change-Id: Id27e7d2673c37aab02d98fcbac9031af6153fea0
2011-07-14Revert "Patch to decrease the maximum packet size for NFC firmware download"Nick Pelly
This reverts commit 294b456a3692cd69f45713bc8e9700132a0e5aec. @#$% the pn544. This patch to execute FW download mode with 64 byte frames has some kind of side-affect. It causes the pn544 to send > NFC I2C Received buffer: 0xB2 0x83 0x53 0xC9 0x6B every 2 seconds. We do not yet know what this command means, it is undocumented. This side affect appear permanent - even after reverting to a 512 byte FW download, the NFC controller continues to send these messages. Reverting ASAP to minimize damage. Change-Id: I139a4a76c045f580df9760dc11d1c6df7b317a50
2011-07-14Patch to support multiple connection on Multiple protocol TAGDaniel Tomas
Change-Id: I0f09869458ebbc6d77363338975754335569b6a6
2011-07-14Delay 5ms after FW SW reset command due to clock instability.Nick Pelly
This was preventing reliable FW download. Change-Id: I28e5cb1e5855974f51578f5d45f2c581a75b2d07
2011-07-12Patch to decrease the maximum packet size for NFC firmware downloadDaniel Tomas
This patch permit to decrease the max packet size to 64 bytes from 512 bytes and to fix an issue faced in response_data buffer with the new packet size. Change-Id: Ifc5cc9910b3b1a71b88624cd04c2bada7f1a413f
2011-07-04Check SAP range in LLCP sockets.Sylvain Fonteneau
LLCP specification mentions that SAP numbers are allocated as follows: - from 0x00 to 0x0F, used for well-known services - from 0x10 to 0x1F, used for SDP advertised services - from 0x20 to 0x3F, used for *non* SDP advertised services This patch enforce this restriction. Change-Id: Idd8ab4da4cfa9ad9e2dbf7eddc3c66900bcf9ff8
2011-06-28am 51c0ca53: am f1612434: am 967359c8: Patch to support the new PN544 ↵Daniel Tomas
firmware events * commit '51c0ca53011b86464dcf14aeb33944a69861a8f4': Patch to support the new PN544 firmware events
2011-06-28am 967359c8: Patch to support the new PN544 firmware eventsDaniel Tomas
* commit '967359c892ff74962b4f4243d989f447ffe4ae11': Patch to support the new PN544 firmware events
2011-06-28Patch to add the windowing support in the libnfcDaniel Tomas
This patch enables windowing of LLC packets send from chipset to host. The host will now wait for up to 4 LLC packets from the chipset before sending an ACK (S-Frame RR). Change-Id: I6a70e1d780847a104e3ec8e403593a69e222aec9
2011-06-28Patch to support the new PN544 firmware eventsandroid-cts-2.3_r5Daniel Tomas
Change-Id: I6e5a976721fb52f2da30081276bb2ac15d27d186
2011-06-27Print warning if no FW file found.Nick Pelly
Change-Id: Id1ab6a1176fe4e7c559e2348261d0902bdffb03c
2011-06-27libnfc spring cleaningNick Pelly
o Fix most libnfc warnings, from 360 to 18 o Make DAL_DEBUG much less verbose and more useful o Clean up Android.mk Done with minimal textual diff to minimize merge conflicts. Change-Id: I918645500723ff7bb092ad9959628fcabac45bec
2011-06-22Implement power control and firmware download for UART.Nick Pelly
Also clean up some UART and I2C DAL functions. o Re-enable FW download o Use /system/vendor/firmware for pn544 firmware now o Clean up read() and write() paths for both I2C and UART o Use new sysfs entry for power and FW control on I2C platforms o Remove userspace sleep()'s on power control toggle. They are now done in the kernel as they should be. Change-Id: I39956d36e02c1eb526a5c546bd3cb74edce4ff18
2011-06-14Misc changes for Nexus Prime bringup.Nick Pelly
o Fix uart read() implementation o Temporarily disable firmware update o Rename ttySx to ttyOx (this should be properly abstracted later) o Bug fix in #ifdef code o Update verbose logging arguments Change-Id: I87814e2be9ddbf5036d5586a2fd82311d56ec47f
2011-06-09Make NfcA timeout configurable in libnfc.Martijn Coenen
Adds an interface for setting the NfcA timeout, which is called "mifare raw" in libnfc. Also changed the default, since it was set to only 2 ms, which is too short for most commands. Current setting is around 600ms. Change-Id: I00ccd85cd47a70895a3aca0f0bc34e1b0eab82c7
2011-06-08am 055a5f95: am b76c80da: am 80c2d409: Merge "Prevent NFC crash-loop if ↵Jean-Baptiste Queru
firmware cannot be loaded." * commit '055a5f9542ba8fcfd2972111b707049732255ebe': Prevent NFC crash-loop if firmware cannot be loaded.
2011-06-06Merge "Implement Felica timeout handling (libNFC)."Martijn Coenen
2011-06-06Add support for connecting to NfcA on IsoDep tags.Martijn Coenen
Always add a ISO14443-3A device handle for tags that are found through the A-gate. This allows the upper stack to connect and maintain a connection to the NfcA technology, even if the tag has IsoDep on top of NfcA. The reason this can work is that libnfc does do the IsoDep activation in software, and if the NfcA target is on a separate handle this activation will not take place if you connect to this handle. Bug: 4195403 Change-Id: I00015e74bdadc6666c2971f8102244670a76e340
2011-06-03Implement Felica timeout handling (libNFC).Martijn Coenen
Change-Id: I1a88ae0807d5ba53a635e31f3c5284906bd40ea2
2011-06-03Update V(RA) counter in LLCP sockets any time it is needed.Sylvain Fonteneau
At some points, the V(RA) socket counter (used for Receive Window checking in connection-oriented sockets) was not properly updated, thus leading to sometimes reject (FRMR) inbound I-frames with valid sequence numbers. This patch factorize the I-frame emission and update V(RA) in the factorized code to ensure this is done at any time. Change-Id: Ic7ef92cb136c32e524a14e31a8d350f7b165c367
2011-06-03am 80c2d409: Merge "Prevent NFC crash-loop if firmware cannot be loaded."Jean-Baptiste Queru
* commit '80c2d4090d6292a3fd2e20a18a981bc19e0a0429': Prevent NFC crash-loop if firmware cannot be loaded.
2011-06-02Prevent NFC crash-loop if firmware cannot be loaded.Martijn Coenen
Don't crash - just run off whatever firmware is in the chip now. Change-Id: I0d24c13452271aed63a5a0aea236db7b1cbd432c
2011-05-19Patch to enable low level traces.Daniel Tomas
This patch permit to display the NFC frames exchanged through the I2C line. To enable that, you just need to enable LOW_LEVEL_TRACES macro. Change-Id: Ica2ff2e6d111b76c056161ec557346f23d21ada0
2011-05-16Fixed LLCP SAP value range.Sylvain Fonteneau
Valid LLCP Service Access Point values are 0x00 to 0x3F, not 0x2F. Before this patch, a socket with a local SAP between 0x30 and 0x3F was unable to communicate (operation callbacks were never called). Change-Id: Ic3f9b9f353a01e2682e28575152f171d7ec421e4
2011-04-14Avoid missing NFCIP inbound frame.Sylvain Fonteneau
If a NFCIP frame is received (NXP_EVT_NFC_RCV_DATA event) before a call to phHal4Nfc_Receive() function, the frame was lost. This could happen if the local host acts as a Target and the remote peer sends its first frame too fast. The data is actually saved in a temporary buffer but, when the phHal4Nfc_Receive() is eventualy called, it triggers a callback with a status code NFCSTATUS_MORE_INFORMATION, which is handled as an error. This patch fixes this behaviour and makes sure that the correct status code is provided with the frame itself. Change-Id: I5311762ca70c71f98dea0287b0844eb1c8dddb6b
2011-04-08Ignore unreadable TLVs during LLCP activation and CONNECT/CC.Sylvain Fonteneau
The LLCP specification defines that if a TLV cannot be interpreted, it shall be ignored rather than generating an error. This patch removed all error reporting on TLV interpretation. The only error that can still happen is length inconsistency in the whole TLV array buffer. Change-Id: Ibf289fceb2283bfddcdc0ddee9e687ece3e90887