[PATCH 0/3] PCI: keystone: Fix device node leaks in syscon phandle parsing
From: zhaofeng2
Date: Tue Nov 10 2026 - 06:26:54 EST
From: Zhao Feng <zhaofeng2@xxxxxxxxxxxxxxxxxxxx>
ks_pcie_init_id(), ks_pcie_set_mode() and ks_pcie_am654_set_mode()
resolve the "ti,syscon-pcie-id" / "ti,syscon-pcie-mode" phandles with
of_parse_phandle_with_fixed_args(), which takes a reference on the
syscon device node, but none of them drops that reference after the
register offset has been read from args.args[0], so the syscon node
is leaked on every probe.
All three call sites were introduced by the same commit, which
switched the driver from syscon_regmap_lookup_by_phandle() to
of_parse_phandle_with_fixed_args() in order to obtain the register
offset from the phandle argument.