Messages in this thread | | | Date | Thu, 26 May 2022 14:18:35 +0200 | From | Andrew Lunn <> | Subject | Re: [PATCH v2] net: dsa: mv88e6xxx: Fix refcount leak in mv88e6xxx_mdios_register |
| |
On Thu, May 26, 2022 at 03:24:15PM +0400, Miaoqian Lin wrote: > of_get_child_by_name() returns a node pointer with refcount > incremented, we should use of_node_put() on it when done. > This function missing of_node_put() in an error path. > Add missing of_node_put() to avoid refcount leak.
What about releasing the reference on the non error case? Where is that.
Andrew
| |