]> git.proxmox.com Git - mirror_ubuntu-impish-kernel.git/commit
UBUNTU: SAUCE: ptp: free ptp clock properly
authorAndrea Righi <andrea.righi@canonical.com>
Mon, 9 Mar 2020 17:22:40 +0000 (18:22 +0100)
committerAndrea Righi <andrea.righi@canonical.com>
Mon, 28 Jun 2021 06:03:51 +0000 (08:03 +0200)
commita7a6facf58d4d26ccbd15e062f1422a6d8bb1fed
tree06a138ed1636f0dfaa9165f5b789a657e641e800
parent963f3ea7375069dcc4a23468eab3f1958f87066e
UBUNTU: SAUCE: ptp: free ptp clock properly

There is a bug in ptp_clock_unregister() where pps_unregister_source()
can free up resources needed by posix_clock_unregister() to properly
destroy a related sysfs device.

Fix this by calling pps_unregister_source() in ptp_clock_release().

See also:
commit 75718584cb3c ("ptp: free ptp device pin descriptors properly").

BugLink: https://bugs.launchpad.net/bugs/1864754
Fixes: a33121e5487b ("ptp: fix the race between the release of ptp_clock and cdev")
Tested-by: Piotr Morgwai KotarbiƄski <foss@morgwai.pl>
Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
drivers/ptp/ptp_clock.c