From patchwork Mon Apr 1 13:54:07 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vivek Gautam X-Patchwork-Id: 2370941 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 7609BDFB7B for ; Mon, 1 Apr 2013 13:59:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758729Ab3DAN7I (ORCPT ); Mon, 1 Apr 2013 09:59:08 -0400 Received: from mailout2.samsung.com ([203.254.224.25]:43974 "EHLO mailout2.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758586Ab3DAN63 (ORCPT ); Mon, 1 Apr 2013 09:58:29 -0400 Received: from epcpsbgr2.samsung.com (u142.gpu120.samsung.co.kr [203.254.230.142]) by mailout2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MKK008Q3XHGGS80@mailout2.samsung.com>; Mon, 01 Apr 2013 22:58:28 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [172.20.52.126]) by epcpsbgr2.samsung.com (EPCPMTA) with SMTP id 9E.09.07735.48299515; Mon, 01 Apr 2013 22:58:28 +0900 (KST) X-AuditID: cbfee68e-b7f946d000001e37-e8-51599284e7f4 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id 33.87.13494.48299515; Mon, 01 Apr 2013 22:58:28 +0900 (KST) Received: from vivekkumarg-linuxpc.sisodomain.com ([107.108.214.169]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0MKK00JXCXD41C70@mmp1.samsung.com>; Mon, 01 Apr 2013 22:58:28 +0900 (KST) From: Vivek Gautam To: linux-usb@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-omap@vger.kernel.org Cc: linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org, balbi@ti.com, stern@rowland.harvard.edu, sarah.a.sharp@linux.intel.com, rob.herring@calxeda.com, kgene.kim@samsung.com, kishon@ti.com, dianders@chromium.org, t.figa@samsung.com, p.paneri@samsung.com Subject: [PATCH v3 08/11] usb: phy: samsung: Enable runtime power management on usb3phy Date: Mon, 01 Apr 2013 19:24:07 +0530 Message-id: <1364824448-14732-9-git-send-email-gautam.vivek@samsung.com> X-Mailer: git-send-email 1.7.6.5 In-reply-to: <1364824448-14732-1-git-send-email-gautam.vivek@samsung.com> References: <1364824448-14732-1-git-send-email-gautam.vivek@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrCIsWRmVeSWpSXmKPExsWyRsSkTrdlUmSgwZuTQhYH79dbnF12kM2i efF6NoveBVfZLC487WGzuLxrDpvF7CX9LBYzzu9jsli0rJXZ4vyWTiaLwysOMFk0nzjFbDHh 9wU2i/UzXrM48Hks+HyF3WN2w0UWj3knAz32z10D5N39wejRt2UVo8fxG9uZPD5vkgvgiOKy SUnNySxLLdK3S+DK+Hf5E2vBV46K3xPXsTcwnmbvYuTgkBAwkbhzWauLkRPIFJO4cG89Wxcj F4eQwFJGiaNHj7BAJEwkdn3byASRWMQo8fTwYmYIZwqTxLHHZxlBqtgEdCWa3u5iBJkqIhAn sXmCMEiYWaCLSWLpUXGQsLBApETH/kqQMIuAqsTaWTPZQWxeAQ+Jpl0HmSB2KUi8uf2MGcTm FPCU+LB1MVhcCKim/eoJVpC1EgL32CWeLb3NBDFIQOLb5EMsEM/ISmw6wAwxR1Li4IobLBMY hRcwMqxiFE0tSC4oTkovMtIrTswtLs1L10vOz93ECIyh0/+e9e1gvHnA+hBjMtC4icxSosn5 wBjMK4k3NDYzsjA1MTU2Mrc0I01YSZxXrcU6UEggPbEkNTs1tSC1KL6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OGivzt77tMTecKnDSROf1lpiw oNd+AVeedDsK6RaI6ydsUvsqtUX2TNLyE8Gv21hYlViKMxINtZiLihMBGhgd+BUDAAA= DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org Enable autosuspending of Samsung usb3.0 PHY Signed-off-by: Vivek Gautam --- drivers/usb/phy/phy-samsung-usb3.c | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/drivers/usb/phy/phy-samsung-usb3.c b/drivers/usb/phy/phy-samsung-usb3.c index 54f6418..a713585 100644 --- a/drivers/usb/phy/phy-samsung-usb3.c +++ b/drivers/usb/phy/phy-samsung-usb3.c @@ -24,6 +24,7 @@ #include #include #include +#include #include #include @@ -287,6 +288,9 @@ static int samsung_usb3phy_probe(struct platform_device *pdev) platform_set_drvdata(pdev, sphy); + pm_runtime_set_active(&pdev->dev); + pm_runtime_enable(&pdev->dev); + return usb_add_phy(&sphy->phy, USB_PHY_TYPE_USB3); } @@ -296,6 +300,8 @@ static int samsung_usb3phy_remove(struct platform_device *pdev) usb_remove_phy(&sphy->phy); + pm_runtime_disable(&pdev->dev); + if (sphy->pmuregs) iounmap(sphy->pmuregs); if (sphy->sysreg)