Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1610473 > unrolled thread

[PATCH v5 0/3] clk: let clk_disable() return immediately if clk is NULL for last 3 clks

Started byMasahiro Yamada <yamada.masahiro@socionext.com>
First post2017-03-28 11:30 +0200
Last post2017-03-30 17:40 +0200
Articles 5 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH v5 0/3] clk: let clk_disable() return immediately if clk is NULL for last 3 clks Masahiro Yamada <yamada.masahiro@socionext.com> - 2017-03-28 11:30 +0200
    [PATCH v5 2/3] ARM: w90x900: let clk_disable() return immediately if clk is NULL Masahiro Yamada <yamada.masahiro@socionext.com> - 2017-03-28 11:30 +0200
      Re: [PATCH v5 2/3] ARM: w90x900: let clk_disable() return immediately  if clk is NULL Arnd Bergmann <arnd@arndb.de> - 2017-03-30 17:40 +0200
    [PATCH v5 1/3] ARM: mmp: let clk_disable() return immediately if clk is NULL Masahiro Yamada <yamada.masahiro@socionext.com> - 2017-03-28 11:30 +0200
      Re: [PATCH v5 1/3] ARM: mmp: let clk_disable() return immediately if  clk is NULL Arnd Bergmann <arnd@arndb.de> - 2017-03-30 17:40 +0200

#1610473 — [PATCH v5 0/3] clk: let clk_disable() return immediately if clk is NULL for last 3 clks

FromMasahiro Yamada <yamada.masahiro@socionext.com>
Date2017-03-28 11:30 +0200
Subject[PATCH v5 0/3] clk: let clk_disable() return immediately if clk is NULL for last 3 clks
Message-ID<tpVBU-5sY-15@gated-at.bofh.it>
Hi Andrew,

Please consider to apply this series to your tree.
This trivial series has been left over so long.

Stephen Boyd suggested to split the series per-arch,
and I did so.
But sub-architecture maintainers did not respond
in spite of my several times pings.


Please see this:
w90x900:   https://patchwork.kernel.org/patch/9338047/
mmp:       https://patchwork.kernel.org/patch/9338049/
blackfin   https://patchwork.kernel.org/patch/9338053/


Stephen mentioned Andrew could pick up this in case maintainers are silent.
http://lkml.iu.edu/hypermail/linux/kernel/1609.2/00801.html


Masahiro Yamada (3):
  ARM: mmp: let clk_disable() return immediately if clk is NULL
  ARM: w90x900: let clk_disable() return immediately if clk is NULL
  blackfin: bf609: let clk_disable() return immediately if clk is NULL

 arch/arm/mach-mmp/clock.c        | 3 +++
 arch/arm/mach-w90x900/clock.c    | 3 +++
 arch/blackfin/mach-bf609/clock.c | 3 +++
 3 files changed, 9 insertions(+)

-- 
2.7.4

[toc] | [next] | [standalone]


#1610475 — [PATCH v5 2/3] ARM: w90x900: let clk_disable() return immediately if clk is NULL

FromMasahiro Yamada <yamada.masahiro@socionext.com>
Date2017-03-28 11:30 +0200
Subject[PATCH v5 2/3] ARM: w90x900: let clk_disable() return immediately if clk is NULL
Message-ID<tpVBV-5sY-47@gated-at.bofh.it>
In reply to#1610473
In many of clk_disable() implementations, it is a no-op for a NULL
pointer input, but this is one of the exceptions.

Making it treewide consistent will allow clock consumers to call
clk_disable() without NULL pointer check.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Acked-by: Wan Zongshun <mcuos.com@gmail.com>
---

Changes in v5: None
Changes in v4:
  - Split into per-arch patches

Changes in v3:
  - Return only when clk is NULL.  Do not take care of error pointer.

Changes in v2:
  - Rebase on Linux 4.6-rc1

 arch/arm/mach-w90x900/clock.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/arm/mach-w90x900/clock.c b/arch/arm/mach-w90x900/clock.c
