Re: [PATCH V3 1/2] amba: bus: fix refcount leak

From: Linus Walleij
Date: Wed Aug 23 2023 - 04:27:29 EST


On Mon, Aug 21, 2023 at 4:34 AM Peng Fan (OSS) <peng.fan@xxxxxxxxxxx> wrote:

> From: Peng Fan <peng.fan@xxxxxxx>
>
> commit 5de1540b7bc4 ("drivers/amba: create devices from device tree")
> increases the refcount of of_node, but not releases it in
> amba_device_release, so there is refcount leak. By using of_node_put
> to avoid refcount leak.
>
> Fixes: 5de1540b7bc4 ("drivers/amba: create devices from device tree")
> Signed-off-by: Peng Fan <peng.fan@xxxxxxx>

Makes sense.
Reviewed-by: Linus Walleij <linus.walleij@xxxxxxxxxx>

Yours,
Linus Walleij