Subject: [PATCH v4a 09/38] timers: atm: Use timer_shutdown_sync() before freeing timer

From: Steven Rostedt <[email-masked]>
Date: Sat, 05 Nov 2022 02:00:33 -0400

From: "Steven Rostedt (Google)" <[email-masked]>

Before a timer is freed, timer_shutdown_sync() must be called.

Link: https://lore.kernel.org/all/[email-masked]/

Cc: Chas Williams <[email-masked]>
Cc: [email-masked]
Cc: [email-masked]
Signed-off-by: Steven Rostedt (Google) <[email-masked]>
---
 drivers/atm/idt77252.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/atm/idt77252.c b/drivers/atm/idt77252.c
index 681cb3786794..99cae174d558 100644
--- a/drivers/atm/idt77252.c
+++ b/drivers/atm/idt77252.c
@@ -2213,7 +2213,7 @@ idt77252_init_ubr(struct idt77252_dev *card, struct vc_map *vc,
 	}
 	spin_unlock_irqrestore(&vc->lock, flags);
 	if (est) {
-		del_timer_sync(&est->timer);
+		timer_shutdown_sync(&est->timer);
 		kfree(est);
 	}
 
@@ -3752,7 +3752,7 @@ static void __exit idt77252_exit(void)
 		card = idt77252_chain;
 		dev = card->atmdev;
 		idt77252_chain = card->next;
-		del_timer_sync(&card->tst_timer);
+		timer_shutdown_sync(&card->tst_timer);
 
 		if (dev->phy->stop)
 			dev->phy->stop(dev);
-- 
2.35.1