aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/nfc/nfcmrvl (follow)
AgeCommit message (Collapse)AuthorFilesLines
2015-11-05NFC: nfcmrvl: avoid being stuck on FW dnld timeoutVincent Cuissard1-3/+9
FW Download procedure can block on del_timer_sync because the timer is not running. This patch check that timer is scheduled before cancelling it. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-11-05NFC: nfcmrvl: remove unneeded CONFIG_OF switchesVincent Cuissard2-24/+0
Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-11-05NFC: nfcmrvl: free reset gpioVincent Cuissard1-0/+3
Reset GPIO shall be freed by the driver since the device used in devm_ calls can be still valid on unregister. If user removes the module and inserts it again, the devm_gpio_request will fail because the underlying physical device (e.g i2c) was not removed so the device management won't have freed the gpio. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-11-05NFC: nfcmrvl: add a small wait after setting UART breakVincent Cuissard1-1/+3
A small wait is inserted to ensure that controller has enough time to handle the break character. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-11-05NFC: nfcmrvl: avoid UART break control during FW downloadVincent Cuissard1-4/+6
BootROM does not support any form of power management during FW download. On UART, the driver shall not try to send breaks. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-11-05NFC: nfcmrvl: fix SPI driver dependenciesArnd Bergmann1-1/+1
The newly added nfcmrvl_spi driver uses the spi_nci infrastructure, but does not have a Kconfig dependency on that, so we can get a link-time error: drivers/built-in.o: In function `nfcmrvl_spi_nci_send': (.text+0x1428dc): undefined reference to `nci_spi_send' drivers/built-in.o: In function `nfcmrvl_spi_probe': (.text+0x142a24): undefined reference to `nci_spi_allocate_spi' drivers/built-in.o: In function `nfcmrvl_spi_int_irq_thread_fn': (.text+0x142abc): undefined reference to `nci_spi_read' This clarifies the dependency. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: caf6e49bf6d0 ("NFC: nfcmrvl: add spi driver") Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-10-27NFC: nfcmrvl: update device tree bindings for Marvell NFCVincent Cuissard3-5/+9
Align NFC bindgins to use marvell instead of mrvl. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-10-27NFC: nfcmrvl: add spi driverVincent Cuissard4-1/+246
This driver adds the support of SPI-based Marvell NFC controller. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-10-27NFC: nfcmrvl: add i2c driverVincent Cuissard5-4/+311
This driver adds the support of I2C-based Marvell NFC controller. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-10-27NFC: nfcmrvl: configure head/tail room values per low level driversVincent Cuissard4-9/+14
Low-level drivers may need to add some data before and/or after NCI packet. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-10-27NFC: nfcmrvl: add firmware download supportVincent Cuissard7-10/+718
Implement firmware download protocol for Marvell NFC controllers. This protocol is based on NCI frames that's why parts of its implementation use some NCI generic functions. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-10-27NFC: nfcmrvl: remove unneeded version definesVincent Cuissard2-9/+3
Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-10-19NFC: nfcmrvl: Auto-select core moduleJean Delvare1-7/+5
As I understand it, the core nfcmrvl module is useless without either the USB or the UART access module. So hide NFC_MRVL and select it automatically if either NFC_MRVL_USB or NFC_MRVL_UART is selected. This avoids presenting NFC_MRVL when neither NFC_MRVL_USB nor NFC_MRVL_UART can be selected. Signed-off-by: Jean Delvare <jdelvare@suse.de> Cc: Lauro Ramos Venancio <lauro.venancio@openbossa.org> Cc: Aloisio Almeida Jr <aloisio.almeida@openbossa.org> Cc: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-13NFC: nfcmrvl: set PB_BAIL_OUT at setupVincent Cuissard2-0/+9
PB_BAIL_OUT parameter as to be set to one. This is needed because digital protocol 1.0 is used in combination with ISO15693 protocol. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-13NFC: nfcmrvl: Allow ISO15693 protocolVincent Cuissard1-0/+1
Reference Marvell NFC controller as ISO15693 capable. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-13NFC: nfcmrvl: small fix in USB driverVincent Cuissard1-0/+1
Marvell NFC USB driver has to be updated to follow new multi PHY driver interface. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-11NFC: nfcmrvl: add UART driverVincent Cuissard4-0/+246
Add support of Marvell NFC chip controlled over UART Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-11NFC: nfcmrvl: add platform_data and DT configurationVincent Cuissard3-26/+82
Declare nfcmrvl platform_data structure and few DT parameters for nfcmrvl driver. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-11NFC: nfcmrvl: add chip reset managementVincent Cuissard2-0/+38
Low level driver can specify a GPIO that will be used to reset the chip. Thanks to this the driver can ensure the state of the device at init. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-11NFC: nfcmrvl: update USB device idVincent Cuissard1-1/+2
Device ID was not restrictive enough. This patch select the USB device with the full device and interface characteristics. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-11NFC: nfcmrvl: update nci recv frame APIVincent Cuissard3-16/+23
Update internal nci recv frame API to use skbuff phy management to generic part of the driver. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-11NFC: nfcmrvl: add support of HCI-based transportVincent Cuissard3-4/+52
In some configuration NCI packet can be encapsulated in HCI packets. This patch had the support of this. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-06-11NFC: nfcmrvl: remove integration related settingsVincent Cuissard1-9/+0
These settings are related to a specific integration that requires the firmware to drive some GPIOs for external RF coexistency. Since this is really linked to specific hardware integration let's remove them. Signed-off-by: Vincent Cuissard <cuissard@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2015-04-07NFC: logging neateningJoe Perches2-11/+11
Add missing terminating newlines to nfc_info and nfc_err to avoid possible interleaving from other messages. Miscellanea: o typo fix of "unknonwn" in message o remove unnecessary OOM messages as there's a generic dump_stack() o realign arguments Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2014-01-09NFC: nfcmrvl: Fix possible memory leak issueAmitkumar Karwar1-2/+7
This patch fixes memory leaks in the error paths of nfcmrvl_nci_register_dev() routine. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2014-01-07NFC: nfcmrvl: Add setup handlerAmitkumar Karwar2-0/+21
Marvell nfc device provides support for external coexistance control. It allows Device Host to inhibit the NFCC from polling when required by asserting a GPIO pin. A second pin allows the DH to have feedback on the current NFCC state. The required configuration for this feature is done in setup handler. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2014-01-07NFC: nfcmrvl: Initial commit for Marvell NFC driverAmitkumar Karwar5-0/+678
This patch adds NFC support for Marvell 8897 NFC-over-USB chipset. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>