Re: [PATCH v1] clk: at91: keep securam node alive while mapping it
From: Brian Masney <bmasney@redhat.com>
Date: 2026-06-01 15:20:50
Also in:
linux-clk, lkml
From: Brian Masney <bmasney@redhat.com>
Date: 2026-06-01 15:20:50
Also in:
linux-clk, lkml
On Fri, May 29, 2026 at 12:20:51AM -0400, Yuho Choi wrote:
pmc_register_ops() gets an owned reference to the
"atmel,sama5d2-securam" node with of_find_compatible_node(). The
success path dropped that reference before passing the node to
of_iomap(), leaving of_iomap() to consume a node pointer after the caller
had released its reference.
Move of_node_put() after of_iomap() so the node remains referenced for
the mapping operation. The unavailable-node error path already releases
the reference.
Fixes: 4d21be864092 ("clk: at91: pmc: execute suspend/resume only for backup mode")
Signed-off-by: Yuho Choi <redacted>Reviewed-by: Brian Masney <bmasney@redhat.com>