From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932512AbcBPNmY (ORCPT ); Tue, 16 Feb 2016 08:42:24 -0500 Received: from mx2.suse.de ([195.135.220.15]:56141 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932376AbcBPNmW (ORCPT ); Tue, 16 Feb 2016 08:42:22 -0500 Message-ID: <1455629987.4532.25.camel@suse.com> Subject: Re: [PATCH 2/3] usb: type-c: USB Type-C Connector System Software Interface From: Oliver Neukum To: Heikki Krogerus Cc: Felipe Balbi , Mathias Nyman , Greg KH , linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org Date: Tue, 16 Feb 2016 14:39:47 +0100 In-Reply-To: <20160216092238.GA18565@kuha.fi.intel.com> References: <1455037283-106479-1-git-send-email-heikki.krogerus@linux.intel.com> <1455037283-106479-3-git-send-email-heikki.krogerus@linux.intel.com> <20160209182155.GC31787@kroah.com> <20160210103042.GB5270@kuha.fi.intel.com> <20160210172035.GA28335@kroah.com> <20160211135011.GA32213@kuha.fi.intel.com> <1455550218.22176.11.camel@suse.com> <20160216092238.GA18565@kuha.fi.intel.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.12.11 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2016-02-16 at 11:22 +0200, Heikki Krogerus wrote: > > That question has not been answered. It would be awkward for the OS > > to find itself in the slave role, which it is ill equipped for. So > > the data role should be switched before the new device is announced > > to user space. How is that handled? > > In the class driver, once we add support for preselecting the role, > when the connection happens we compare the initial role to the > preselected one and execute swap if it differs. Only after that we > notify userspace. Yes, but we need an API. We can't keep adding to it. So if that is to be supported, it needs to be defined now. Regards Oliver