mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Alexander A. Klimov" <grandmaster@al2klimov.de>
To: "Daniel Lezcano" <daniel.lezcano@kernel.org>,
	"Thomas Gleixner" <tglx@kernel.org>,
	"Andreas Färber" <afaerber@suse.de>,
	"Manivannan Sadhasivam" <mani@kernel.org>,
	linux-kernel@vger.kernel.org (open list:CLOCKSOURCE,
	CLOCKEVENT DRIVERS),
	linux-arm-kernel@lists.infradead.org (moderated list:ARM/ACTIONS
	SEMI ARCHITECTURE),
	linux-actions@lists.infradead.org (moderated list:ARM/ACTIONS
	SEMI ARCHITECTURE)
Cc: "Alexander A. Klimov" <grandmaster@al2klimov.de>
Subject: [PATCH] clocksource/drivers/owl: fix refcount leak
Date: Thu, 21 May 2026 06:19:00 +0200	[thread overview]
Message-ID: <20260521041901.542964-1-grandmaster@al2klimov.de> (raw)

Every value returned from of_clk_get() is supposed to be cleaned up
via clk_put() once not needed anymore.

Fixes: 4be78a86c506 ("clocksource: Add Owl timer")
Signed-off-by: Alexander A. Klimov <grandmaster@al2klimov.de>
---
 drivers/clocksource/timer-owl.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/clocksource/timer-owl.c b/drivers/clocksource/timer-owl.c
index ac97420bfa7c..fa347f430563 100644
--- a/drivers/clocksource/timer-owl.c
+++ b/drivers/clocksource/timer-owl.c
@@ -142,6 +142,7 @@ static int __init owl_timer_init(struct device_node *node)
 	}
 
 	rate = clk_get_rate(clk);
+	clk_put(clk);
 
 	owl_timer_reset(owl_clksrc_base);
 	owl_timer_set_enabled(owl_clksrc_base, true);
-- 
2.54.0


             reply	other threads:[~2026-05-21  4:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-21  4:19 Alexander A. Klimov [this message]
2026-05-21 12:10 ` Markus Elfring
2026-05-22 18:20   ` Alexander A. Klimov
2026-05-22 19:25     ` Markus Elfring

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=20260521041901.542964-1-grandmaster@al2klimov.de \
    --to=grandmaster@al2klimov.de \
    --cc=afaerber@suse.de \
    --cc=daniel.lezcano@kernel.org \
    --cc=linux-actions@lists.infradead.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mani@kernel.org \
    --cc=tglx@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®