Linux USB
 help / color / mirror / Atom feed
From: Heikki Krogerus <heikki.krogerus@linux.intel.com>
To: Abhishek Pandit-Subedi <abhishekpandit@chromium.org>
Cc: Jameson Thies <jthies@google.com>,
	Benson Leung <bleung@chromium.org>,
	Bartosz Szpila <bszpila@google.com>,
	"Pilla, Siva sai kumar" <siva.sai.kumar.pilla@intel.com>,
	linux-usb@vger.kernel.org
Subject: [RFC PATCH 0/3] usb: typec: ucsi: New way to handle GET_CONNECTOR_STATUS
Date: Wed, 28 Aug 2024 19:14:58 +0300	[thread overview]
Message-ID: <20240828161502.2774996-1-heikki.krogerus@linux.intel.com> (raw)

Hi,

I'm getting rid of only struct ucsi_connector_status, but my plan is
to remove all command specific data structures that don't align
naturally unless there are strong objections against it. Ideally we
could use bitfields - that way using those structures would not be a
problem - but I guess we still can't.

So UCSI_FIELD() is a hack, and may be replaced in the end, but it
works. I need to check if we can use bitmaps instead, but I did not
get that far yet.

The last patch is probable the one that you are really interested in.
Let me know what you think.

thanks,

Heikki Krogerus (3):
  usb: typec: ucsi: Helper for Get Connector Status command
  usb: typec: ucsi: Remove struct ucsi_connector_status
  usb: typec: ucsi: Helpers for new GET_CONNECTOR_STATUS fields

 drivers/usb/typec/ucsi/psy.c       |  28 +++----
 drivers/usb/typec/ucsi/trace.h     |  22 ++---
 drivers/usb/typec/ucsi/ucsi.c      | 110 ++++++++++++-------------
 drivers/usb/typec/ucsi/ucsi.h      | 128 +++++++++++++++++++++++------
 drivers/usb/typec/ucsi/ucsi_acpi.c |   7 +-
 5 files changed, 179 insertions(+), 116 deletions(-)

-- 
2.45.2


             reply	other threads:[~2024-08-28 16:15 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-28 16:14 Heikki Krogerus [this message]
2024-08-28 16:14 ` [RFC PATCH 1/3] usb: typec: ucsi: Helper for Get Connector Status command Heikki Krogerus
2024-08-28 16:15 ` [RFC PATCH 2/3] usb: typec: ucsi: Remove struct ucsi_connector_status Heikki Krogerus
2024-08-29 21:37   ` Abhishek Pandit-Subedi
2024-08-28 16:15 ` [RFC PATCH 3/3] usb: typec: ucsi: Helpers for new GET_CONNECTOR_STATUS fields Heikki Krogerus
2024-08-28 23:54   ` Pilla, Siva sai kumar
2024-08-29  6:43     ` Heikki Krogerus
2024-08-29 21:49   ` Abhishek Pandit-Subedi
2024-08-30  8:37     ` Heikki Krogerus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240828161502.2774996-1-heikki.krogerus@linux.intel.com \
    --to=heikki.krogerus@linux.intel.com \
    --cc=abhishekpandit@chromium.org \
    --cc=bleung@chromium.org \
    --cc=bszpila@google.com \
    --cc=jthies@google.com \
    --cc=linux-usb@vger.kernel.org \
    --cc=siva.sai.kumar.pilla@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox