Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1696876pxb; Wed, 10 Feb 2021 14:40:17 -0800 (PST) X-Google-Smtp-Source: ABdhPJzsAZar6oEsD7Q4nDDW+Tis8JFR/DGZCGlhKFzl48hAd8lFVqXUKJ8D/ftLpKI5F09WTLdx X-Received: by 2002:a17:906:1389:: with SMTP id f9mr5279039ejc.442.1612996817762; Wed, 10 Feb 2021 14:40:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1612996817; cv=none; d=google.com; s=arc-20160816; b=WM+9BxMJpfgorlbUFD+RP77rD8ll+kYJdEWw2avP3TStuOAyNNsCSj9g7wMHfRMp9S LmWLGIayaZgtB+e0rprWf8IOSk6Kwhg8UDIkPx8D8U3ckyOWYtJg32d0wjJHWwAcFGNw ohPhblLqOf1DXmB0iIN0merAwfqZFgjz/AiZJVXEKRkTlcY6Lwjh8TsmnY5CdC7uiJsg eaaaF95NFUyMSn2d7cAEL0PSj/spI2adqNZ4umtJWcnoeUC8iZMBfTQ2jbWOi8kWDnm/ STxx+bNKfshAJ2dPVefyjslUdv/6utgoPymAwi7y4rbHqjQcn2iIWAFPH0mWx2bLsC0v jqQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=s90SilBQFi+ziwOIINhOeEY8oYLj+xr0s/beSIR3XzA=; b=NMleqnxqWuC/PVlzd5m6WTLyJS5m0kiTV/WnUdMYptnmNAZVBW4S+571UVKx2V/4ZL mPQ+qTcnL4r1aGnMUmLiMlnrxRUlmvuRW6v6f9Qz/llYGc1ztLC1VrofFEBa1kvBtJ8C DAKUr095fZHjuI3skN6oF3RmznBC+1WQvzsDC6k8+0k+iCO060SQqXA4kcI7Vf3h1GoU Lz5zHxqdO2GAmiUF5sIBx7LkNHi/4QT4N+DHRGiLvao5cEbuud2tls3V3BewpMLvxBf3 vTUfhnlIniKXcDVwGOiOGd7/p22wZ2RWOX3HTcI4nMSH85tjpW4G9zNoTsdvfksFcVwv rxxA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=MnEVVT6E; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a27si2366243ejc.18.2021.02.10.14.39.53; Wed, 10 Feb 2021 14:40:17 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=MnEVVT6E; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233713AbhBJWiU (ORCPT + 99 others); Wed, 10 Feb 2021 17:38:20 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33946 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232891AbhBJWiN (ORCPT ); Wed, 10 Feb 2021 17:38:13 -0500 Received: from mail-pf1-x436.google.com (mail-pf1-x436.google.com [IPv6:2607:f8b0:4864:20::436]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5C58CC061756 for ; Wed, 10 Feb 2021 14:37:33 -0800 (PST) Received: by mail-pf1-x436.google.com with SMTP id u143so2251609pfc.7 for ; Wed, 10 Feb 2021 14:37:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=s90SilBQFi+ziwOIINhOeEY8oYLj+xr0s/beSIR3XzA=; b=MnEVVT6ElZKR6HNoGnByOlde92Fc00O5NLMZG97kXOqfO9xJdd/lo+nOZrahuarmX4 VpRMSLM/1rx0YTuEN6S/wDCBZBx1OX/tF+6TJrlgVtxArkAUYjwv4gpdTc7RvK11vkhi bDep2WDFkBv5OrnATTrAr3VFk391/iVVMxyQA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=s90SilBQFi+ziwOIINhOeEY8oYLj+xr0s/beSIR3XzA=; b=gFnd912EFGEUCTd/DrfvTHfL3WVPnML9D++apmWeTu6z7r2yWvNkUwQUJNN0PVmBER CzLUXlV4+jgoZurbYOP9ow2sw1An9+BpQOphxabjYpsMlepbPeOymtlBdoSANItn5D9R dzOs+0Ema6GoGRRRWhXj4x+qFqJUGxGBtpeppyDhrY1P7CFpugm8wqzjRRMBcRt6RQFa KS+BHermrljpNBUPVy/AK9VXHyBwB6yNL4A56V/BXIIxeVTRJlXU9/2sfxaHI1FP2DTB RPM9QhU/rfEf1lmXqJuqa+XcUXH+VBmGM/lnNavwpP/As8MsizFjaDBVwWewTZBHYOWw QVXQ== X-Gm-Message-State: AOAM532PUN5mQrpY5wxvBv4vIgKKyZ1FckeA+NuY1cTiczZ229w9/tUk oRscH5a5kd4Io2m1XfJAt1kyyw== X-Received: by 2002:a63:4a49:: with SMTP id j9mr5225931pgl.197.1612996652851; Wed, 10 Feb 2021 14:37:32 -0800 (PST) Received: from localhost ([2620:15c:202:1:d8e6:826a:fc50:2158]) by smtp.gmail.com with UTF8SMTPSA id j20sm3331858pfe.172.2021.02.10.14.37.31 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 10 Feb 2021 14:37:32 -0800 (PST) Date: Wed, 10 Feb 2021 14:37:30 -0800 From: Matthias Kaehlcke To: Krzysztof Kozlowski Cc: Greg Kroah-Hartman , Rob Herring , Frank Rowand , devicetree@vger.kernel.org, Peter Chen , Stephen Boyd , Alan Stern , Ravi Chandra Sadineni , Bastien Nocera , linux-kernel@vger.kernel.org, Douglas Anderson , linux-usb@vger.kernel.org, Al Cooper , "Alexander A. Klimov" , Andy Gross , Bjorn Andersson , Masahiro Yamada , Mathias Nyman , linux-arm-msm@vger.kernel.org Subject: Re: [PATCH v5 0/4] USB: misc: Add onboard_usb_hub driver Message-ID: References: <20210210171040.684659-1-mka@chromium.org> <20210210210451.3coi62cynptzb6wf@kozik-lap> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20210210210451.3coi62cynptzb6wf@kozik-lap> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Krzysztof, On Wed, Feb 10, 2021 at 10:04:51PM +0100, Krzysztof Kozlowski wrote: > On Wed, Feb 10, 2021 at 09:10:35AM -0800, Matthias Kaehlcke wrote: > > This series adds the onboard_usb_hub_driver, the corresponding > > device tree bindings and creation of onboard_usb_hub platform in > > the xhci-plat driver during probe(). > > > > The main issue the driver addresses is that a USB hub needs to be > > powered before it can be discovered. For discrete onboard hubs (an > > example for such a hub is the Realtek RTS5411) this is often solved > > by supplying the hub with an 'always-on' regulator, which is kind > > of a hack. > > It seems you are re-developing the power sequence drivers which perform > exactly this. Peter Chen some time ago was bringing power sequence to > USB devices, but I lost track where this ended up. > > Some of his (and my) very old work (2017...) can be found here: > https://github.com/krzk/linux/tree/wip/odroid-u3-usb3503-pwrseq pwrseq was brought up in the discussion about this driver, but wasn't deemed suitable for this use case which might require more complex configurations: https://lore.kernel.org/patchwork/patch/1313000/#1512725 > Instead of adding custom driver hiding some USB hub implementation, > power sequence seems a generic solution. What if you need to power cycle > other embedded USB device? Not a hub? The driver could be extended to also cover other types of devices if desired. Maybe it should be called usb-pwrseq then, even though it's not directly related with the original pwrseq series.