From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752915AbcFBGiI (ORCPT ); Thu, 2 Jun 2016 02:38:08 -0400 Received: from bh-25.webhostbox.net ([208.91.199.152]:55704 "EHLO bh-25.webhostbox.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751049AbcFBGiF (ORCPT ); Thu, 2 Jun 2016 02:38:05 -0400 Subject: Re: [RFC PATCHv2] usb: USB Type-C Connector Class To: Oliver Neukum References: <1463661894-22820-1-git-send-email-heikki.krogerus@linux.intel.com> <20160530131951.GA13055@kuha.fi.intel.com> <1464616767.5364.5.camel@suse.com> <20160531083121.GA10084@kuha.fi.intel.com> <1464684509.10800.16.camel@suse.com> <20160531120901.GB10084@kuha.fi.intel.com> <20160531124355.GC10084@kuha.fi.intel.com> <20160531172033.GB14007@roeck-us.net> <20160601082336.GE10084@kuha.fi.intel.com> <1464771866.4051.4.camel@suse.com> <574EE452.3000805@roeck-us.net> <1464848668.8527.2.camel@suse.com> Cc: Heikki Krogerus , Andy Shevchenko , Rajaram R , Felipe Balbi , Mathias Nyman , Greg KH , linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org From: Guenter Roeck Message-ID: <574FD43E.9080305@roeck-us.net> Date: Wed, 1 Jun 2016 23:37:50 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 MIME-Version: 1.0 In-Reply-To: <1464848668.8527.2.camel@suse.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Authenticated_sender: linux@roeck-us.net X-OutGoing-Spam-Status: No, score=-1.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - bh-25.webhostbox.net X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - roeck-us.net X-Get-Message-Sender-Via: bh-25.webhostbox.net: authenticated_id: linux@roeck-us.net X-Authenticated-Sender: bh-25.webhostbox.net: linux@roeck-us.net X-Source: X-Source-Args: X-Source-Dir: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 06/01/2016 11:24 PM, Oliver Neukum wrote: > On Wed, 2016-06-01 at 06:34 -0700, Guenter Roeck wrote: >> The class code would not explicitly learn about the reset, >> but it would be informed about the exited modes. > > That has drawbacks > Playing devils advocate a bit here > - it doesn't tell you what caused the mode to be left (if you > UFP, it may be the regular command) Does it matter ? > - it is a race against your own command It is my understanding that races have to be resolved by the drivers, since the typec code does not do any locking. This is quite similar to handling, say, a request to change the vconn source or to change the power role. Am I missing something ? > - it does not work if you are in basic USB mode > Would alternate modes be active in that case ? Thanks, Guenter