summaryrefslogtreecommitdiff
path: root/kernel/debug/debug_core.c
diff options
context:
space:
mode:
authorJosef Bacik <josef@toxicpanda.com>2026-10-27 12:06:48 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2026-11-03 13:28:53 +0100
commiteedf2cf3505c1562a2fb24f8b997056f023d242b (patch)
treeee33c9a48e4cedfded05dfa51f832e226e9b6597 /kernel/debug/debug_core.c
parent7ada442f5ef77f8d53f608a0141a5e88a888ca9f (diff)
serial: samsung: put the previous baud clock
s3c24xx_serial_getclk() returns the best baud clock with the reference which clk_get() has taken. s3c24xx_serial_set_termios() stores it in ourport->baudclk and disables the clock which was there before, but does not put it. clk_get() hands out a new handle on every call, so the new clock never equals the old one, and every call of ->set_termios() leaks a handle: a struct clk and a copy of the connection name. Whoever has the port open can repeat that at will with tcsetattr(). Put the old clock when it is replaced, and the new one in case it is not stored. Fixes: 5f5a7a5578c5 ("serial: samsung: switch to clkdev based clock lookup") Cc: stable <stable@kernel.org> Cc: Krzysztof Kozlowski <krzk@kernel.org> Cc: Peter Griffin <peter.griffin@linaro.org> Cc: Alim Akhtar <alim.akhtar@samsung.com> Cc: Jiri Slaby <jirislaby@kernel.org> Cc: Kukjin Kim <kgene.kim@samsung.com> Cc: Thomas Abraham <thomas.abraham@linaro.org> Signed-off-by: Josef Bacik <josef@toxicpanda.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Link: https://patch.msgid.link/20261027-tty-llm-v1-22-99b0202ae546@linuxfoundation.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel/debug/debug_core.c')
0 files changed, 0 insertions, 0 deletions