ata: sata_highbank: fix OF node reference leak in highbank_initialize_phys()
authorJoe Hattori <joe@pf.is.s.u-tokyo.ac.jp>
Thu, 5 Dec 2024 10:30:14 +0000 (19:30 +0900)
committerDamien Le Moal <dlemoal@kernel.org>
Mon, 9 Dec 2024 00:06:58 +0000 (09:06 +0900)
commit676fe1f6f74db988191dab5df3bf256908177072
tree2c5750b3b4d85122f8affbd5d4ff05b6334c6408
parentfac04efc5c793dccbd07e2d59af9f90b7fc0dca4
ata: sata_highbank: fix OF node reference leak in highbank_initialize_phys()

The OF node reference obtained by of_parse_phandle_with_args() is not
released on early return. Add a of_node_put() call before returning.

Fixes: 8996b89d6bc9 ("ata: add platform driver for Calxeda AHCI controller")
Signed-off-by: Joe Hattori <joe@pf.is.s.u-tokyo.ac.jp>
Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
drivers/ata/sata_highbank.c