From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Boyd Subject: [PATCH v5 12/23] usb: chipidea: msm: Mark device as runtime pm active Date: Mon, 17 Oct 2016 18:56:25 -0700 Message-ID: <20161018015636.11701-13-stephen.boyd@linaro.org> References: <20161018015636.11701-1-stephen.boyd@linaro.org> Return-path: Received: from mail-pf0-f173.google.com ([209.85.192.173]:35821 "EHLO mail-pf0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S936313AbcJRB4y (ORCPT ); Mon, 17 Oct 2016 21:56:54 -0400 Received: by mail-pf0-f173.google.com with SMTP id s8so85941894pfj.2 for ; Mon, 17 Oct 2016 18:56:53 -0700 (PDT) In-Reply-To: <20161018015636.11701-1-stephen.boyd@linaro.org> Sender: linux-arm-msm-owner@vger.kernel.org List-Id: linux-arm-msm@vger.kernel.org To: linux-usb@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, Andy Gross , Bjorn Andersson , Neil Armstrong , Arnd Bergmann , Felipe Balbi , Peter Chen , Greg Kroah-Hartman We're not properly marking the glue layer/wrapper device as runtime active, so runtime PM believes that the hardware state is inactive when we call pm_runtime_enable() in this driver. This causes a problem when the glue layer has a power domain associated with it, because runtime PM will go and disable the power domain to match the 'inactive' state of the device. Let's mark the device as active so that runtime PM doesn't improperly power down this device when it's actually active. Acked-by: Peter Chen Cc: Greg Kroah-Hartman Signed-off-by: Stephen Boyd --- drivers/usb/chipidea/ci_hdrc_msm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/chipidea/ci_hdrc_msm.c b/drivers/usb/chipidea/ci_hdrc_msm.c index 3889809fd0c4..89c1a02d69b5 100644 --- a/drivers/usb/chipidea/ci_hdrc_msm.c +++ b/drivers/usb/chipidea/ci_hdrc_msm.c @@ -80,6 +80,7 @@ static int ci_hdrc_msm_probe(struct platform_device *pdev) platform_set_drvdata(pdev, plat_ci); + pm_runtime_set_active(&pdev->dev); pm_runtime_no_callbacks(&pdev->dev); pm_runtime_enable(&pdev->dev); -- 2.10.0.297.gf6727b0