rtc: destroy mutex when releasing the device
PATCH 1/1 rtc: destroy mutex when releasing the device
From: Bartosz Golaszewski <[email protected]>
Not destroying mutexes doesn't lead to resource leak but it's the correct thing to do for mutex debugging accounting.
Signed-off-by Bartosz Golaszewski <[email protected]>
--- drivers/rtc/class.c | 1 + 1 file changed, 1 insertion(+)
drivers/rtc/class.c +1 -0
@@ -28,6 +28,7 @@ static void rtc_device_release(struct device *dev)struct rtc_device *rtc =to_rtc_device (dev);ida_simple_remove (&rtc_ida, rtc->id); +mutex_destroy (&rtc->ops_lock);kfree (rtc); }
Signature · 1 line
2.29.1
Quoted 2 lines · Bartosz Golaszewski
Not destroying mutexes doesn't lead to resource leak but it's the correct thing to do for mutex debugging accounting.
Applied, thanks!
[1/1] rtc: destroy mutex when releasing the device
commit: b3527837a60a5dcd0c16c28804b6ec9b47f15947
Best regards,
Signature · 1 line
Alexandre Belloni <[email protected]>