Re: [PATCH net] net: dsa: bcm_sf2: Fix node reference count

From: David Miller
Date: Thu Jun 18 2020 - 22:41:55 EST


From: Andrew Lunn <andrew@xxxxxxx>
Date: Thu, 18 Jun 2020 14:56:40 +0200

> That if_find_node_by_name() does a put is not very intuitive.
> Maybe document that as well in the kerneldocs?
>
> Reviewed-by: Andrew Lunn <andrew@xxxxxxx>

I've been complaining about the non-intuitiveness of the various
OF interfaces for a long time. They transfer reference counts
across objects, and that makes the logic hard to audit.

The iterators are the worst.