mbox series

[v4,00/18] usb: typec: API improvements

Message ID 20191104142435.29960-1-heikki.krogerus@linux.intel.com (mailing list archive)
Headers show
Series usb: typec: API improvements | expand

Message

Heikki Krogerus Nov. 4, 2019, 2:24 p.m. UTC
Hi,

I removed the extra error messages from ucsi_acpi.c and ucsi_ccg.c as
requested by Guenter.

The cover letter from v2:

I modified ucsi_acpi.c so that the behavior matches exactly the
behaviour of the Connector Change Event handling before these patches.

The cover letter from v2:

There is now a check in ucsi_exec_command() that makes sure we do not
call ucsi_read_error() with UCSI_GET_ERROR_STATUS command. That should
prevent endless recursion from happening.

The original cover letter:

The first patches in this series (patches 1-8) introduce a small
change to the USB Type-C Connector Class API. Guenter was kind enough
to go over those already.

Patches 10-15 improve the ucsi driver API by introducing more
traditional read and write routines, and the rest is more generic
optimisations and improvements to the ucsi drivers.

Let me know if there is anything you want to be changed.

thanks,

Heikki Krogerus (18):
  usb: typec: Copy everything from struct typec_capability during
    registration
  usb: typec: Introduce typec_get_drvdata()
  usb: typec: Separate the operations vector
  usb: typec: tcpm: Start using struct typec_operations
  usb: typec: tps6598x: Start using struct typec_operations
  usb: typec: ucsi: Start using struct typec_operations
  usb: typec: hd3ss3220: Start using struct typec_operations
  usb: typec: Remove the callback members from struct typec_capability
  usb: typec: Remove unused members from struct typec_capability
  usb: typec: hd3ss3220: Give the connector fwnode to the port device
  usb: typec: ucsi: Simplified registration and I/O API
  usb: typec: ucsi: acpi: Move to the new API
  usb: typec: ucsi: ccg: Move to the new API
  usb: typec: ucsi: Remove the old API
  usb: typec: ucsi: Remove struct ucsi_control
  usb: typec: ucsi: Remove all bit-fields
  usb: typec: ucsi: New error codes
  usb: typec: ucsi: Optimise ucsi_unregister()

 drivers/usb/typec/class.c            |  42 +-
 drivers/usb/typec/hd3ss3220.c        |  36 +-
 drivers/usb/typec/tcpm/tcpm.c        |  45 +-
 drivers/usb/typec/tps6598x.c         |  49 ++-
 drivers/usb/typec/ucsi/displayport.c |  40 +-
 drivers/usb/typec/ucsi/trace.c       |  11 -
 drivers/usb/typec/ucsi/trace.h       |  79 +---
 drivers/usb/typec/ucsi/ucsi.c        | 609 ++++++++++++++-------------
 drivers/usb/typec/ucsi/ucsi.h        | 417 +++++++-----------
 drivers/usb/typec/ucsi/ucsi_acpi.c   |  91 +++-
 drivers/usb/typec/ucsi/ucsi_ccg.c    | 166 ++++----
 include/linux/usb/typec.h            |  41 +-
 12 files changed, 770 insertions(+), 856 deletions(-)

Comments

Greg Kroah-Hartman Nov. 4, 2019, 3:05 p.m. UTC | #1
On Mon, Nov 04, 2019 at 05:24:17PM +0300, Heikki Krogerus wrote:
> Hi,
> 
> I removed the extra error messages from ucsi_acpi.c and ucsi_ccg.c as
> requested by Guenter.

I've applied the first 11 patches now, as it looks like Guenter wanted a
better comment in patch 12 :(

Feel free to rebase and resend the remaining as a new series.

thanks,

greg k-h
Guenter Roeck Nov. 4, 2019, 6:53 p.m. UTC | #2
On Mon, Nov 04, 2019 at 04:05:24PM +0100, Greg Kroah-Hartman wrote:
> On Mon, Nov 04, 2019 at 05:24:17PM +0300, Heikki Krogerus wrote:
> > Hi,
> > 
> > I removed the extra error messages from ucsi_acpi.c and ucsi_ccg.c as
> > requested by Guenter.
> 
> I've applied the first 11 patches now, as it looks like Guenter wanted a
> better comment in patch 12 :(
> 
Sounds like I am too picky. Feel free to ignore and go ahead.  
FTR, I'll send a Reviewed-by: for that patch.

Guenter
Greg Kroah-Hartman Nov. 4, 2019, 8:53 p.m. UTC | #3
On Mon, Nov 04, 2019 at 10:53:33AM -0800, Guenter Roeck wrote:
> On Mon, Nov 04, 2019 at 04:05:24PM +0100, Greg Kroah-Hartman wrote:
> > On Mon, Nov 04, 2019 at 05:24:17PM +0300, Heikki Krogerus wrote:
> > > Hi,
> > > 
> > > I removed the extra error messages from ucsi_acpi.c and ucsi_ccg.c as
> > > requested by Guenter.
> > 
> > I've applied the first 11 patches now, as it looks like Guenter wanted a
> > better comment in patch 12 :(
> > 
> Sounds like I am too picky. Feel free to ignore and go ahead.  
> FTR, I'll send a Reviewed-by: for that patch.

Fair enough, thanks for this, I'll go queue up the rest now.

greg k-h
Greg Kroah-Hartman Nov. 4, 2019, 8:54 p.m. UTC | #4
On Mon, Nov 04, 2019 at 04:05:24PM +0100, Greg Kroah-Hartman wrote:
> On Mon, Nov 04, 2019 at 05:24:17PM +0300, Heikki Krogerus wrote:
> > Hi,
> > 
> > I removed the extra error messages from ucsi_acpi.c and ucsi_ccg.c as
> > requested by Guenter.
> 
> I've applied the first 11 patches now, as it looks like Guenter wanted a
> better comment in patch 12 :(

Oh, and very nice work.  thanks for doing this.

greg k-h