summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Merge "Fixed FRMR sending on invalid LLCP frame received"Martijn Coenen2012-02-062-12/+12
|\
| * Fixed FRMR sending on invalid LLCP frame receivedSunil Jogi2012-02-062-12/+12
| | | | | | | | | | | | | | DSAP and SSAP were switched on with the other at multiple location in the code. This patch fix those. Change-Id: Iea8e499049a2cd4a234155a3044b875eb9c6ca7a
* | am 700428d8: am 8c56cd9e: Reconcile with ics-mr1-releaseThe Android Open Source Project2012-02-010-0/+0
|\ \ | |/ |/| | | * commit '700428d8f73604f27f4416fd14d3ef1cb86fca9e':
| * am 8c56cd9e: Reconcile with ics-mr1-releaseThe Android Open Source Project2012-02-010-0/+0
| |\ | | | | | | | | | * commit '8c56cd9e0bc2808d73e6596ba3bb128cc2fbcd7c':
| | * Reconcile with ics-mr1-releaseThe Android Open Source Project2012-02-010-0/+0
| | |\ | | | | | | | | | | | | Change-Id: Iee6e204b8a44a1efb75dea184cc1a69baac91f06
* | | | Handle inbound buffering in LLCP connectionless socketsSunil Jogi2012-01-303-67/+171
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This enables the server to avoid losing packets, especially when receiving them in an aggregated packet. The size of the buffer is determined by the size of the working buffer provided by the application. Change-Id: Ia3c72e19fdb74e2a43390af5607c497c2275fe46
* | | | Fixed rejected receive request in LLCPSunil Jogi2012-01-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If phLibNfc_Llcp_Recv() is called in the callback of a previous phLibNfc_Llcp_Recv(), it could be rejected due to the bSocketRecvPending flag which was not properly reset. Change-Id: I6c41469480b50bb7adc9a721ec96f715e5d56a60
* | | | Fixed wrong callbacks callSunil Jogi2012-01-301-19/+17
| | | | | | | | | | | | | | | | | | | | | | | | Call the callback only if the context is not null. Change-Id: I783d9e8ddedb2546eff85837826703db189f9f59
* | | | Increase internal LLCP buffers to fit max MIUSunil Jogi2012-01-272-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Interal buffer increased to 2178 = 3 (max LLCP header size) + 128 (default MIU) + 2047 (max MIU) Change-Id: I3cc2ff705e74ae657d93b5e50a577b0e7e5ebfcf
* | | | Reset LLCP socket internal variables before next use.Sunil Jogi2012-01-271-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some internal variables used in reveive window checkings were not reset on socket closure/re-opening. This was leading to have the send() function waiting forever for remote acknowledgments. Change-Id: Ic7741b004de80af3f851f620842d46c42f654804
* | | | Update for LLCP V(SA) internal variableSunil Jogi2012-01-271-6/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The V(SA) is an internal variable used in LLCP connection-oriented data links to check receive window conditions. It corresponds to the last frame number acknowledged by remote peer + 1. The patch makes sure this variable is updated evry time it is needed. Change-Id: Ie5ac925a6f1dfa19b22ac2b6e96659440d5daf21
* | | | LLCP 1.1: Fix some bugs.Martijn Coenen2012-01-272-3/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - Clear out send callback if send was not accepted. - Set transport busy status for RR/RNR frames. Change-Id: Idf8986f6b82995644b176247a644e36d2c879ebf
* | | | Adding support for handling maximum length supported by peerSunil Jogi2012-01-274-21/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Support for chaining is added based on maximum length supported by and passed in ATS by peer and maximum length supported by the device. Change-Id: I8f9f8468ff8ac9d3579bc8b6afbe3e2072e56de8
* | | | LLCP 1.1 implementation.Sunil Jogi2012-01-2711-108/+912
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, in LLCP v1.0, the only way to use the SDP (Service Discovery Protocol) service was to send a CONNECT frame containing the Service Name to the SDP service. This was implicitly preforming a connection request to the requested service. LLCP v1.1 introduced a way to discover services more efficiently and without implicit connection. It also enables connectionless services to have a service name. It is based on a new protocol based on a new SNL frame containing discovery requests and responses. This update comes with new APIs: - phLibNfc_Llcp_DiscoverServices() function can be used to discover remote services. It can take multiple service names and resolve all of them in a single call. - Register service name at bind time. Cache LLCP service name/sap pairs. In LLCP 1.1 specification defines at section 5.9 that any service lookup answer must be valid for the whole LLCP session duration. To enforce this, we cache the SAP/SN pairs locally and make sure that the applications don't break the cache. The stack remains fully retro-compatible with v1.0 devices. Change-Id: I052edd3838013cee65e7415d0ed01fc3e9cad36d
* | | | LLCP 1.1: allow pending operations on connectionless.Sunil Jogi2012-01-276-469/+595
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The pending operations were handled at the connection-oriented sockets level, with no possibility for other transport types to handle pending operations. A dispatcher has been added at the generic transport level to remove this limitation. This feature is needed to implement LLCP v1.1. Change-Id: I69e37ba800d1c531396ca97ab0a0480e0f53d63f
* | | | Don't overwrite psUpperLayerContext when reconfiguring the SE.Martijn Coenen2012-01-202-54/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes one of the crashes occuring when turning the screen off during p2p transfers. One remaining. Change-Id: I3e45be9b8f4be40350ba4dd9db7e596631206bd1
* | | | Clear out send/recv callbacks for connectionless sockets.Martijn Coenen2012-01-201-3/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a connectionless socket is closed, Connectionless_Abort() is called, which in turn calls the send and receive callbacks to indicate abortion. But since these callbacks are not cleared out after a previous send/receive has completed, this can lead to spurious callbacks and consequently memory corruption. Change-Id: Iea7a34829c4db1cae3b49f33117b25b50205683f
* | | | Prevent LLCP stack from deactiving twice.Martijn Coenen2012-01-131-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some parts of the code reset the state to an operation state, even if the link has already been shutdown. This allowed for a second deactivation callback, causing a crash higher up in the stack. Bug: 5765077 Change-Id: I2f2ac720756353d45d82634d27a3dd9acecae43d
* | | | Rename (IF_)LOGE(_IF) to (IF_)ALOGE(_IF) DO NOT MERGESteve Block2012-01-065-15/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | See https://android-git.corp.google.com/g/#/c/157220 Bug: 5449033 Change-Id: I935ee4450e2e62ced1537bafb787ad402cfcb69c
* | | | Rename (IF_)LOGW(_IF) to (IF_)ALOGW(_IF) DO NOT MERGESteve Block2012-01-054-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | See https://android-git.corp.google.com/g/157065 Bug: 5449033 Change-Id: I05dd3a5e5f671c0fdc17bf4e3d52395ccdb56e45
* | | | Rename (IF_)LOGD(_IF) to (IF_)ALOGD(_IF) DO NOT MERGESteve Block2012-01-032-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | See https://android-git.corp.google.com/g/156016 Bug: 5449033 Change-Id: Ie5dac4fad8942433d2b8fe3c0539e4c3c678a082
* | | | am 593d6d4a: Reconcile with ics-mr1-releaseThe Android Open Source Project2011-12-090-0/+0
|\ \ \ \ | |/ / / | | | | | | | | * commit '593d6d4a79601c530825ce9a52fd3f4cf03e1b6f':
| * | | Reconcile with ics-mr1-releaseThe Android Open Source Project2011-12-080-0/+0
| |\ \ \ | | |/ / | |/| / | | |/ Change-Id: If89fd19c4cd2215ee43c5ef1dbd151c049d940d2
* | | Reconcile with ics-mr1-releaseThe Android Open Source Project2011-11-100-0/+0
|\ \ \ | | |/ | |/| | | | Change-Id: Iaf498cf86a8995a7c51b3b88c3b1acebdf0185b7
| * | merge in ics-mr1-release history after reset to ics-mr1The Android Automerger2011-11-080-0/+0
| |\ \ | | |/ | |/|
* | | am b99be65c: Use NFC HAL for some libnfc settings.Martijn Coenen2011-11-076-114/+56
|\ \ \ | |/ / | | | | | | | | | * commit 'b99be65c277b0cc65a00a33e784ed49461531737': Use NFC HAL for some libnfc settings.
| * | Use NFC HAL for some libnfc settings.Martijn Coenen2011-11-036-114/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The NFC HAL in libhardware allows us to store and retrieve product-specific settings. This patch moves two product-specific settings to the HAL: the device port, and the usage of the i2c workaround we had for crespo. This means configuring the port no longer needs to be done from JNI land. Change-Id: I2e19b6f188f808bc2f2a1f1abc28f2a6c47e6a4c
* | | Reconcile with ics-mr1-releaseThe Android Open Source Project2011-10-310-0/+0
|\ \ \ | |/ / |/| / | |/ Change-Id: I1f8bab351bcf7e2e90623aae71c725a123144440
| * merge in ics-mr1-release history after reset to ics-mr1The Android Automerger2011-10-260-0/+0
| |\ |/ /
| * merge in ics-release history after reset to masterThe Android Automerger2011-10-230-0/+0
| |\
| | * merge in ics-release history after reset to masterThe Android Automerger2011-09-250-0/+0
| | |\
| | | * merge in ics-release history after reset to masterThe Android Automerger2011-09-140-0/+0
| | | |\
| | | | * merge in ics-release history after reset to masterThe Android Automerger2011-09-020-0/+0
| | | | |\
| | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-08-250-0/+0
| | | | | |\
| | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-08-220-0/+0
| | | | | | |\
| | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-08-170-0/+0
| | | | | | | |\
| | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-08-030-0/+0
| | | | | | | | |\
| | | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-07-280-0/+0
| | | | | | | | | |\
| | | | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-07-270-0/+0
| | | | | | | | | | |\
| | | | | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-07-260-0/+0
| | | | | | | | | | | |\
| | | | | | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-07-220-0/+0
| | | | | | | | | | | | |\
| | | | | | | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-07-210-0/+0
| | | | | | | | | | | | | |\
| | | | | | | | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-07-200-0/+0
| | | | | | | | | | | | | | |\
| | | | | | | | | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-07-190-0/+0
| | | | | | | | | | | | | | | |\
| | | | | | | | | | | | | | | | * merge in ics-release history after reset to masterThe Android Automerger2011-07-150-0/+0
| | | | | | | | | | | | | | | | |\
| | | | | | | | | | | | | | | | | * Revert "Patch to decrease the maximum packet size for NFC firmware download"Nick Pelly2011-07-141-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* | | | | | | | | | | | | | | | | | Merge remote branch 'goog/ics-mr0' into ics-mr1Ed Heyl2011-10-260-0/+0
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | | | | | | | Use a 10s timeout in uart_read() in FW download mode.Nick Pelly2011-10-252-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This provides a path to flush RX, necessary when we enter FW download mode with bogus data already in RX. This fixes a problem where NFC was dead on several HSPA and LTE devices. Also decrease FW timeout completition from 120s to 60s. Typically FW download takes 30s, and 120 is unnecessarily large and causes a long delay to bring up NFC when we need to retry FW. Bug: 5468674 Change-Id: I0fd40c199daac861fe5acda4f2d214bdcff8e869
* | | | | | | | | | | | | | | | | | | Use a 10s timeout in uart_read() in FW download mode.Nick Pelly2011-10-252-2/+6
| |/ / / / / / / / / / / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This provides a path to flush RX, necessary when we enter FW download mode with bogus data already in RX. This fixes a problem where NFC was dead on several HSPA and LTE devices. Also decrease FW timeout completition from 120s to 60s. Typically FW download takes 30s, and 120 is unnecessarily large and causes a long delay to bring up NFC when we need to retry FW. Bug: 5468674 Change-Id: I0fd40c199daac861fe5acda4f2d214bdcff8e869
* | | | | | | | | | | | | | | | | | am 17abc6eb: (-s ours) Merge "Remove NFC I2C workaround for Prime (DO NOT ↵Martijn Coenen2011-10-210-0/+0
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MERGE)." into ics-mr0 * commit '17abc6eb45b326f574c657e227670a8fddf9385e': Remove NFC I2C workaround for Prime (DO NOT MERGE).