From patchwork Mon Jun 30 19:13:29 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vasily Khoruzhick X-Patchwork-Id: 4454001 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 A7FDEBEEAA for ; Mon, 30 Jun 2014 19:15:45 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id A4F552037E for ; Mon, 30 Jun 2014 19:15:44 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D2EEF2037D for ; Mon, 30 Jun 2014 19:15:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756269AbaF3TPm (ORCPT ); Mon, 30 Jun 2014 15:15:42 -0400 Received: from mail-wi0-f182.google.com ([209.85.212.182]:55576 "EHLO mail-wi0-f182.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754527AbaF3TPl (ORCPT ); Mon, 30 Jun 2014 15:15:41 -0400 Received: by mail-wi0-f182.google.com with SMTP id bs8so6513406wib.9 for ; Mon, 30 Jun 2014 12:15:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=pRYRNMh5U6PIQ2O/VwkkZw3f2BdVx/fHdZUO6S0Lzgk=; b=M3NhQZAyxDX1QgwbGennQhdJWMdf4f1FtO4jVCtWu+vgHFTycJXY0x3C8pt4tsUHHF LtZEot+OhKkvhHooXt+LfH53XYiaSPloYRRxYwVLaYjIiZrCl6zRAWFlTVjbUUY6fcBm +NZ68wvwhcpDfrsTtVPmJeVMZF6eDmwMSEYcO0d10OLMoAutdjgphQ1N9RkjmZMOwCTy T2GXZ5hCc9SuuxUAk52NMZoHUr8Jueq8euYpt02yUgtZSYjKed+bUOZUgOemRuql9Fxw JbOf/nq2R3YTkzuif+lcdwOdrmDuc/YRtFtuXXz1+FoKUJaDV6zi9Qfw9V4c+3XzlQxc yqtw== X-Received: by 10.180.39.33 with SMTP id m1mr31901000wik.82.1404155740037; Mon, 30 Jun 2014 12:15:40 -0700 (PDT) Received: from anarsoul-thinkpad.localdomain ([212.98.170.222]) by mx.google.com with ESMTPSA id fs17sm4876237wjc.6.2014.06.30.12.15.38 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 30 Jun 2014 12:15:39 -0700 (PDT) From: Vasily Khoruzhick To: Ben Dooks , Kukjin Kim , Felipe Balbi , Greg Kroah-Hartman , linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-usb@vger.kernel.org Cc: Vasily Khoruzhick Subject: [PATCH] usb: gadget: s3c2410: Move to clk_prepare_enable/clk_disable_unprepare Date: Mon, 30 Jun 2014 22:13:29 +0300 Message-Id: <1404155609-3103-1-git-send-email-anarsoul@gmail.com> X-Mailer: git-send-email 2.0.0 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=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham 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 Use clk_prepare_enable/clk_disable_unprepare to make the driver work properly with common clock framework. Signed-off-by: Vasily Khoruzhick --- drivers/usb/gadget/s3c2410_udc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/usb/gadget/s3c2410_udc.c b/drivers/usb/gadget/s3c2410_udc.c index 7987aa0..357b58e 100644 --- a/drivers/usb/gadget/s3c2410_udc.c +++ b/drivers/usb/gadget/s3c2410_udc.c @@ -1788,7 +1788,7 @@ static int s3c2410_udc_probe(struct platform_device *pdev) return PTR_ERR(usb_bus_clock); } - clk_enable(usb_bus_clock); + clk_prepare_enable(usb_bus_clock); udc_clock = clk_get(NULL, "usb-device"); if (IS_ERR(udc_clock)) { @@ -1796,7 +1796,7 @@ static int s3c2410_udc_probe(struct platform_device *pdev) return PTR_ERR(udc_clock); } - clk_enable(udc_clock); + clk_prepare_enable(udc_clock); mdelay(10); @@ -1952,13 +1952,13 @@ static int s3c2410_udc_remove(struct platform_device *pdev) release_mem_region(rsrc_start, rsrc_len); if (!IS_ERR(udc_clock) && udc_clock != NULL) { - clk_disable(udc_clock); + clk_disable_unprepare(udc_clock); clk_put(udc_clock); udc_clock = NULL; } if (!IS_ERR(usb_bus_clock) && usb_bus_clock != NULL) { - clk_disable(usb_bus_clock); + clk_disable_unprepare(usb_bus_clock); clk_put(usb_bus_clock); usb_bus_clock = NULL; }