All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/7] typec: tcpm: Add sink side support for PPS
@ 2018-01-02 15:50 ` Adam Thomson
  0 siblings, 0 replies; 67+ messages in thread
From: Adam Thomson @ 2018-01-02 15:50 UTC (permalink / raw)
  To: Heikki Krogerus, Guenter Roeck, Greg Kroah-Hartman,
	Sebastian Reichel, Hans de Goede, Yueyao Zhu, Rui Miguel Silva
  Cc: linux-usb, linux-pm, linux-kernel, support.opensource

This patch set adds sink side support for the PPS feature introduced in the
USB PD 3.0 specification.

The source PPS supply is represented using the Power Supply framework to provide
access and control APIs for dealing with it's operating voltage and current,
and switching between a standard PDO and PPS APDO operation. During standard PDO
operation the voltage and current is read-only, but for APDO PPS these are
writable as well to allow for control.

It should be noted that the keepalive for PPS is not handled within TCPM. The
expectation is that the external user will be required to ensure re-requests
occur regularly to ensure PPS remains and the source does not hard reset.

Changes in v4:
 - For PD 3.0 definitions patch, make it benign with regards to existing TCPM
   code so build isn't broken if this one patch is applied, as suggested by
   kbuild robot. Update for dynamic revision is moved to be part of sink side
   PPS support patch.
 - Use PTR_ERR_OR_ZERO macro to simplify return of devm_tcpm_psy_register()
   function, as suggested by kbuild robot.
 - Make devm_tcpm_psy_register() static as not used outside this file.

Changes in v3:
 - Drop 'RFC' from patch series titles
 - Rename PPS related defines to be PPS specific rather than generic APDO titles
 - Update source caps logging to only print PPS APDOs, and for others report as
   undefined.
 - Add ABI documentation for tcpm-source-psy sysfs properties
 - Rebase PDO selection on top of 'typec: tcpm: Only request matching pdos'
   patch.
 - Update capabilities validation introduced in
   'typec: tcpm: Validate source and sink caps' to support PPS APDOs.
 - Dropped power_supply 'type' property update for PPS addition
 - Added 'connected_type' property to power_supply framework, to support
   supplies which can report multiple connected types (e.g. USB), as discussed
   with Heikki.

Changes in v2:
 - Use USB_PD and usb_pd prefixes for macros and inline functions in headers.
 - Negotiate spec revision of PD headers during initial contract agreement.
 - New headers now use SPDX tags for referencing correct license.

NOTE: Code changes are based on linux-next tag 'next-20171212' to pick up
capabilities validation and selection updates.

Adam Thomson (7):
  typec: tcpm: Add PD Rev 3.0 definitions to PD header
  typec: tcpm: Add ADO header for Alert message handling
  typec: tcpm: Add SDB header for Status message handling
  typec: tcpm: Add core support for sink side PPS
  power: supply: Add 'connected_type' property and supporting code
  typec: tcpm: Represent source supply through power_supply class
  typec: tcpm: Add support for sink PPS related messages

 .../ABI/testing/sysfs-class-power-tcpm-source-psy  |  92 +++
 drivers/power/supply/power_supply_sysfs.c          |  50 ++
 drivers/usb/typec/Kconfig                          |   1 +
 drivers/usb/typec/fusb302/Kconfig                  |   2 +-
 drivers/usb/typec/fusb302/fusb302.c                |  63 +-
 drivers/usb/typec/tcpm.c                           | 916 ++++++++++++++++++++-
 include/linux/power_supply.h                       |  15 +
 include/linux/usb/pd.h                             | 187 ++++-
 include/linux/usb/pd_ado.h                         |  42 +
 include/linux/usb/pd_ext_sdb.h                     |  31 +
 include/linux/usb/tcpm.h                           |   2 +-
 11 files changed, 1306 insertions(+), 95 deletions(-)
 create mode 100644 Documentation/ABI/testing/sysfs-class-power-tcpm-source-psy
 create mode 100644 include/linux/usb/pd_ado.h
 create mode 100644 include/linux/usb/pd_ext_sdb.h

-- 
1.9.1

^ permalink raw reply	[flat|nested] 67+ messages in thread

end of thread, other threads:[~2018-03-19 10:39 UTC | newest]

Thread overview: 67+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-02 15:50 [PATCH v4 0/7] typec: tcpm: Add sink side support for PPS Adam Thomson
2018-01-02 15:50 ` Adam Thomson
2018-01-02 15:50 ` [PATCH v4 1/7] typec: tcpm: Add PD Rev 3.0 definitions to PD header Adam Thomson
2018-01-02 15:50   ` Adam Thomson
2018-01-02 15:50   ` [v4,1/7] " Opensource [Adam Thomson]
2018-01-30 12:21   ` [PATCH v4 1/7] " Heikki Krogerus
2018-01-30 12:21     ` [v4,1/7] " Heikki Krogerus
2018-02-06 14:14     ` [PATCH v4 1/7] " Adam Thomson
2018-02-06 14:14       ` [v4,1/7] " Opensource [Adam Thomson]
2018-01-02 15:50 ` [PATCH v4 2/7] typec: tcpm: Add ADO header for Alert message handling Adam Thomson
2018-01-02 15:50   ` Adam Thomson
2018-01-02 15:50   ` [v4,2/7] " Opensource [Adam Thomson]
2018-01-30 12:22   ` [PATCH v4 2/7] " Heikki Krogerus
2018-01-30 12:22     ` [v4,2/7] " Heikki Krogerus
2018-01-02 15:50 ` [PATCH v4 3/7] typec: tcpm: Add SDB header for Status " Adam Thomson
2018-01-02 15:50   ` Adam Thomson
2018-01-02 15:50   ` [v4,3/7] " Opensource [Adam Thomson]
2018-01-30 12:22   ` [PATCH v4 3/7] " Heikki Krogerus
2018-01-30 12:22     ` Heikki Krogerus
2018-01-30 12:22     ` [v4,3/7] " Heikki Krogerus
2018-01-02 15:50 ` [PATCH v4 4/7] typec: tcpm: Add core support for sink side PPS Adam Thomson
2018-01-02 15:50   ` Adam Thomson
2018-01-02 15:50   ` [v4,4/7] " Opensource [Adam Thomson]
2018-01-30 12:46   ` [PATCH v4 4/7] " Heikki Krogerus
2018-01-30 12:46     ` [v4,4/7] " Heikki Krogerus
2018-02-06 14:33     ` [PATCH v4 4/7] " Adam Thomson
2018-02-06 14:33       ` [v4,4/7] " Opensource [Adam Thomson]
2018-02-06 14:53       ` [PATCH v4 4/7] " Heikki Krogerus
2018-02-06 14:53         ` [v4,4/7] " Heikki Krogerus
2018-01-02 15:50 ` [PATCH v4 5/7] power: supply: Add 'connected_type' property and supporting code Adam Thomson
2018-01-02 15:50   ` Adam Thomson
2018-01-02 15:50   ` [v4,5/7] " Opensource [Adam Thomson]
2018-01-30 12:54   ` [PATCH v4 5/7] " Heikki Krogerus
2018-01-30 12:54     ` [v4,5/7] " Heikki Krogerus
2018-02-08 21:30   ` [PATCH v4 5/7] " Sebastian Reichel
2018-02-08 21:30     ` [v4,5/7] " Sebastian Reichel
2018-02-09 11:28     ` [PATCH v4 5/7] " Adam Thomson
2018-02-09 11:28       ` [v4,5/7] " Opensource [Adam Thomson]
2018-02-09 15:01       ` [PATCH v4 5/7] " Sebastian Reichel
2018-02-09 15:01         ` [v4,5/7] " Sebastian Reichel
2018-02-09 15:43         ` [PATCH v4 5/7] " Adam Thomson
2018-02-09 15:43           ` [v4,5/7] " Opensource [Adam Thomson]
2018-01-02 15:50 ` [PATCH v4 6/7] typec: tcpm: Represent source supply through power_supply class Adam Thomson
2018-01-02 15:50   ` Adam Thomson
2018-01-02 15:50   ` [v4,6/7] " Opensource [Adam Thomson]
2018-01-30 13:11   ` [PATCH v4 6/7] " Heikki Krogerus
2018-01-30 13:11     ` [v4,6/7] " Heikki Krogerus
2018-02-06 15:51     ` [PATCH v4 6/7] " Adam Thomson
2018-02-06 15:51       ` [v4,6/7] " Opensource [Adam Thomson]
2018-02-08 10:45       ` [PATCH v4 6/7] " Heikki Krogerus
2018-02-08 10:45         ` [v4,6/7] " Heikki Krogerus
2018-02-09 16:06         ` [PATCH v4 6/7] " Adam Thomson
2018-02-09 16:06           ` [v4,6/7] " Opensource [Adam Thomson]
2018-01-02 15:50 ` [PATCH v4 7/7] typec: tcpm: Add support for sink PPS related messages Adam Thomson
2018-01-02 15:50   ` Adam Thomson
2018-01-02 15:50   ` [v4,7/7] " Opensource [Adam Thomson]
2018-01-30 13:18   ` [PATCH v4 7/7] " Heikki Krogerus
2018-01-30 13:18     ` [v4,7/7] " Heikki Krogerus
2018-01-22 14:31 ` [PATCH v4 0/7] typec: tcpm: Add sink side support for PPS Greg Kroah-Hartman
2018-01-22 14:31   ` Greg Kroah-Hartman
2018-01-22 15:57   ` Guenter Roeck
2018-01-30 13:25 ` Heikki Krogerus
2018-01-30 14:27   ` Guenter Roeck
2018-02-05 10:30   ` Adam Thomson
2018-03-09 17:33 ` Greg Kroah-Hartman
2018-03-12  8:32   ` Adam Thomson
2018-03-19 10:39     ` Adam Thomson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.