Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp1779454rdb; Thu, 7 Dec 2023 08:33:22 -0800 (PST) X-Google-Smtp-Source: AGHT+IEto7TJQB6ZiZO2SgpyUV+hm+HVwkN3ycI79KsrplDLa9AYI504LsMGD6WArYXpFFZbM3lb X-Received: by 2002:a17:90a:c690:b0:286:9b8e:7e8c with SMTP id n16-20020a17090ac69000b002869b8e7e8cmr2927170pjt.60.1701966802114; Thu, 07 Dec 2023 08:33:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701966802; cv=none; d=google.com; s=arc-20160816; b=h2NfDhlPmwCP++epVsoo8Oew3BDj/GRgXSvYMlkmPDpnKKdyG0Ywhzwm93x/Y7603k i0GdsClt59mITShq/OLvOMlQGZVhYzK1rlLeQqOkixmm4OxIvcNHSKbvWrvb9ncKv53R tCm6wFRuOJRavYJzlrGnkwlW5HN6UPajT99miEJFm1xNskMBXPi7WB1j87ietCLR/9id ZL5qgkk/DFRLRu/Wkli4+KBLXggkeclqSTHfSs5itaZ9IvvnWtVoxghk5ACWctV7Gw9M eJ7SGNol38iywIbrxG8zV7P9oaroir1VgYIl6EmGzsxq5cG8YEJYK+XEymSRsCR31Fic D/9A== 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=oSMFlZ85aYjTiJumI051oc40X8TWQW1CJL/RAiBKqEs=; fh=vFpuv1Eeit2p0C5Ks5jSw1nEDZ7JWco5bheoW7CNBh4=; b=ADKisK303vLLppWDECKL55ch1yqlaS5679B+vbrQs1GOO4tffoh6TYMnR3oAsfZhOm FFpMsWikuCoRrGPNFa//lFEGCLICd6dFgOWJSTI9cNHk6nR6ZOYM2+o42WOxA5pTRCEq jLJfBuSb2x16hHNV1oWnGmfO2Mj++02ueYMFwyVf/KrITth+zz7lLa3UJljVubu0jTe6 Uszyc6R3mAk/3P1B+PBsZFSaV218Q59CUNPAesY7xqrwqdVScIDLU937JMoXxkKJaD+M ECf0eMS2kAUQuRPJ/If9NqqVcHDcTkmXpxCZwe/yyRGybNwL8CaNAKVzUKlIqw2NA5yZ sCVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="HCcs02/9"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from morse.vger.email (morse.vger.email. [23.128.96.31]) by mx.google.com with ESMTPS id bk8-20020a17090b080800b0028573fb25b9si83051pjb.135.2023.12.07.08.33.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Dec 2023 08:33:22 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) client-ip=23.128.96.31; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="HCcs02/9"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 5F23C826EEAB; Thu, 7 Dec 2023 08:33:19 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232933AbjLGQdG (ORCPT + 99 others); Thu, 7 Dec 2023 11:33:06 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60256 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229949AbjLGQdF (ORCPT ); Thu, 7 Dec 2023 11:33:05 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 18515133 for ; Thu, 7 Dec 2023 08:33:11 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id AD3D2C433CA; Thu, 7 Dec 2023 16:33:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1701966790; bh=8rENzAp0p8TNocu2nRhngKa8SFr6isL6RTBVJp6KrZs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=HCcs02/9Ogdjyp9dN1TdkXfGx1t09VNdtVuisKSk/2MgsrOLpeYKzVj3D+aV97LHX A3fg2Kt+4eRUxoJpfAikLZEZe1B9RFgR1oUsFhgRfKKCz9uAdpCDei+73Kdk7dQfLl c7Uu5wk6hld0DUq53ArASqtQFqJPm3Jc/pAsFh/c5lU8LnEM8tMlEnF8wAb1ty8VQe a/plY608cmUIQ46TGaWwosU31iy0MCsDS1VUJinwiMRN+r5iA5+KZoOHc13xUJD+SP nTjwd2/rH8VbbD4PhCbPYJ+eotlhbrWoMTmMgeEBeRFgSVebMNt1zZXdltX3b4frg9 TtMxCobQJmozQ== Received: from johan by xi.lan with local (Exim 4.96.2) (envelope-from ) id 1rBHK4-00019F-0o; Thu, 07 Dec 2023 17:34:00 +0100 Date: Thu, 7 Dec 2023 17:34:00 +0100 From: Johan Hovold To: Krishna Kurapati PSSNV Cc: Thinh Nguyen , Greg Kroah-Hartman , Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Wesley Cheng , Conor Dooley , cros-qcom-dts-watchers@chromium.org, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, quic_ppratap@quicinc.com, quic_jackp@quicinc.com Subject: Re: [PATCH v2 2/6] usb: dwc3: qcom: Rename hs_phy_irq to qusb2_phy_irq Message-ID: References: <20231204100950.28712-1-quic_kriskura@quicinc.com> <20231204100950.28712-3-quic_kriskura@quicinc.com> <9d52fa8c-41d1-46a7-be89-5c1c11ca09b4@quicinc.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9d52fa8c-41d1-46a7-be89-5c1c11ca09b4@quicinc.com> X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Thu, 07 Dec 2023 08:33:19 -0800 (PST) On Thu, Dec 07, 2023 at 09:17:32PM +0530, Krishna Kurapati PSSNV wrote: > On 12/7/2023 8:58 PM, Johan Hovold wrote: > > Here too you should say something about why this won't break any systems > > booting using an older devicetree. Specifically, the QUSB2 PHY interrupt > > has never been armed on any system running mainline as those bits never > > made it upstream. > > > > So an alternative to this could also be to just drop the QUSB2 PHY > > interrupt handling from this driver for now. > > So, are you suggesting that we drop the whole patch ? No, I meant that an alternative could be to drop the current hs_phy_irq handling from the driver. > I assume if the older kernels are using old DT, they would be using an > old driver version too right ? No, and this is part of the devicetree ABI as we discussed the other week. You should generally be able to continue booting with an older devicetree on a newer kernel (even if newer functionality may not be enabled then). > Is there a case where DT is not updated but driver is ? Because if we > drop this patch from series, targets with updated DT's would break. Actually they would not due to the fact that the QUSB2 PHY interrupt is currently never armed in the PHY (and the interrupts are looked up by name and are considered optional by the driver). But simply dropping this patch is not an option here. I'm fine with this patch as it is, but the reason we can merge it is that those interrupts are currently not actually used. Otherwise, this would break older devicetrees. But this also means, we could consider dropping the current hs_phy_irq handling altogether. Hmm. Looking at the qusb2_phy_runtime_suspend() again now I see that the interrupt is actually armed on runtime suspend, it's just that it is configured incorrectly and would wakeup immediately if someone ever exercised this path. Specifically, the bits that would set those PHY_MODE_USB_HOST_HS modes (that should never have been merged) never made it upstream so this code is just dead code currently. I said before I'll look into ripping this out, but yeah, I'm swamped with work as usual (and it has been sitting there dead for years so there's no rush). So to summarise, the QUSB2 wakeup handling is incomplete and broken, so we won't actually make things worse by renaming the interrupts. If this was working, we would need to continue supporting the old names, though. Johan