[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CALzBnUEe5cp1672OSywK1w_cP--+731tKDbOmqjBt2NghK2OGw@mail.gmail.com>
Date: Wed, 3 Sep 2025 12:47:32 -0400
From: RD Babiera <rdbabiera@...gle.com>
To: Heikki Krogerus <heikki.krogerus@...ux.intel.com>
Cc: gregkh@...uxfoundation.org, badhri@...gle.com, linux-usb@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1 1/2] usb: typec: class: add typec_get_data_role symbol
On Thu, Aug 28, 2025 at 5:44 AM Heikki Krogerus
<heikki.krogerus@...ux.intel.com> wrote:
> > Alt Mode drivers are responsible for sending Enter Mode through the TCPM,
> > but only a DFP is allowed to send Enter Mode. typec_get_data_role gets
> > the port's data role, which can then be used in altmode drivers via
> > typec_altmode_get_data_role to know if Enter Mode should be sent.
> The functions are okay by me, but is the above statement correct?
> Are you mixing power role and data role?
The PD Specification lists the DFP as being the USB host when USB
Communication is supported while acting as a DFP; it gives
a charger being a DFP and not supporting USB Communication as an
example.
> > @@ -172,6 +172,18 @@ typec_altmode_get_svdm_version(struct typec_altmode *altmode)
> > return typec_get_negotiated_svdm_version(typec_altmode2port(altmode));
> > }
> >
> > +/**
> > + * typec_altmode_get_data_role - Get port data role. Alt Mode drivers should only
> > + * issue Enter Mode through the port if they are the DFP.
>
> The second sentence should go below. But I'm not sure it's correct.
The kernel-doc comment guide agrees with that statement. I'll change it,
thanks for the heads up!
---
RD
Powered by blists - more mailing lists