[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACeCKadwa4-xOrihjv-6mkxxFtR5VeFuExP48hTrmteXw=fr9w@mail.gmail.com>
Date: Thu, 22 Oct 2020 11:18:49 -0700
From: Prashant Malani <pmalani@...omium.org>
To: Heikki Krogerus <heikki.krogerus@...ux.intel.com>
Cc: Greg KH <gregkh@...uxfoundation.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
"open list:USB NETWORKING DRIVERS" <linux-usb@...r.kernel.org>,
Benson Leung <bleung@...omium.org>
Subject: Re: [PATCH v2] usb: typec: Expose Product Type VDOs via sysfs
Hi Heikki,
Thanks for your feedback.
On Thu, Oct 22, 2020 at 5:43 AM Heikki Krogerus
<heikki.krogerus@...ux.intel.com> wrote:
>
> On Thu, Oct 22, 2020 at 12:25:07AM -0700, Prashant Malani wrote:
> > Hi Greg,
> >
> > On Thu, Oct 22, 2020 at 12:17 AM Greg KH <gregkh@...uxfoundation.org> wrote:
> > >
> > > Given that your current implementation is not acceptable, something has
> > > to change :)
> >
> > Got it. I'd like to see if Heikki has any suggestions on naming these
> > entries better.
>
> Why not have product type specific attribute files?
>
> So if the partner is UFP, then we expose ufp1 and ufp2 files that
> return the UFP1 and UFP2 VDO values and hide the other files:
>
> % ls /sys/class/typec/port0-partner/identity/
> id_header cert_stat product ufp1 ufp2
>
> If the partner is DFP, then you expose the dfp file and hide
> everything else:
>
> % ls /sys/class/typec/port0-partner/identity/
> id_header cert_stat product dfp
>
> And so on.
>
Makes sense, thanks! The only query I have here is , does the kernel
*need* to implement this logic? Userspace can read id_header VDO and
figure this on its own (parse the Product Type specific VDOs
accordingly).
Apart from that, I can work on implementing this if there are no concerns.
Best regards,
> thanks,
>
> --
> heikki
Powered by blists - more mailing lists