From patchwork Mon Oct 20 10:45:34 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 5104211 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id B3CCEC11AC for ; Mon, 20 Oct 2014 10:46:10 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 0448520176 for ; Mon, 20 Oct 2014 10:46:10 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 264F1201DD for ; Mon, 20 Oct 2014 10:46:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753579AbaJTKp6 (ORCPT ); Mon, 20 Oct 2014 06:45:58 -0400 Received: from mailout1.w1.samsung.com ([210.118.77.11]:54314 "EHLO mailout1.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753245AbaJTKpy (ORCPT ); Mon, 20 Oct 2014 06:45:54 -0400 Received: from eucpsbgm1.samsung.com (unknown [203.254.199.244]) by mailout1.w1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NDQ00KWFOP8HA10@mailout1.w1.samsung.com>; Mon, 20 Oct 2014 11:48:44 +0100 (BST) X-AuditID: cbfec7f4-b7f6c6d00000120b-59-5444e7ddbe83 Received: from eusync4.samsung.com ( [203.254.199.214]) by eucpsbgm1.samsung.com (EUCPMTA) with SMTP id CF.54.04619.DD7E4445; Mon, 20 Oct 2014 11:45:49 +0100 (BST) Received: from amdc1339.digital.local ([106.116.147.30]) by eusync4.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0NDQ009U7OK7MS20@eusync4.samsung.com>; Mon, 20 Oct 2014 11:45:49 +0100 (BST) From: Marek Szyprowski To: linux-usb@vger.kernel.org, linux-samsung-soc@vger.kernel.org Cc: Marek Szyprowski , Felipe Balbi , Kyungmin Park , Robert Baldyga , Paul Zimmerman , Krzysztof Kozlowski Subject: [PATCH v2 04/10] usb: dwc2/gadget: disable phy before turning off power regulators Date: Mon, 20 Oct 2014 12:45:34 +0200 Message-id: <1413801940-31086-5-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.2 In-reply-to: <1413801940-31086-1-git-send-email-m.szyprowski@samsung.com> References: <1413801940-31086-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrMJMWRmVeSWpSXmKPExsVy+t/xa7p3n7uEGNw6YWxx8H69xesXhhZn m96wW8w4v4/JYtGyVmaLtUfusltsnzKdyeLB4Z3sDhwefVtWMXps2f+Z0eP4je1MHp83yQWw RHHZpKTmZJalFunbJXBlrPownblgLkdFz+4LbA2Mr9m6GDk5JARMJDa0/mKBsMUkLtxbDxTn 4hASWMoo8eDiPCYIp49J4uf1w2BVbAKGEl1vu8C6RQQcJJYsvQNmMwv8ZJSYPNWmi5GDQ1gg VuLIw0SQMIuAqsS3HyuZQWxeAQ+JvesvskMsk5P4/3IFE4jNKeAp8ebFNEYQWwioZtPylywT GHkXMDKsYhRNLU0uKE5KzzXUK07MLS7NS9dLzs/dxAgJqC87GBcfszrEKMDBqMTDK2DpEiLE mlhWXJl7iFGCg1lJhLf7NlCINyWxsiq1KD++qDQntfgQIxMHp1QDY5SlNZuda2/idZc5chNu lgTfvHfn+y1Ohlvtd2rYGi5Zd0m+MuRZ/M/U1a1u44PJ/DMFcmNvbZbbNNlgUUtov/qplme8 rdtr7e0LHsSqRi97knU1vnHqM+5NBixGr0zWX/y7YbnvElnjnTVrI6SeCHn9nnKPaYfXtx0S AnPD1vqp7Ar8ELrvuRJLcUaioRZzUXEiAG6yZSgGAgAA Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Spam-Status: No, score=-8.3 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch fixes probe function to match the pattern used elsewhere in the driver, where power regulators are turned off as the last element in the device shutdown procedure. Signed-off-by: Marek Szyprowski Acked-by: Paul Zimmerman --- drivers/usb/dwc2/gadget.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c index a4b4def23afd..fd52a8b23649 100644 --- a/drivers/usb/dwc2/gadget.c +++ b/drivers/usb/dwc2/gadget.c @@ -3571,6 +3571,7 @@ static int s3c_hsotg_probe(struct platform_device *pdev) s3c_hsotg_initep(hsotg, &hsotg->eps[epnum], epnum); /* disable power and clock */ + s3c_hsotg_phy_disable(hsotg); ret = regulator_bulk_disable(ARRAY_SIZE(hsotg->supplies), hsotg->supplies); @@ -3579,8 +3580,6 @@ static int s3c_hsotg_probe(struct platform_device *pdev) goto err_ep_mem; } - s3c_hsotg_phy_disable(hsotg); - ret = usb_add_gadget_udc(&pdev->dev, &hsotg->gadget); if (ret) goto err_ep_mem;