Received: by 10.192.165.148 with SMTP id m20csp7694imm; Thu, 19 Apr 2018 14:56:51 -0700 (PDT) X-Google-Smtp-Source: AIpwx4813eAOUp4stREbBJg8n5VO+aBtCHOlJj01TcAjizlNPHaXiKY3uYRWOy8ehkQMyQ0X+6al X-Received: by 10.99.182.66 with SMTP id v2mr4714444pgt.158.1524175011488; Thu, 19 Apr 2018 14:56:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524175011; cv=none; d=google.com; s=arc-20160816; b=gIa8pUh+7vE7q+jxMPFQEKzNv9sfLUztuOgdXYVbR2YDl+4blrwtcTMDNfCDEfBmjj /Twux0UjQQtebKBgFu+IDwXaCMySAam1RcT8j1IjFHZTvCZ6DTh4SBHP/IEgawDxutNf TL2jQ15rwOC7u+GIauRg49l01KU0dFjkhxUMp40P486NYjubb9cJWe5qCyeSN0NqgpKD dceV+il7o8eom//NXlkFlfDViSyfHNLCf4BSQ4hIYuzWcV2vFjhzSvYI4AvyFBBj7DQO BSrNNflwEkHAKDuuciYkpHrPbSJpFavgZEAqrQrW0YBTAyxoQyZ1hRADB5k93ZXgWW6u xMVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=LVVS4nqvFsky5W9JMiawxXlysB1Ls57jne/mRXGOg3M=; b=GHKn777971AfQgH9F+e41A6PHBdYD0Zk/Bx08IHQzKS6EuQs0saiT6tHHVeXAyIFOj l3lnbrKGfwu8gpMBtmNGYIbSAyKb9JXF2CK0tgYuPEKnlS4+VRHoAFxHmIsYQvCyoqHo 5EEx8L7rLn4GO2drdzxBdAuh6mYamcuWZGBN6l1tuSsXTotxlnkj4HkdK6PALp/NLM64 9csJ3OdSit0MGDlzbZj1KIR9Bn+9dA8Jp2keRCSDl40oTtxjLIKR8dor9+W82ncmY32w 20+eOQdcgXeNqgUhgYd5w+/iibiFJeMWV/3nn4vLSNUqQiGbDxdJ9HEnM0HFH8OHV8Qh u0Pg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=Ih1s3Cb1; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a61-v6si4166573plc.402.2018.04.19.14.56.34; Thu, 19 Apr 2018 14:56:51 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=Ih1s3Cb1; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753537AbeDSVyr (ORCPT + 99 others); Thu, 19 Apr 2018 17:54:47 -0400 Received: from mail-ot0-f196.google.com ([74.125.82.196]:33868 "EHLO mail-ot0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753460AbeDSVyq (ORCPT ); Thu, 19 Apr 2018 17:54:46 -0400 Received: by mail-ot0-f196.google.com with SMTP id i5-v6so7533667oth.1; Thu, 19 Apr 2018 14:54:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=LVVS4nqvFsky5W9JMiawxXlysB1Ls57jne/mRXGOg3M=; b=Ih1s3Cb1CNDcHH9C36tULObaIXmHL5BcUwcX5jIbkyDuYvWC7Q9j/0I83Nuv3lZ6x3 xIF0hEmC3PtMw8sF5M0KB3S5yymuwEBvFcbbOh8Hamku9qwiWAZxzrQPFw3wIMrsBtI5 6lx+aQSNT7k4uffa4qAMYd+NRYbU82splRY6ShtPHh33e4JtvpMic/AszPkNh/mdzT6j YN5CXwUA2PZeJx7xH09kPxQwadi8OCUVxYyPKzFP1rANLmXXKZ5WPMpZAWNTKK2Hn5yI iqy/5UMS996gM4trNVFi3LILx6Fjd5346nzRBMiDMfnEwOOkyGX81EhDSiXqlsbtgSPU 1V/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=LVVS4nqvFsky5W9JMiawxXlysB1Ls57jne/mRXGOg3M=; b=aEaQrufMC0JKieiEVGIqKXBk5FIcyUQK4ZQUQQQKOYege07xSxdj19c0/WQs2Ef05n yvvTqMqP1P6Wq41TrkgdxV/7Lj1v4TLe5lqZtT8F1PBAqdq0BXWdXpLGH4zwADiBroWw vO3FUO9kqqB5zHnYbTioLbmf3/V+WzpQIiNpGlJJPQt+e0wG3T5E8GM33K8zW18xuGbU g2HExJkFk/Lr2dN9nRlkIOaXKGTCHOJy0Jw1KcYRy3RbdOvxvyEqo7N7kUCaAndBQj9q VZvRzW81fvGadmMNMxyPXJuj1wOI4YzmV1AYuHP7APLvgZnRVaNEby3D3Y92czlLsrVh L4Fw== X-Gm-Message-State: ALQs6tD7WWI/NqpHtbuxbuHAC1GN1vyRdQf+82Xvl2Zuii4mmYYzgMpK BWdvf5Caqq6LPzQMEaPWPKg6i4RiU/ALqLwidOk= X-Received: by 2002:a9d:be1:: with SMTP id 88-v6mr4829438oth.285.1524174885121; Thu, 19 Apr 2018 14:54:45 -0700 (PDT) MIME-Version: 1.0 Received: by 10.201.44.216 with HTTP; Thu, 19 Apr 2018 14:54:24 -0700 (PDT) In-Reply-To: <20180419074353.GK9198@localhost> References: <20180413151505.32663-1-johan@kernel.org> <20180419074353.GK9198@localhost> From: Martin Blumenstingl Date: Thu, 19 Apr 2018 23:54:24 +0200 Message-ID: Subject: Re: [PATCH 0/3] USB: musb: dsps: phy fix and DT-topology support To: Johan Hovold Cc: Bin Liu , Greg Kroah-Hartman , Alan Stern , Arnd Bergmann , Kishon Vijay Abraham I , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Johan, On Thu, Apr 19, 2018 at 9:43 AM, Johan Hovold wrote: > On Wed, Apr 18, 2018 at 09:18:30PM +0200, Martin Blumenstingl wrote: >> Hi Johan, >> >> On Fri, Apr 13, 2018 at 5:15 PM, Johan Hovold wrote: >> > I've been carrying a patch out-of-tree since my work on improving the >> > USB device-tree support which is needed to be able to describe USB >> > topologies for musb based controllers. >> > >> > This patch, which associates the platform controller device with the >> > glue device device-tree node, did not play well with the recent changes >> > which added generic phy support to USB core however. >> I'm the one who added this >> >> > Like the recent dwc2 regression fixed by Arnd after the device-tree >> > #phy-cell changes, the generic phy code in USB core can now also fail >> > indefinitly with -EPROBE_DEFER when the controller uses a legacy USB >> > phy. >> > >> > The second patch addresses this for musb, which handles its own (legacy >> > and generic) phys, but something more may possibly now be needed for >> > other platforms with legacy phys. >> I'm not sure if I understand the problem yet - could you please >> explain with your words what "legacy PHYs" are and how the "conflict" >> with the PHY handling in USB core? >> >> I am aware of two PHY subsystems: >> - drivers/phy >> -- also called "generic PHY framework" >> -- uses a "phys" property > > Right, and these are sometimes referred to as generic PHYs, as opposed > to... > >> - drivers/usb/phy >> -- also called "USB PHY framework" >> -- AFAIK this should not be used for new drivers > > ...the legacy ones. > >> -- uses an "usb-phy" property > > This is unfortunately not always the case however; some legacy USB phys > are also referred to using a "phys" property... oh, I was not aware of that. this explains the issue you're seeing... thank you for the explanation! >> the new PHY handling in USB core only parses the "phys" property and >> thus should not conflict with "usb-phy" (the legacy property) > >> however, I probably missed something so I'd appreciate an explanation >> how things can break > > ...and that is the problem. Specifically, since last fall when a number > of legacy-phy nodes had a #phy-cells property added to them (to silence > DTC warnings), the generic PHY subsubsystem can now return -EPROBE_DEFER > indefinitely when looking up a phy as it finds a matching device-tree > node, but for which there will never be a generic phy registered (since > it's handled by a legacy-phy driver). > > I referred to Arnd's workaround for "usb-nop-xceiv" devices > > b7563e2796f8 ("phy: work around 'phys' references to > usb-nop-xceiv devices") > > which has some more background on this. thank you for this pointer too > So if we have any other host controllers out there using > "phys"-properties with legacy phys other than "usb-nop-xceiv", then > these will now fail to register (with -EPROBE_DEFER) unless > hcd->skip_phy_initialization is set (or we blacklist them as well in the > generic phy code). > > I'm not aware of any further examples, but we're sure to find out soon > enough if there are. > > Perhaps we should blacklist also "ti,am335x-usb-phy" in the generic phy > code even if hcd->skip_phy_initialization is still needed for musb for > the time being anyway. > > Johan Regards Martin