OSDN Git Service

pinctrl: stm32: fix memory leak issue
authorAlexandre Torgue <alexandre.torgue@st.com>
Thu, 14 Feb 2019 16:54:24 +0000 (17:54 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Dec 2019 08:21:35 +0000 (09:21 +0100)
commit1ff5ee143c8ae6f383c5d6e0fb04069c12e014f6
tree1299e6a6dca3175f9f4e07f87750cabe1400fed5
parent3e777af50963bc38d816190fe07e79f519d66a0b
pinctrl: stm32: fix memory leak issue

commit cd8c9b5a49576bf28990237715bc2cb2210ac80a upstream.

configs is allocated by pinconf_generic_parse_dt_config(),
pinctrl_utils_add_map_configs() duplicates configs so it can and has to
be freed to prevent memory leaks.

Signed-off-by: Alexandre Torgue <alexandre.torgue@st.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/pinctrl/stm32/pinctrl-stm32.c