Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751363AbdGQRSw (ORCPT ); Mon, 17 Jul 2017 13:18:52 -0400 Received: from mail-pg0-f67.google.com ([74.125.83.67]:33030 "EHLO mail-pg0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751293AbdGQRSu (ORCPT ); Mon, 17 Jul 2017 13:18:50 -0400 Date: Mon, 17 Jul 2017 12:18:47 -0500 From: Rob Herring To: Stephen Boyd Cc: Andy Gross , Peter Chen , Peter Rosin , linux-usb@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Rob Clark , Greg Kroah-Hartman Subject: Re: [PATCH 0/3] USB Mux support for Chipidea Message-ID: <20170717171847.7jnkw5hf4wbh7up7@rob-hp-laptop> References: <20170712010255.26855-1-stephen.boyd@linaro.org> <149998530228.4532.1798948469358915658@sboyd-linaro> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <149998530228.4532.1798948469358915658@sboyd-linaro> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2199 Lines: 51 On Thu, Jul 13, 2017 at 03:35:02PM -0700, Stephen Boyd wrote: > Quoting Peter Rosin (2017-07-11 22:04:46) > > On 2017-07-12 03:02, Stephen Boyd wrote: > > > This patchset adds support for the TC7USB40MU usb mux found on > > > db410c 96boards platforms via the new multiplexer framework and > > > hooks that into the chipidea driver. This allows us to properly > > > control host or device mode on this board via the sysfs knob. > > > > > > So far I've only tested this on db410c, and there are some rough > > > edges to finish off before it can merge. Also I'm experiencing > > > odd behavior with switching the role while gadget is enabled and > > > the micro-usb cable is kept connected. Not sure what's wrong but > > > it seems like the gadget never gets disconnected? I'll investigate > > > more. > > > > > > TODO: > > > > > > 1. The mux framework has to be selected for consumers to use it. We'll > > > need some stubs in the consumer header file to allow compilation to > > > continue without mux always enabled by consumers. > > > > Instead of "depends on MULTIPLEXER", just add "select MULTIPLEXER" > > to the Kconfig. Otherwise, you'll have to convince Linus that we > > really do need a Kconfig question for the subsystem :-) > > > > https://lkml.org/lkml/2017/7/4/118 > > Ok. I'll add a select to the chipidea driver. > > > > > > 2. We probably need some sort of mux_control_get_optional() API so that > > > we know if there was an error getting the mux control, instead of just > > > ignoring errors. For now I can pass up EPROBE_DEFER errors and ignore > > > other errors and consider it "missing from DT". > > > > Yes, mux_control_get_optional should be easy to add. > > > > > 3. Maybe we can get rid of the mux driver and just use mux-gpio.c with > > > a compatible string update? I split it off because we may want to > > > support the "S" pin on the TC7USB40MU one day that shuts off both > > Oh this is a typo. I mean "OE" pin. > > > > mux outputs. > > > > Maybe no need for a compatible update either, if it works to do something > > like this in the DT? Please keep the compatible. Use "gpio-mux" as a fallback if you wish. Rob