On Mon, May 13, 2019 at 12:44 PM Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> wrote: > > It has been reported that some laptops, equipped with NXP NFC300, have > different ID then mentioned in the driver. > > While at it, I found that the driver has a lot of duplication and redundant > platform data. The rest of the series (11 out of 12 patches) is dedicated to > clean the driver up. > > Sedat, would be nice if you can compile kernel with this patch series applied > and test on your laptop. > Hi Andy, Hi Oleg, I have tested Andy's v2 series on my ThinkPad T470 successfully with Linux v5.1.1. Additionally, I had the NFC patch "NFC: fix attrs checks in netlink interface" from Andrey Konovalov (see [1]). sdi@iniza:~/src/linux-kernel/linux$ git log --oneline v5.1.1.. 729d291510c2 (HEAD -> 5.1.1-1-amd64-gcc8-ldbfd) Merge branch 'for-5.1/nfc-nxp-nci' into 5.1.1-1-amd64-gcc8-ldbfd f083f056830c (for-5.1/nfc-nxp-nci-v2) NFC: nxp-nci: Convert to SPDX license tags 132b5681e074 NFC: nxp-nci: Remove 'default n' for tests 840b1df28cab NFC: nxp-nci: Remove unused macro pr_fmt() 5b55e26db0c2 NFC: nxp-nci: Drop comma in terminator lines 0a1edd5ce3bb NFC: nxp-nci: Drop of_match_ptr() use acae10451393 NFC: nxp-nci: Constify acpi_device_id 07648528dae3 NFC: nxp-nci: Get rid of useless label 38b8c38f2187 NFC: nxp-nci: Get rid of code duplication in ->probe() 446f5aef4522 NFC: nxp-nci: Add GPIO ACPI mapping table 813d4243c563 NFC: nxp-nci: Convert to use GPIO descriptor 1e5187ddb944 NFC: nxp-nci: Get rid of platform data 775a4fa8fb68 NFC: nxp-nci: Add NXP1001 to the ACPI ID table db79db400c5b Merge branch 'for-5.1/nfc' into 5.1.1-1-amd64-cbl-asmgoto e1c37435140f (for-5.1/nfc) NFC: fix attrs checks in netlink interface With neard (daemon) and neard-tools packages from Debian/buster AMD64 I am able to access, list and poll from my NFC (nfc0) device. root@iniza:~# systemctl status neard.service ● neard.service - LSB: NFC daemon Loaded: loaded (/etc/init.d/neard; generated) Active: active (running) since Mon 2019-05-13 13:14:12 CEST; 16min ago Docs: man:systemd-sysv-generator(8) Process: 810 ExecStart=/etc/init.d/neard start (code=exited, status=0/SUCCESS) Tasks: 1 (limit: 4915) Memory: 1.6M CGroup: /system.slice/neard.service └─885 /usr/lib/neard/neard Mai 13 13:14:12 iniza systemd[1]: Starting LSB: NFC daemon... Mai 13 13:14:12 iniza neard[877]: NEAR daemon version 0.16 Mai 13 13:14:12 iniza neard[810]: Starting NFC daemon: neard. Mai 13 13:14:12 iniza systemd[1]: Started LSB: NFC daemon. root@iniza:~# nfctool --list nfc0: Tags: [ tag0 ] Devices: [ ] Protocols: [ Felica MIFARE Jewel ISO-DEP NFC-DEP ] Powered: Yes RF Mode: Initiator lto: 150 rw: 15 miux: 2047 root@iniza:~# nfctool --poll -d nfc0 Start polling on nfc0 as initiator Targets found for nfc0 Tags: [ tag1 ] Devices: [ ] Thanks to all involved people. Please, feel free to add any credits you think are appropriate. A big Thank you from North-West Germany. Regards, - Sedat - [1] https://patchwork.kernel.org/patch/10339089/ > In v2: > - added new ID patch > - added new clean up patch > - Cc'ed to linux-wireless@ as well, since linux-nfc@ bounces my mails > - Cc'ed to the reported of the problem with T470 laptop > > Andy Shevchenko (12): > NFC: nxp-nci: Add NXP1001 to the ACPI ID table > NFC: nxp-nci: Get rid of platform data > NFC: nxp-nci: Convert to use GPIO descriptor > NFC: nxp-nci: Add GPIO ACPI mapping table > NFC: nxp-nci: Get rid of code duplication in ->probe() > NFC: nxp-nci: Get rid of useless label > NFC: nxp-nci: Constify acpi_device_id > NFC: nxp-nci: Drop of_match_ptr() use > NFC: nxp-nci: Drop comma in terminator lines > NFC: nxp-nci: Remove unused macro pr_fmt() > NFC: nxp-nci: Remove 'default n' for tests > NFC: nxp-nci: Convert to SPDX license tags > > MAINTAINERS | 1 - > drivers/nfc/nxp-nci/Kconfig | 1 - > drivers/nfc/nxp-nci/core.c | 15 +-- > drivers/nfc/nxp-nci/firmware.c | 13 +-- > drivers/nfc/nxp-nci/i2c.c | 147 ++++++-------------------- > drivers/nfc/nxp-nci/nxp-nci.h | 1 - > include/linux/platform_data/nxp-nci.h | 27 ----- > 7 files changed, 37 insertions(+), 168 deletions(-) > delete mode 100644 include/linux/platform_data/nxp-nci.h > > -- > 2.20.1 >