From patchwork Fri Nov 4 05:41:22 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steven Rostedt X-Patchwork-Id: 15356 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp190910wru; Thu, 3 Nov 2022 22:51:26 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6rP+b16Q9CySLN/hfcK/jCtVUxo/CZcbIF3+WpxTuKtMM6A2+A7IV13sHf7efrlFm24/0q X-Received: by 2002:a05:6402:5296:b0:461:b6e5:ea63 with SMTP id en22-20020a056402529600b00461b6e5ea63mr33802455edb.248.1667541085855; Thu, 03 Nov 2022 22:51:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667541085; cv=none; d=google.com; s=arc-20160816; b=zCUB/ofqoxcD/tkNdmZltz33pXU9mN43fEU9DplPIhTKQcWb7oBjuNW2caicHCgQ9+ iCgWs7UOL8qrjqNWQcrzo6Tc3oJA7C+4QuVh/fDB7X9583kAcAaLqboND5wjsMB2azRq 3m1b91bXnAnHv3U81/VmLw8yJ1fBjeFTH0/SWzZbp+1EQgE1GtttRn1NLxmtV4RAlap8 eVg8UApjNNGak0syjd0otzW6tXF4UHSyhGXnRqrjbU5DQT9/aAfIciVbAY3DQELXvLZ6 iLQ/aXRMJSoFP1E8pDUL50Iz7kGl+LDdpqL2Cq2t05AqJ1KkI6EIrdggVPI9MpEQi+Cf YN2w== 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=EkndezTUktA6Z6gGptsmErohFQ2EVqk5/96mO2A+9HE=; b=T37u4Za581a930SM8qgwwAaUihqLN1kPYF9+a6ySHHI4EPgG2n94A5lpc3njC/f0w9 bSrzIKEo92Em08ZsI798io6a81eluzj1v4FmaVj9eONkN59iecBW0l2Xf57hOg80XrbC LrnEWQCyOzatXwXXdtqKAeLkXB0Ua25TrD9sTnknEe+lUG7xp4mgnXVSE2Rv8soWRMwv CanqKt38nUS7SvMu8RyOw994PfIb6A9T7C4ZIJSXcSH+7fVIOV6c9s+9hyLBNrmEINJY my+PHBemoETkXO9Kj57EQiC+Y45fn9vUIQIOgk1xUbHB4S5/6SwaPHq0SDHfYDmTz5hq yVSA== 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 m18-20020a056402511200b004574154f09asi3247664edd.529.2022.11.03.22.51.02; Thu, 03 Nov 2022 22:51:25 -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 S231759AbiKDFuX (ORCPT + 99 others); Fri, 4 Nov 2022 01:50:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55854 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231364AbiKDFsy (ORCPT ); Fri, 4 Nov 2022 01:48:54 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4561328E0C for ; Thu, 3 Nov 2022 22:48:53 -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 dfw.source.kernel.org (Postfix) with ESMTPS id E4906620DD for ; Fri, 4 Nov 2022 05:48:50 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C02EBC433C1; Fri, 4 Nov 2022 05:48:50 +0000 (UTC) Received: from rostedt by gandalf.local.home with local (Exim 4.96) (envelope-from ) id 1oqpZt-0071E9-17; Fri, 04 Nov 2022 01:49:17 -0400 Message-ID: <20221104054917.188768105@goodmis.org> User-Agent: quilt/0.66 Date: Fri, 04 Nov 2022 01:41:22 -0400 From: Steven Rostedt To: linux-kernel@vger.kernel.org Cc: Linus Torvalds , Thomas Gleixner , Stephen Boyd , Guenter Roeck , Anna-Maria Gleixner , Andrew Morton , Jaroslav Kysela , Takashi Iwai , Austin Kim , alsa-devel@alsa-project.org Subject: [RFC][PATCH v3 29/33] timers: ALSA: Use timer_shutdown_sync() before freeing timer References: <20221104054053.431922658@goodmis.org> MIME-Version: 1.0 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1748543561554307993?= X-GMAIL-MSGID: =?utf-8?q?1748543561554307993?= From: "Steven Rostedt (Google)" Before a timer is freed, timer_shutdown_sync() must be called. Link: https://lore.kernel.org/all/20220407161745.7d6754b3@gandalf.local.home/ Cc: Jaroslav Kysela Cc: Takashi Iwai Cc: Austin Kim Cc: alsa-devel@alsa-project.org Signed-off-by: Steven Rostedt (Google) Reviewed-by: Takashi Iwai --- sound/i2c/other/ak4117.c | 2 +- sound/synth/emux/emux.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/i2c/other/ak4117.c b/sound/i2c/other/ak4117.c index 1bc43e927d82..640501bb3ca6 100644 --- a/sound/i2c/other/ak4117.c +++ b/sound/i2c/other/ak4117.c @@ -47,7 +47,7 @@ static void reg_dump(struct ak4117 *ak4117) static void snd_ak4117_free(struct ak4117 *chip) { - del_timer_sync(&chip->timer); + timer_shutdown_sync(&chip->timer); kfree(chip); } diff --git a/sound/synth/emux/emux.c b/sound/synth/emux/emux.c index a870759d179e..0006c3ddb51d 100644 --- a/sound/synth/emux/emux.c +++ b/sound/synth/emux/emux.c @@ -129,7 +129,7 @@ int snd_emux_free(struct snd_emux *emu) if (! emu) return -EINVAL; - del_timer_sync(&emu->tlist); + timer_shutdown_sync(&emu->tlist); snd_emux_proc_free(emu); snd_emux_delete_virmidi(emu);