index 2c371ff..ac6fd1a 100644
--- a/arch/arm/mach-w90x900/clock.c
+++ b/arch/arm/mach-w90x900/clock.c
@@ -46,6 +46,9 @@ void clk_disable(struct clk *clk)
 {
 	unsigned long flags;
 
+	if (!clk)
+		return;
+
 	WARN_ON(clk->enabled == 0);
 
 	spin_lock_irqsave(&clocks_lock, flags);
-- 
2.7.4

[toc] | [prev] | [next] | [standalone]


#1613199 — Re: [PATCH v5 2/3] ARM: w90x900: let clk_disable() return immediately if clk is NULL

FromArnd Bergmann <arnd@arndb.de>
Date2017-03-30 17:40 +0200
SubjectRe: [PATCH v5 2/3] ARM: w90x900: let clk_disable() return immediately if clk is NULL
Message-ID<tqKl4-8nZ-29@gated-at.bofh.it>
In reply to#1610475
On Tue, Mar 28, 2017 at 11:17 AM, Masahiro Yamada
<yamada.masahiro@socionext.com> wrote:
> In many of clk_disable() implementations, it is a no-op for a NULL
> pointer input, but this is one of the exceptions.
>
> Making it treewide consistent will allow clock consumers to call
> clk_disable() without NULL pointer check.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> Acked-by: Wan Zongshun <mcuos.com@gmail.com>
> ---

Applied to next/fixes-non-critical in arm-soc, I don't think anybody else
was going to apply it. Thanks!

     Arnd

[toc] | [prev] | [next] | [standalone]


#1610480 — [PATCH v5 1/3] ARM: mmp: let clk_disable() return immediately if clk is NULL

FromMasahiro Yamada <yamada.masahiro@socionext.com>
Date2017-03-28 11:30 +0200
Subject[PATCH v5 1/3] ARM: mmp: let clk_disable() return immediately if clk is NULL
Message-ID<tpVBW-5sY-61@gated-at.bofh.it>
In reply to#1610473
In many of clk_disable() implementations, it is a no-op for a NULL
pointer input, but this is one of the exceptions.

Making it treewide consistent will allow clock consumers to call
clk_disable() without NULL pointer check.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---

Changes in v5:
  - None

Changes in v4:
  - Split into per-arch patches

Changes in v3:
  - Return only when clk is NULL.  Do not take care of error pointer.

Changes in v2:
  - Rebase on Linux 4.6-rc1

 arch/arm/mach-mmp/clock.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/arm/mach-mmp/clock.c b/arch/arm/mach-mmp/clock.c
index ac6633d..28fe64c 100644
--- a/arch/arm/mach-mmp/clock.c
+++ b/arch/arm/mach-mmp/clock.c
@@ -67,6 +67,9 @@ void clk_disable(struct clk *clk)
 {
 	unsigned long flags;
 
+	if (!clk)
+		return;
+
 	WARN_ON(clk->enabled == 0);
 
 	spin_lock_irqsave(&clocks_lock, flags);
-- 
2.7.4

[toc] | [prev] | [next] | [standalone]


#1613195 — Re: [PATCH v5 1/3] ARM: mmp: let clk_disable() return immediately if clk is NULL

FromArnd Bergmann <arnd@arndb.de>
Date2017-03-30 17:40 +0200
SubjectRe: [PATCH v5 1/3] ARM: mmp: let clk_disable() return immediately if clk is NULL
Message-ID<tqKl3-8nZ-11@gated-at.bofh.it>
In reply to#1610480
On Tue, Mar 28, 2017 at 11:17 AM, Masahiro Yamada
<yamada.masahiro@socionext.com> wrote:
> In many of clk_disable() implementations, it is a no-op for a NULL
> pointer input, but this is one of the exceptions.
>
> Making it treewide consistent will allow clock consumers to call
> clk_disable() without NULL pointer check.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> ---
>
Applied to next/fixes-non-critical, thanks

     Arnd

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web