From patchwork Tue Apr 16 21:53:47 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Doug Anderson X-Patchwork-Id: 10904215 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DE9B513B5 for ; Tue, 16 Apr 2019 21:54:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C26D128535 for ; Tue, 16 Apr 2019 21:54:19 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B342128A0F; Tue, 16 Apr 2019 21:54:19 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 52C1A28535 for ; Tue, 16 Apr 2019 21:54:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:To :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=+UCAUo6udy6aFi/tDcJG2eqt5AZgVLM+4mXff8uco+E=; b=Kaa+6vISJr0sb8 ES74Jb9GKRLJeA/vp8oJ4XMBTe8WASDE6bOrbLN4VoqoJahYRhPPO2bX/Z/rnZ8I17ZUOCgVubj/h izvck8G84V442W37VobKeNNRijdPUPAO3yO7ZCgrp3cCL0dL6CfvvrsQBa1ERH7IDHQxyCBDyH7eS AEPHKrooWO9NCWxEvq4i1wrOCEBMiuOHROInDcr1apw2NEbxkfUlHtwfU5EB6eOnVZJ27chslIVsf rFg9SM27i7O0OoylaikSr/dS03oBPtdZH1Jw4J6zEt69KtpZOmKaRrjYDC7shEkGC6kAvMtG9f/sW Zeqrw5IrakrgAvaFFCqA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hGW1v-00089G-Qf; Tue, 16 Apr 2019 21:54:15 +0000 Received: from mail-pl1-x642.google.com ([2607:f8b0:4864:20::642]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hGW1s-00087y-Ob for linux-rockchip@lists.infradead.org; Tue, 16 Apr 2019 21:54:14 +0000 Received: by mail-pl1-x642.google.com with SMTP id t16so10996449plo.0 for ; Tue, 16 Apr 2019 14:54:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=9HGU4dCKpXPQnSBrDR2ECEUC1qmGkGpsIfBVYvSfbAc=; b=RG7wZxCW8Z6YRFTWDTOwvUtZpsmFe9M0LLHCuTQ92Xx3GKtPCDP+vTPWgTlMTphJAG K2ngJz9rExe3KSMZvT2dGJZ0UwEvJC2B5PB+FrRftE9FZZqZfUIOASNsVMCq/EAeSXLN wDzRSVJYzW1w2mH49a0NUDrFuoggMbB33M2OA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=9HGU4dCKpXPQnSBrDR2ECEUC1qmGkGpsIfBVYvSfbAc=; b=fQ74gTf9KArtHG5ZgSnjvnJ2UNlmW0DkNsF7kaojHlNhS0JOaSn8NPMCP9tbn3XkJk gAJNJmqhkbNYBR3Oz4k2G916tS7NH8tEzJdR6OYl6ZHzQGGL3fjESoSURJUJZSoTfWuf VarMPU80UWdoekgwhBFs60QBHHPtdjxZhAWb1MQritF4oI7xi8sLsenshawEtTJitjzQ puL6y37nHqdtLPTr5Jg1egeoDLBFTUB8QSrPdGj12WnT6vPS5+WSbyPGKBl1mqfB/Kq0 CSLJIKGrePbzWFdRww7zt5ucurhPF/5XZsFM7wara1Tq0xn3jlK+y8hVoj5HmZF9cBPX IfQA== X-Gm-Message-State: APjAAAXKeEg2onAPoQAC1u04rE6nP6/Q8V0KwpC7JcM9O0ZcIq6FEYXt HtK49HJywbqfImUqi9u8buVhpg== X-Google-Smtp-Source: APXvYqzyFpMWEmeYMmrX9KaorHnS7Ur0BIgPYvvV0Vvlt8QvOPOjbOuGAegmy11626TgNUuOgto1sQ== X-Received: by 2002:a17:902:1681:: with SMTP id h1mr71653830plh.102.1555451651706; Tue, 16 Apr 2019 14:54:11 -0700 (PDT) Received: from tictac2.mtv.corp.google.com ([2620:15c:202:1:24fa:e766:52c9:e3b2]) by smtp.gmail.com with ESMTPSA id b6sm8156770pgt.58.2019.04.16.14.54.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 16 Apr 2019 14:54:10 -0700 (PDT) From: Douglas Anderson To: Rob Herring , Minas Harutyunyan , Heiko Stuebner , Felipe Balbi Subject: [PATCH v2 0/4] usb: dwc2: Another attempt handling rk3288's remote wake quirk Date: Tue, 16 Apr 2019 14:53:47 -0700 Message-Id: <20190416215351.242246-1-dianders@chromium.org> X-Mailer: git-send-email 2.21.0.593.g511ec345e18-goog MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190416_145412_821309_95D7AAD4 X-CRM114-Status: UNSURE ( 9.40 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , devicetree@vger.kernel.org, linux-usb@vger.kernel.org, amstan@chromium.org, Greg Kroah-Hartman , Randy Li , Douglas Anderson , linux-kernel@vger.kernel.org, linux-rockchip@lists.infradead.org, mka@chromium.org, ryandcase@chromium.org, Elaine Zhang , jwerner@chromium.org, linux-arm-kernel@lists.infradead.org Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP This is another attempt to upstream the code to unwedge the rk3288's "host" USB port when it sees a remote wakeup. Previously I attempted this [1] and it appears that Randy Li made some attempts too [2] which resulted in at least the PHY bindings for the USB PHY landing as well as the USB PHY support. Nice! Hopefully this addresses previous comments and could land this time? [1] https://lkml.kernel.org/r/1446236275-12698-2-git-send-email-dianders@chromium.org [2] https://lkml.kernel.org/r/1472939729-15187-4-git-send-email-ayaka@soulik.info Changes in v2: - Cancel the work when dwc2 is freed (Matthias). Douglas Anderson (4): dt-bindings: usb: dwc2: Document quirk to reset PHY upon wakeup usb: dwc2: optionally assert phy reset when waking up ARM: dts: rockchip: Hook resets up to USB PHYs on rk3288. ARM: dts: rockchip: Add quirk for resetting rk3288's dwc2 host on wakeup Documentation/devicetree/bindings/usb/dwc2.txt | 2 ++ arch/arm/boot/dts/rk3288.dtsi | 7 +++++++ drivers/usb/dwc2/core.h | 5 +++++ drivers/usb/dwc2/core_intr.c | 12 ++++++++++++ drivers/usb/dwc2/hcd.c | 18 +++++++++++++++--- drivers/usb/dwc2/platform.c | 9 +++++++++ 6 files changed, 50 insertions(+), 3 deletions(-)