1. 14 11月, 2019 5 次提交
  2. 13 11月, 2019 2 次提交
  3. 11 11月, 2019 3 次提交
  4. 07 11月, 2019 22 次提交
  5. 05 11月, 2019 7 次提交
  6. 04 11月, 2019 1 次提交
    • H
      usb: typec: ucsi: Simplified registration and I/O API · bdc62f2b
      Heikki Krogerus 提交于
      Adding more simplified API for interface registration and
      read and write operations.
      
      The registration is split into separate creation and
      registration phases. That allows the drivers to properly
      initialize the interface before registering it if necessary.
      
      The read and write operations are supplied in a completely
      separate struct ucsi_operations that is passed to the
      ucsi_register() function during registration. The new read
      and write operations will work more traditionally so that
      the read callback function reads a requested amount of data
      from an offset, and the write callback functions write the
      given data to the offset. The drivers will have to support
      both non-blocking writing and blocking writing. In blocking
      writing the driver itself is responsible of waiting for the
      completion event.
      
      The new API makes it possible for the drivers to perform
      tasks also independently of the core ucsi.c, and that should
      allow for example quirks to be handled completely in the
      drivers without the need to touch ucsi.c.
      
      The old API is kept until all drivers have been converted to
      the new API.
      Signed-off-by: NHeikki Krogerus <heikki.krogerus@linux.intel.com>
      Tested-by: NAjay Gupta <ajayg@nvidia.com>
      Reviewed-by: NGuenter Roeck <linux@roeck-us.net>
      Link: https://lore.kernel.org/r/20191104142435.29960-12-heikki.krogerus@linux.intel.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      bdc62f2b