From patchwork Thu Nov 8 14:37:40 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 197842 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from mail-pa0-f56.google.com (mail-pa0-f56.google.com [209.85.220.56]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 2D72C2C0131 for ; Fri, 9 Nov 2012 01:38:00 +1100 (EST) Received: by mail-pa0-f56.google.com with SMTP id fa1sf2084377pad.11 for ; Thu, 08 Nov 2012 06:37:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20120806; h=mime-version:x-beenthere:received-spf:from:to:cc:subject:date :message-id:x-mailer:in-reply-to:references:in-reply-to:references :x-original-sender:x-original-authentication-results:reply-to :precedence:mailing-list:list-id:x-google-group-id:list-post :list-help:list-archive:sender:list-subscribe:list-unsubscribe :content-type; bh=kxAjL25/SCfDFT8Ebzo7jkd31TyVeyI9PASr1YC9fH8=; b=J1rtEunjIu9ABZ+xsV1MmN+aoPbae1jZQYski/TahnyvbzmzWGtAfX9hyRYFOh1wXL xCwwsoERO+BOAGiL1+8dkyyjBa2ngP3atCt8Y8huh2xHjUTgquDQ5HNACwjWB5ffKmYL X4xIwNgACLXCr/svXp1ZJsLLYhfeiqzC+1SHnXIzDoE1w+2mXFgtmlP6sXQ0gn3LXy2h 18QxxE7MqV+5Y7PL7r1IXtLWCIiwCRh6Gn1yBx+kb9Jcp+Mtw3nrzovYvheoMmEhKvon NAszVbh2z9ONtPPj08Exw9ByrI0aucJi7nIz9uRbVlHo/PAhjKnxKTCv9IxB0OMEbhiC s3Ng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-beenthere:received-spf:from:to:cc:subject:date :message-id:x-mailer:in-reply-to:references:in-reply-to:references :x-gm-message-state:x-original-sender :x-original-authentication-results:reply-to:precedence:mailing-list :list-id:x-google-group-id:list-post:list-help:list-archive:sender :list-subscribe:list-unsubscribe:content-type; bh=kxAjL25/SCfDFT8Ebzo7jkd31TyVeyI9PASr1YC9fH8=; b=FDPxZ4sbZGv8h1mDW3ZlanF790lxqgnqPmlbPglMPoj+7ap8dZDAIqhIz216nWqJl3 NaZG+bvm4DNO1oBZKQ4flzpVtGS5gAQIpGP5LyD5TxsAmu5Ii9hrCudz7+RjE0C4J2dk j/jAMfBXWNNb2eYX/5zbz/t3vhnZ2q98v5VUTlMSsL61WtYrp8UY47XrlzGHPqBbzPC4 PzablCaQJAz9pVLdrzmX/7zpWH8I9OCGy7UITAEprMoDT6LdfHYVZOAjnBAsmPSETs/4 WBmNbin2ZM+NsgokN836S5tJupcfdQr0SWsk+SJpxfNHFG4Nc3PoOdY70x6ivGfu4nXz mTdg== Received: by 10.68.143.74 with SMTP id sc10mr1574683pbb.5.1352385479486; Thu, 08 Nov 2012 06:37:59 -0800 (PST) MIME-Version: 1.0 X-BeenThere: rtc-linux@googlegroups.com Received: by 10.68.254.169 with SMTP id aj9ls11372901pbd.0.gmail; Thu, 08 Nov 2012 06:37:58 -0800 (PST) Received: by 10.66.86.102 with SMTP id o6mr3060869paz.41.1352385478901; Thu, 08 Nov 2012 06:37:58 -0800 (PST) Received: by 10.66.86.102 with SMTP id o6mr3060868paz.41.1352385478889; Thu, 08 Nov 2012 06:37:58 -0800 (PST) Received: from mail-pb0-f41.google.com (mail-pb0-f41.google.com [209.85.160.41]) by gmr-mx.google.com with ESMTPS id uz6si6186491pbc.0.2012.11.08.06.37.58 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 08 Nov 2012 06:37:58 -0800 (PST) Received-SPF: neutral (google.com: 209.85.160.41 is neither permitted nor denied by best guess record for domain of viresh.kumar@linaro.org) client-ip=209.85.160.41; Received: by mail-pb0-f41.google.com with SMTP id rq2so1890881pbb.28 for ; Thu, 08 Nov 2012 06:37:58 -0800 (PST) Received: by 10.66.87.165 with SMTP id az5mr22840539pab.46.1352385478807; Thu, 08 Nov 2012 06:37:58 -0800 (PST) Received: from localhost ([122.167.75.112]) by mx.google.com with ESMTPS id hc4sm16036116pbc.30.2012.11.08.06.37.55 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 08 Nov 2012 06:37:58 -0800 (PST) From: Viresh Kumar To: akpm@linux-foundation.org Cc: rtc-linux@googlegroups.com, linux-kernel@vger.kernel.org, a.zummo@towertech.it, spear-devel@list.st.com, Deepak Sikri , Viresh Kumar Subject: [rtc-linux] [PATCH 2/3] rtc: rtc-spear: Add clk_{un}prepare() support Date: Thu, 8 Nov 2012 20:07:40 +0530 Message-Id: X-Mailer: git-send-email 1.7.12.rc2.18.g61b472e In-Reply-To: References: In-Reply-To: References: X-Gm-Message-State: ALoCoQlBMYrHlGMHkFJ1Y0p4kv9bTPE1qSC5ksrIAwmamKUVmOyzgRrJ5Qdnp5mhclnMRp1SHV5m X-Original-Sender: viresh.kumar@linaro.org X-Original-Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 209.85.160.41 is neither permitted nor denied by best guess record for domain of viresh.kumar@linaro.org) smtp.mail=viresh.kumar@linaro.org Reply-To: rtc-linux@googlegroups.com Precedence: list Mailing-list: list rtc-linux@googlegroups.com; contact rtc-linux+owners@googlegroups.com List-ID: X-Google-Group-Id: 712029733259 List-Post: , List-Help: , List-Archive: Sender: rtc-linux@googlegroups.com List-Subscribe: , List-Unsubscribe: , From: Deepak Sikri clk_{un}prepare is mandatory for platforms using common clock framework. Because for SPEAr we don't do anything in clk_{un}prepare() calls, just call them ones in probe/remove. Signed-off-by: Deepak Sikri Signed-off-by: Viresh Kumar --- drivers/rtc/rtc-spear.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/rtc/rtc-spear.c b/drivers/rtc/rtc-spear.c index 480ecc3..990de02 100644 --- a/drivers/rtc/rtc-spear.c +++ b/drivers/rtc/rtc-spear.c @@ -401,7 +401,7 @@ static int __devinit spear_rtc_probe(struct platform_device *pdev) if (IS_ERR(config->clk)) return PTR_ERR(config->clk); - status = clk_enable(config->clk); + status = clk_prepare_enable(config->clk); if (status < 0) return status; @@ -424,7 +424,7 @@ static int __devinit spear_rtc_probe(struct platform_device *pdev) err_disable_clock: platform_set_drvdata(pdev, NULL); - clk_disable(config->clk); + clk_disable_unprepare(config->clk); return status; } @@ -435,7 +435,7 @@ static int __devexit spear_rtc_remove(struct platform_device *pdev) rtc_device_unregister(config->rtc); spear_rtc_disable_interrupt(config); - clk_disable(config->clk); + clk_disable_unprepare(config->clk); device_init_wakeup(&pdev->dev, 0); return 0;