From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752719AbcFVOmY (ORCPT ); Wed, 22 Jun 2016 10:42:24 -0400 Received: from mga03.intel.com ([134.134.136.65]:58431 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752190AbcFVOmW (ORCPT ); Wed, 22 Jun 2016 10:42:22 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.26,509,1459839600"; d="scan'208";a="981168752" Date: Wed, 22 Jun 2016 17:38:03 +0300 From: Heikki Krogerus To: Oliver Neukum Cc: Felipe Balbi , Greg KH , Guenter Roeck , linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org Subject: Re: [PATCHv3 1/2] usb: USB Type-C connector class Message-ID: <20160622143803.GG19856@kuha.fi.intel.com> References: <1466520711-125758-1-git-send-email-heikki.krogerus@linux.intel.com> <1466520711-125758-2-git-send-email-heikki.krogerus@linux.intel.com> <1466540705.2014.11.camel@suse.com> <20160622095016.GB19856@kuha.fi.intel.com> <1466590495.12516.10.camel@suse.com> <20160622114458.GF19856@kuha.fi.intel.com> <1466603223.16513.2.camel@suse.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1466603223.16513.2.camel@suse.com> User-Agent: Mutt/1.6.1 (2016-04-27) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 22, 2016 at 03:47:03PM +0200, Oliver Neukum wrote: > On Wed, 2016-06-22 at 14:44 +0300, Heikki Krogerus wrote: > > If our port is DRD (which would be DRP in the port controller spec), > > the supported_power_roles will list: > > > > device, host > > > > And the power role, if the port is Source only, the > > supported_power_roles will list: > > > > source > > > > If the port is Sink only, the supported_power_roles will list: > > > > sink > > > > If our port is DRP, the supported_power_roles will list: > > > > source, sink > > > > What is there that is missing? We are able to express all the types of > > "Roles Supported" that the DEVICE_CAPABILITIES define, no? > > No, because these are distinct in time. Some ports are DRP so they > support > > device, host > > at the same time. Some ports can be switched between DFP and UFP > they then either support host or device. But you lose the information > that the ports can be switched. You can't ever be host and device at the same time. Just like you can't ever be source and sink at the same time. Are we now talking about how should a port be advertised to the partners? So basically, do you want to be able to program the port to be DFP only, UFP only or DRP from user space? Thanks, -- heikki