All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paul Walmsley <paul@pwsan.com>
To: linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org
Subject: [PATCH 10/10] OMAP clock: resolve old checkpatch and CodingStyle issues with plat-omap/clock.c
Date: Mon, 26 Apr 2010 01:04:38 -0600	[thread overview]
Message-ID: <20100426070435.9743.25021.stgit@localhost.localdomain> (raw)
In-Reply-To: <20100426070217.9743.92728.stgit@localhost.localdomain>

Clean up comment style, remove unnecessary includes, and resolve some
checkpatch warnings in plat-omap/clock.c.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
---
 arch/arm/plat-omap/clock.c |   28 +++++++++++++++-------------
 1 files changed, 15 insertions(+), 13 deletions(-)

diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
index 5261a09..c9cd98a 100644
--- a/arch/arm/plat-omap/clock.c
+++ b/arch/arm/plat-omap/clock.c
@@ -12,14 +12,12 @@
  */
 #include <linux/kernel.h>
 #include <linux/init.h>
-#include <linux/module.h>
 #include <linux/list.h>
 #include <linux/errno.h>
 #include <linux/err.h>
 #include <linux/string.h>
 #include <linux/clk.h>
 #include <linux/mutex.h>
-#include <linux/platform_device.h>
 #include <linux/cpufreq.h>
 #include <linux/debugfs.h>
 #include <linux/io.h>
@@ -32,9 +30,9 @@ static DEFINE_SPINLOCK(clockfw_lock);
 
 static struct clk_functions *arch_clock;
 
-/*-------------------------------------------------------------------------
+/*
  * Standard clock functions defined in include/linux/clk.h
- *-------------------------------------------------------------------------*/
+ */
 
 int clk_enable(struct clk *clk)
 {
@@ -92,9 +90,9 @@ unsigned long clk_get_rate(struct clk *clk)
 }
 EXPORT_SYMBOL(clk_get_rate);
 
-/*-------------------------------------------------------------------------
+/*
  * Optional clock functions defined in include/linux/clk.h
- *-------------------------------------------------------------------------*/
+ */
 
 long clk_round_rate(struct clk *clk, unsigned long rate)
 {
@@ -140,9 +138,11 @@ int clk_set_parent(struct clk *clk, struct clk *parent)
 	unsigned long flags;
 	int ret = -EINVAL;
 
-	if (cpu_is_omap44xx())
-	/* OMAP4 clk framework not supported yet */
+	if (cpu_is_omap44xx()) {
+		WARN(1, "clock: %s: not supported yet on OMAP4\n", __func__);
 		return 0;
+	}
+
 	if (clk == NULL || IS_ERR(clk) || parent == NULL || IS_ERR(parent))
 		return ret;
 
@@ -169,9 +169,9 @@ struct clk *clk_get_parent(struct clk *clk)
 }
 EXPORT_SYMBOL(clk_get_parent);
 
-/*-------------------------------------------------------------------------
+/*
  * OMAP specific clock functions shared between omap1 and omap2
- *-------------------------------------------------------------------------*/
+ */
 
 int __initdata mpurate;
 
@@ -222,7 +222,7 @@ void clk_reparent(struct clk *child, struct clk *parent)
 }
 
 /* Propagate rate to children */
-void propagate_rate(struct clk * tclk)
+void propagate_rate(struct clk *tclk)
 {
 	struct clk *clkp;
 
@@ -389,7 +389,9 @@ void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table)
 }
 #endif
 
-/*-------------------------------------------------------------------------*/
+/*
+ *
+ */
 
 #ifdef CONFIG_OMAP_RESET_CLOCKS
 /*
@@ -404,7 +406,7 @@ static int __init clk_disable_unused(void)
 		if (ck->ops == &clkops_null)
 			continue;
 
-		if (ck->usecount > 0 || ck->enable_reg == 0)
+		if (ck->usecount > 0 || !ck->enable_reg)
 			continue;
 
 		spin_lock_irqsave(&clockfw_lock, flags);



WARNING: multiple messages have this Message-ID (diff)
From: paul@pwsan.com (Paul Walmsley)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 10/10] OMAP clock: resolve old checkpatch and CodingStyle issues with plat-omap/clock.c
Date: Mon, 26 Apr 2010 01:04:38 -0600	[thread overview]
Message-ID: <20100426070435.9743.25021.stgit@localhost.localdomain> (raw)
In-Reply-To: <20100426070217.9743.92728.stgit@localhost.localdomain>

Clean up comment style, remove unnecessary includes, and resolve some
checkpatch warnings in plat-omap/clock.c.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
---
 arch/arm/plat-omap/clock.c |   28 +++++++++++++++-------------
 1 files changed, 15 insertions(+), 13 deletions(-)

diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
index 5261a09..c9cd98a 100644
--- a/arch/arm/plat-omap/clock.c
+++ b/arch/arm/plat-omap/clock.c
@@ -12,14 +12,12 @@
  */
 #include <linux/kernel.h>
 #include <linux/init.h>
