(I'm so sorry!) Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git

pinctrl: tegra: xusb: free maps on DT map failure

tegra_xusb_padctl_parse_subnode() can append mappings before a later child or configuration operation fails. The top-level callback currently returns the error while retaining all mappings allocated for earlier children. Free the accumulated map on failure. The caller ignores the output parameters when the mapping callback returns an error, so they do not need to be reset after freeing the map. Signed-off-by: Jiale Yao <yaojiale02@163.com> Signed-off-by: Linus Walleij <linusw@kernel.org>


Author Jiale Yao Committer Linus Walleij Date Commit Parent e873c665
+5 -1
1 changed file
+5 -1
1 changed file