lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 26 Aug 2016 17:07:10 +0300
From:   Heikki Krogerus <heikki.krogerus@...ux.intel.com>
To:     Vincent Palatin <vpalatin@...omium.org>
Cc:     Greg KH <gregkh@...uxfoundation.org>,
        Guenter Roeck <linux@...ck-us.net>,
        Oliver Neukum <oneukum@...e.com>,
        Felipe Balbi <felipe.balbi@...ux.intel.com>,
        Bin Gao <bin.gao@...ux.intel.com>,
        linux-kernel@...r.kernel.org, linux-usb@...r.kernel.org
Subject: Re: [PATCHv6 1/3] usb: USB Type-C connector class

Hi Vincent,

On Fri, Aug 26, 2016 at 03:16:16PM +0200, Vincent Palatin wrote:
> >> > +What:          /sys/class/typec/<port>/current_vconn_role
> >> > +Date:          June 2016
> >> > +Contact:       Heikki Krogerus <heikki.krogerus@...ux.intel.com>
> >> > +Description:
> >> > +               Shows the current VCONN role of the port. This attribute can be
> >> > +               used to request VCONN role swap on the port when the port
> >> > +               supports USB Power Delivery.
> >> > +
> >> > +               Valid values are:
> >> > +               - source
> >> > +               - sink
> >>
> >>
> >> either we are currently sourcing vconn or not, but even if you are
> >> not, you are probably not a vconn sink either (ie only vconn-powered
> >> accessory are, your usual linux-powered laptop/phone is probably not)
> >
> > It's not relevant to know whether the vconn is being actually used or
> > not here. I'm not sure what's your point?
> 
> 
> My point was: saying we are a VCONN "sink" just because we are not
> currently sourcing vconn is usually not true.

OK, I understand your point now. You are correct. I think we need to
change this attribute and call it "vconn_source" that reports "1" or
"0".

I'll change that and send one more version of these on Monday
(hopefully the last one) unless somebody disagrees.

> >> > +What:          /sys/class/typec/<port>-partner/type
> >> > +Date:          June 2016
> >> > +Contact:       Heikki Krogerus <heikki.krogerus@...ux.intel.com>
> >> > +Description:
> >> > +               Shows the type of the partner. Can be one of the following:
> >> > +               - USB - When the partner is normal USB host/peripheral.
> >> > +               - Charger - When the partner has been identified as dedicated
> >> > +                           charger.
> >> > +               - Alternate Mode - When the partner supports Alternate Modes.
> >> > +               - Accessory - When the partner is one of the accessories with
> >> > +                             specific Accessory Mode defined in USB Type-C
> >> > +                             specification.
> >>
> >>
> >> where a dock would be classified ?
> >
> > A dock is just USB PD capable device with a bunch of alternate modes
> > that is attached to the port. There is no specific identifier for a
> > "dock".
> 
> My remark was a bit too stern,
> I meant a dock might be 'USB' 'Charger' 'Alternate Mode' , all at the
> same time or alternately depending what you plug in.
> I don't really see those types as mutually exclusive.

So USB type means the partner does not have alternate modes (I'll
clear that in the documentation), Charger is a dedicated charger and
therefore can not be anything else (no USB, no alternate modes).

To answer your original question, a dock would be reported as
Alternate Mode.


Thanks,

-- 
heikki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