Message ID | 20221027150926.006142977@goodmis.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp286974wru; Thu, 27 Oct 2022 08:11:38 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5FAEV2tYuuO9z2VYPeVFAaXnLnQZ8lVFqxN5fVsbDl0+7KyNnvDgqHkOrB7OmjeTe713M3 X-Received: by 2002:a05:6402:10c2:b0:45c:3c87:721f with SMTP id p2-20020a05640210c200b0045c3c87721fmr47878351edu.251.1666883493624; Thu, 27 Oct 2022 08:11:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666883493; cv=none; d=google.com; s=arc-20160816; b=QxACRmqXgFHaGvGlqJwaId+22htAzGKfQBcaM2VC1r2UM3V0TMo0lmDz9YaATyBgpE nJX3akoFBgzMKY1GSlTjUq1+Nbx6XWC/6N++JCrjpl0PzGJ/MGv9qlFfBJ9wv2KNKYiS w8jhz6/OvkczCA6M9n5I/1WeCBEU+wtfXxNwYwaXJW/zMVVIDT79RoW3r78+c8SPct04 C3ihZen+f4Z1DdcIWC+fiT/WkhKLDvR9C0dqaIqvNJbcfaOkTxz90mcpQuK9LqfpQZ0V 6UaFmT4kweMgqWRMyyPpdvrdddXlqYoPGEMeY8c+4XiipWuRUDlR2ut29vYSCmkuNDE5 MzyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:subject:cc:to:from:date :user-agent:message-id; bh=hLYf6h8Gy4gj5veiRtZcD8YRllrfZbjnTqXoXZ08cGU=; b=YBU6BR4IzgLvH3moSewO+uCrYuySRv7gs2MX9/W24NBAtMdPNkBsGwb61S/CESpxiC qTATML1pyDFGswj6ioWUw2YqBuJqcAkkHwTb/j4WySNXwPjAVbLaBoFwTqdTYiJIRyTG o61xZnM+1hYFLnLaEUqLs7XZ+ZWDcQIF17zQEophFTsX/OZWQTb8+k4U4y97IXdk3lAl gU47yFW3zaowDKtGysrkN7dp9Vf3NTlzPLCLUvQk00iN0gmH1OG7D+Qu/uGX09aKvJTE ISkektSOovXJzgsNWSe4ZjAoYpPVylDAELZgBVdHGXGW3mSZYOBBC9ipqWIk2l6ohRLH ku+A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id jg42-20020a170907972a00b007418e87eea8si1754370ejc.770.2022.10.27.08.11.07; Thu, 27 Oct 2022 08:11:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236415AbiJ0PKe (ORCPT <rfc822;chrisfriedt@gmail.com> + 99 others); Thu, 27 Oct 2022 11:10:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56816 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236004AbiJ0PJP (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 27 Oct 2022 11:09:15 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B33B818F25A; Thu, 27 Oct 2022 08:09:13 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 563AFB826AC; Thu, 27 Oct 2022 15:09:12 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 056BEC43145; Thu, 27 Oct 2022 15:09:11 +0000 (UTC) Received: from rostedt by gandalf.local.home with local (Exim 4.96) (envelope-from <rostedt@goodmis.org>) id 1oo4Va-00BvUJ-0a; Thu, 27 Oct 2022 11:09:26 -0400 Message-ID: <20221027150926.006142977@goodmis.org> User-Agent: quilt/0.66 Date: Thu, 27 Oct 2022 11:05:30 -0400 From: Steven Rostedt <rostedt@goodmis.org> To: linux-kernel@vger.kernel.org Cc: Linus Torvalds <torvalds@linux-foundation.org>, Thomas Gleixner <tglx@linutronix.de>, Stephen Boyd <sboyd@kernel.org>, Guenter Roeck <linux@roeck-us.net>, "Rafael J. Wysocki" <rafael@kernel.org>, Len Brown <lenb@kernel.org>, James Morse <james.morse@arm.com>, Tony Luck <tony.luck@intel.com>, Borislav Petkov <bp@alien8.de>, Shuai Xue <xueshuai@linux.alibaba.com>, Dave Hansen <dave.hansen@linux.intel.com>, Jarkko Sakkinen <jarkko@kernel.org>, linux-acpi@vger.kernel.org Subject: [RFC][PATCH v2 05/31] timers: ACPI: Use del_timer_shutdown() before freeing timer References: <20221027150525.753064657@goodmis.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_HI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747854026307544573?= X-GMAIL-MSGID: =?utf-8?q?1747854026307544573?= |
Series |
timers: Use del_timer_shutdown() before freeing timers
|
|
Commit Message
Steven Rostedt
Oct. 27, 2022, 3:05 p.m. UTC
From: "Steven Rostedt (Google)" <rostedt@goodmis.org> Before a timer is freed, del_timer_shutdown() must be called. Link: https://lore.kernel.org/all/20220407161745.7d6754b3@gandalf.local.home/ Cc: "Rafael J. Wysocki" <rafael@kernel.org> Cc: Len Brown <lenb@kernel.org> Cc: James Morse <james.morse@arm.com> Cc: Tony Luck <tony.luck@intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Shuai Xue <xueshuai@linux.alibaba.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Jarkko Sakkinen <jarkko@kernel.org> Cc: linux-acpi@vger.kernel.org Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org> --- drivers/acpi/apei/ghes.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Comments
On Thu, Oct 27, 2022 at 5:09 PM Steven Rostedt <rostedt@goodmis.org> wrote: > > From: "Steven Rostedt (Google)" <rostedt@goodmis.org> > > Before a timer is freed, del_timer_shutdown() must be called. > > Link: https://lore.kernel.org/all/20220407161745.7d6754b3@gandalf.local.home/ > > Cc: "Rafael J. Wysocki" <rafael@kernel.org> > Cc: Len Brown <lenb@kernel.org> > Cc: James Morse <james.morse@arm.com> > Cc: Tony Luck <tony.luck@intel.com> > Cc: Borislav Petkov <bp@alien8.de> > Cc: Shuai Xue <xueshuai@linux.alibaba.com> > Cc: Dave Hansen <dave.hansen@linux.intel.com> > Cc: Jarkko Sakkinen <jarkko@kernel.org> > Cc: linux-acpi@vger.kernel.org > Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org> Please add "APEI: ghes:" to the subject after "ACPI:". Apart from this Acked-by: Rafael J. Wysocki <rafael@kernel.org> > --- > drivers/acpi/apei/ghes.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/acpi/apei/ghes.c b/drivers/acpi/apei/ghes.c > index 80ad530583c9..916b952b14d0 100644 > --- a/drivers/acpi/apei/ghes.c > +++ b/drivers/acpi/apei/ghes.c > @@ -1405,7 +1405,7 @@ static int ghes_remove(struct platform_device *ghes_dev) > ghes->flags |= GHES_EXITING; > switch (generic->notify.type) { > case ACPI_HEST_NOTIFY_POLLED: > - del_timer_sync(&ghes->timer); > + del_timer_shutdown(&ghes->timer); > break; > case ACPI_HEST_NOTIFY_EXTERNAL: > free_irq(ghes->irq, ghes); > -- > 2.35.1
On Thu, Oct 27, 2022 at 11:05:30AM -0400, Steven Rostedt wrote: > From: "Steven Rostedt (Google)" <rostedt@goodmis.org> > > Before a timer is freed, del_timer_shutdown() must be called. > > Link: https://lore.kernel.org/all/20220407161745.7d6754b3@gandalf.local.home/ > > Cc: "Rafael J. Wysocki" <rafael@kernel.org> > Cc: Len Brown <lenb@kernel.org> > Cc: James Morse <james.morse@arm.com> > Cc: Tony Luck <tony.luck@intel.com> > Cc: Borislav Petkov <bp@alien8.de> > Cc: Shuai Xue <xueshuai@linux.alibaba.com> > Cc: Dave Hansen <dave.hansen@linux.intel.com> > Cc: Jarkko Sakkinen <jarkko@kernel.org> > Cc: linux-acpi@vger.kernel.org > Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org> > --- > drivers/acpi/apei/ghes.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/acpi/apei/ghes.c b/drivers/acpi/apei/ghes.c > index 80ad530583c9..916b952b14d0 100644 > --- a/drivers/acpi/apei/ghes.c > +++ b/drivers/acpi/apei/ghes.c > @@ -1405,7 +1405,7 @@ static int ghes_remove(struct platform_device *ghes_dev) > ghes->flags |= GHES_EXITING; > switch (generic->notify.type) { > case ACPI_HEST_NOTIFY_POLLED: > - del_timer_sync(&ghes->timer); > + del_timer_shutdown(&ghes->timer); > break; > case ACPI_HEST_NOTIFY_EXTERNAL: > free_irq(ghes->irq, ghes); > -- > 2.35.1 Acked-by: Jarkko Sakkinen <jarkko@kernel.org> BR, Jarkko
diff --git a/drivers/acpi/apei/ghes.c b/drivers/acpi/apei/ghes.c index 80ad530583c9..916b952b14d0 100644 --- a/drivers/acpi/apei/ghes.c +++ b/drivers/acpi/apei/ghes.c @@ -1405,7 +1405,7 @@ static int ghes_remove(struct platform_device *ghes_dev) ghes->flags |= GHES_EXITING; switch (generic->notify.type) { case ACPI_HEST_NOTIFY_POLLED: - del_timer_sync(&ghes->timer); + del_timer_shutdown(&ghes->timer); break; case ACPI_HEST_NOTIFY_EXTERNAL: free_irq(ghes->irq, ghes);