]> git.baikalelectronics.ru Git - kernel.git/commit
firmware: xilinx: Fix an error handling path in 'zynqmp_firmware_probe()'
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Sun, 10 May 2020 13:03:57 +0000 (15:03 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 15 May 2020 14:20:02 +0000 (16:20 +0200)
commit54c207e27370bcd628eac547d797004b0ec48430
treed54c08884c64f7e1a140407527c3a354eb1d0ceb
parent27b2c2ef3b2b68a10f841c0345d4525180689c21
firmware: xilinx: Fix an error handling path in 'zynqmp_firmware_probe()'

If 'mfd_add_devices()' fails, we must undo 'zynqmp_pm_api_debugfs_init()'
otherwise some debugfs directory and files will be left.

Just move the call to 'zynqmp_pm_api_debugfs_init()' a few lines below to
fix the issue.

Fixes: ac501716d36a ("drivers: soc: xilinx: Add ZynqMP power domain driver")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Reviewed-by: Jolly Shah <jolly.shah@xilinx.com>
Link: https://lore.kernel.org/r/20200510130357.233364-1-christophe.jaillet@wanadoo.fr
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/firmware/xilinx/zynqmp.c