1. 30 Nov, 2017 1 commit
  2. 27 Jul, 2017 1 commit
    • Johan Hovold's avatar
      NFC: fix broken device allocation · f73de3f9
      Johan Hovold authored
      commit 20777bc5 upstream.
      
      Commit 7eda8b8e ("NFC: Use IDR library to assing NFC devices IDs")
      moved device-id allocation and struct-device initialisation from
      nfc_allocate_device() to nfc_register_device().
      
      This broke just about every nfc-device-registration error path, which
      continue to call nfc_free_device() that tries to put the device
      reference of the now uninitialised (but zeroed) struct device:
      
      kobject: '(null)' (ce316420): is not initialized, yet kobject_put() is being called.
      
      The late struct-device initialisation also meant that various work
      queues whose names are derived from the nfc device name were also
      misnamed:
      
        421 root         0 SW<  [(null)_nci_cmd_]
        422 root         0 SW<  [(null)_nci_rx_w]
        423 root         0 SW<  [(null)_nci_tx_w]
      
      Move the id-allocation and struct-device initialisation back to
      nfc_allocate_device() and fix up the single call site which did not use
      nfc_free_device() in its error path.
      
      Fixes: 7eda8b8e ("NFC: Use IDR library to assing NFC devices IDs")
      Cc: Samuel Ortiz <sameo@linux.intel.com>
      Signed-off-by: 's avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: 's avatarSamuel Ortiz <sameo@linux.intel.com>
      Signed-off-by: 's avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      f73de3f9
  3. 29 Dec, 2015 1 commit
  4. 27 Oct, 2015 1 commit
  5. 02 Feb, 2015 1 commit
  6. 26 Jan, 2015 2 commits
  7. 14 Mar, 2014 2 commits
  8. 23 Feb, 2014 1 commit
  9. 04 Jan, 2014 2 commits
    • Samuel Ortiz's avatar
      NFC: Only warn on SE discovery error · a434c240
      Samuel Ortiz authored
      SE discovery errors are currently overwriting the dev_up() return error.
      This is wrong for many reasons:
      
      - We don't want to report an error if we actually brought the device up
        but it failed to discover SEs. By doing so we pretend we don't have an
        NFC functional device even we do. The only thing we could not do was
        checking for SEs availability. This is the false negative case.
      
      - In some cases the actual device power up failed but the SE discovery
        succeeded. Userspace then believes the device is up while it's not.
        This is the false positive case.
      Signed-off-by: 's avatarSamuel Ortiz <sameo@linux.intel.com>
      a434c240
    • Arron Wang's avatar
      NFC: Fix target mode p2p link establishment · d31652a2
      Arron Wang authored
      With commit e29a9e2a, we set the active_target pointer from
      nfc_dep_link_is_up() in order to support the case where the target
      detection and the DEP link setting are done atomically by the driver.
      That can only happen in initiator mode, so we need to check for that
      otherwise we fail to bring a p2p link in target mode.
      Signed-off-by: 's avatarArron Wang <arron.wang@intel.com>
      Signed-off-by: 's avatarSamuel Ortiz <sameo@linux.intel.com>
      d31652a2
  10. 11 Dec, 2013 1 commit
  11. 24 Sep, 2013 2 commits
  12. 13 Aug, 2013 4 commits
  13. 30 Jul, 2013 1 commit
  14. 14 Jun, 2013 6 commits
  15. 13 Jun, 2013 1 commit
    • Eric Lapuyade's avatar
      NFC: Add firmware upload netlink command · 9674da87
      Eric Lapuyade authored
      As several NFC chipsets can have their firmwares upgraded and
      reflashed, this patchset adds a new netlink command to trigger
      that the driver loads or flashes a new firmware. This will allows
      userspace triggered firmware upgrade through netlink.
      The firmware name or hint is passed as a parameter, and the driver
      will eventually fetch the firmware binary through the request_firmware
      API.
      The cmd can only be executed when the nfc dev is not in use. Actual
      firmware loading/flashing is an asynchronous operation. Result of the
      operation shall send a new event up to user space through the nfc dev
      multicast socket. During operation, the nfc dev is not openable and
      thus not usable.
      Signed-off-by: 's avatarEric Lapuyade <eric.lapuyade@intel.com>
      Signed-off-by: 's avatarSamuel Ortiz <sameo@linux.intel.com>
      9674da87
  16. 12 Apr, 2013 1 commit
  17. 11 Apr, 2013 1 commit
  18. 06 Feb, 2013 1 commit
  19. 09 Jan, 2013 2 commits
  20. 26 Oct, 2012 4 commits
  21. 02 Oct, 2012 1 commit
    • Linus Torvalds's avatar
      workqueue: avoid using deprecated functions · 916082b0
      Linus Torvalds authored
      The network merge brought in a few users of functions that got
      deprecated by the workqueue cleanups: the 'system_nrt_wq' is now the
      same as the regular system_wq, since all workqueues are now non-
      reentrant.
      
      Similarly, remove one use of flush_work_sync() - the regular
      flush_work() has become synchronous, and the "_sync()" version is thus
      deprecated as being superfluous.
      Signed-off-by: 's avatarLinus Torvalds <torvalds@linux-foundation.org>
      916082b0
  22. 24 Sep, 2012 1 commit
    • Tejun Heo's avatar
      NFC: Use system_nrt_wq instead of custom ones · 474fee3d
      Tejun Heo authored
      NFC is using a number of custom ordered workqueues w/ WQ_MEM_RECLAIM.
      WQ_MEM_RECLAIM is unnecessary unless NFC is gonna be used as transport
      for storage device, and all use cases match one work item to one
      ordered workqueue - IOW, there's no actual ordering going on at all
      and using system_nrt_wq gives the same behavior.
      
      There's nothing to be gained by using custom workqueues.  Use
      system_nrt_wq instead and drop all the custom ones.
      Signed-off-by: 's avatarTejun Heo <tj@kernel.org>
      Signed-off-by: 's avatarSamuel Ortiz <sameo@linux.intel.com>
      474fee3d
  23. 09 Jul, 2012 2 commits