-#include <linux/module.h>
 #include <linux/list.h>
 #include <linux/errno.h>
 #include <linux/err.h>
 #include <linux/string.h>
 #include <linux/clk.h>
 #include <linux/mutex.h>
-#include <linux/platform_device.h>
 #include <linux/cpufreq.h>
 #include <linux/debugfs.h>
 #include <linux/io.h>
@@ -32,9 +30,9 @@ static DEFINE_SPINLOCK(clockfw_lock);
 
 static struct clk_functions *arch_clock;
 
-/*-------------------------------------------------------------------------
+/*
  * Standard clock functions defined in include/linux/clk.h
- *-------------------------------------------------------------------------*/
+ */
 
 int clk_enable(struct clk *clk)
 {
@@ -92,9 +90,9 @@ unsigned long clk_get_rate(struct clk *clk)
 }
 EXPORT_SYMBOL(clk_get_rate);
 
-/*-------------------------------------------------------------------------
+/*
  * Optional clock functions defined in include/linux/clk.h
- *-------------------------------------------------------------------------*/
+ */
 
 long clk_round_rate(struct clk *clk, unsigned long rate)
 {
@@ -140,9 +138,11 @@ int clk_set_parent(struct clk *clk, struct clk *parent)
 	unsigned long flags;
 	int ret = -EINVAL;
 
-	if (cpu_is_omap44xx())
-	/* OMAP4 clk framework not supported yet */
+	if (cpu_is_omap44xx()) {
+		WARN(1, "clock: %s: not supported yet on OMAP4\n", __func__);
 		return 0;
+	}
+
 	if (clk == NULL || IS_ERR(clk) || parent == NULL || IS_ERR(parent))
 		return ret;
 
@@ -169,9 +169,9 @@ struct clk *clk_get_parent(struct clk *clk)
 }
 EXPORT_SYMBOL(clk_get_parent);
 
-/*-------------------------------------------------------------------------
+/*
  * OMAP specific clock functions shared between omap1 and omap2
- *-------------------------------------------------------------------------*/
+ */
 
 int __initdata mpurate;
 
@@ -222,7 +222,7 @@ void clk_reparent(struct clk *child, struct clk *parent)
 }
 
 /* Propagate rate to children */
-void propagate_rate(struct clk * tclk)
+void propagate_rate(struct clk *tclk)
 {
 	struct clk *clkp;
 
@@ -389,7 +389,9 @@ void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table)
 }
 #endif
 
-/*-------------------------------------------------------------------------*/
+/*
+ *
+ */
 
 #ifdef CONFIG_OMAP_RESET_CLOCKS
 /*
@@ -404,7 +406,7 @@ static int __init clk_disable_unused(void)
 		if (ck->ops == &clkops_null)
 			continue;
 
-		if (ck->usecount > 0 || ck->enable_reg == 0)
+		if (ck->usecount > 0 || !ck->enable_reg)
 			continue;
 
 		spin_lock_irqsave(&clockfw_lock, flags);

  parent reply	other threads:[~2010-04-26  7:07 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-26  7:04 [PATCH 00/10] OMAP PRCM, clock: some cleanup patches for 2.6.35 Paul Walmsley
2010-04-26  7:04 ` Paul Walmsley
2010-04-26  7:04 ` [PATCH 01/10] OMAP1 clock: fix section mismatch on clk_init Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26 18:11   ` Tony Lindgren
2010-04-26 18:11     ` Tony Lindgren
2010-04-26  7:04 ` [PATCH 02/10] OMAP2 PRCM: convert OMAP2 PRCM macros to the _SHIFT/_MASK suffixes Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26  7:04 ` [PATCH 03/10] OMAP3 PRCM: convert OMAP3 " Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26  7:04 ` [PATCH 04/10] OMAP2+ PRCM: convert remaining " Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26  7:04 ` [PATCH 05/10] OMAP3: PM: PM_MPUGRPSEL writes should use GRPSEL macros, not EN macros Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26  7:04 ` [PATCH 06/10] OMAP2+ clock: remove DEFAULT_RATE clksel_rate flag Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26  7:04 ` [PATCH 07/10] OMAP2+ clock: clean up clkt_clksel.c Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26  7:04 ` [PATCH 08/10] OMAP3 clock: rename RATE_IN_343X, RATE_IN_3430ES2 to match reality Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26  7:04 ` [PATCH 09/10] OMAP3 clock: remove unnecessary duplicate of dpll4_m2_ck, added for 36xx Paul Walmsley
2010-04-26  7:04   ` Paul Walmsley
2010-04-26  7:04 ` Paul Walmsley [this message]
2010-04-26  7:04   ` [PATCH 10/10] OMAP clock: resolve old checkpatch and CodingStyle issues with plat-omap/clock.c Paul Walmsley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100426070435.9743.25021.stgit@localhost.localdomain \
    --to=paul@pwsan.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-omap@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.