From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DBDB6C4167B for ; Thu, 22 Dec 2022 07:55:31 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 1745F34E0; Thu, 22 Dec 2022 08:54:40 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 1745F34E0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1671695730; bh=hTuIjHBHd+Tec1DAOqqIPFW5jFXlpQ7ZWnftXs2hg6Q=; h=From:To:Subject:References:Date:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: Cc:From; b=pQj9IcXlVx+U1jmpK0433qVYZKUATskzAisEcQ1cHKy6CXB5tAu4LVVo+9lPIqGLv fzIUW4/6CiE3AW9AUViNvS5JBhLy2G9fuOLrTpjWD3SzPvitfb4wEoAJncauAPBpxp sBp/7ApKX1j6HjOqyXhi6fqffLSA1vbI75UjH9mo= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 6605CF8056F; Thu, 22 Dec 2022 08:52:15 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 07B39F8047B; Wed, 21 Dec 2022 19:48:04 +0100 (CET) Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 4AC11F801C1 for ; Wed, 21 Dec 2022 19:48:02 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 4AC11F801C1 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=XiS53svt 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 E71FD618E5; Wed, 21 Dec 2022 18:47:59 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0F6C4C433EF; Wed, 21 Dec 2022 18:47:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671648479; bh=hTuIjHBHd+Tec1DAOqqIPFW5jFXlpQ7ZWnftXs2hg6Q=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=XiS53svtnGlZKUpJLWpjIb00pvlTavkGyE/yhXeS7hKFYS8V/5Xav/+mlpRGezW6h BljUFnHKQWw/igsJKn42+z68Zwy3Z5sPZrjhFME/Kwqkbwjx7njFSsJY/zjJWCYIs2 hg7VB/Upxxl01DViL7TGCOLjNQW9ZDg1YFt1aai4iFOc2yVu8ujua8wy7VEyZXvui4 /1bJ/zTi5VZkqa0c9me5b9nyIRR+8AGM7a6aXGScjL7jgysNOOGh6mrX4vs3UGAGXF 1s0aX5L7Ze9A8zWY2oezGwBJF7QaIiwiLIJLyqjhe4qpPeepExO7oc4XqzOCONcDBc /pYLvZHxEpyuQ== From: Kalle Valo To: Steven Rostedt Subject: Re: [PATCH] treewide: Convert del_timer*() to timer_shutdown*() References: <20221220134519.3dd1318b@gandalf.local.home> Date: Wed, 21 Dec 2022 20:47:50 +0200 In-Reply-To: <20221220134519.3dd1318b@gandalf.local.home> (Steven Rostedt's message of "Tue, 20 Dec 2022 13:45:19 -0500") Message-ID: <87mt7gk2zt.fsf@kernel.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Mailman-Approved-At: Thu, 22 Dec 2022 08:52:08 +0100 X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alsa-devel@alsa-project.org, linux-staging@lists.linux.dev, linux-sh@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-leds@vger.kernel.org, drbd-dev@lists.linbit.com, linux-nilfs@vger.kernel.org, linux-scsi@vger.kernel.org, linux-atm-general@lists.sourceforge.net, lvs-devel@vger.kernel.org, linux-acpi@vger.kernel.org, SHA-cyfmac-dev-list@infineon.com, coreteam@netfilter.org, intel-wired-lan@lists.osuosl.org, linux-input@vger.kernel.org, tipc-discussion@lists.sourceforge.net, linux-ext4@vger.kernel.org, Guenter Roeck , linux-media@vger.kernel.org, bridge@lists.linux-foundation.org, intel-gfx@lists.freedesktop.org, linux-nfs@vger.kernel.org, linux-block@vger.kernel.org, cgroups@vger.kernel.org, Thomas Gleixner , Anna-Maria Gleixner , brcm80211-dev-list.pdl@broadcom.com, Stephen Boyd , netdev@vger.kernel.org, linux-usb@vger.kernel.org, linux-wireless@vger.kernel.org, LKML , Julia Lawall , linux-bluetooth@vger.kernel.org, netfilter-devel@vger.kernel.org, Andrew Morton , Linus Torvalds Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Steven Rostedt writes: > [ > Linus, > > I ran the script against your latest master branch: > commit b6bb9676f2165d518b35ba3bea5f1fcfc0d969bf > > As the timer_shutdown*() code is now in your tree, I figured > we can start doing the conversions. At least add the trivial ones > now as Thomas suggested that this gets applied at the end of the > merge window, to avoid conflicts with linux-next during the > development cycle. I can wait to Friday to run it again, and > resubmit. > > What is the best way to handle this? > ] > > From: "Steven Rostedt (Google)" > > Due to several bugs caused by timers being re-armed after they are > shutdown and just before they are freed, a new state of timers was added > called "shutdown". After a timer is set to this state, then it can no > longer be re-armed. > > The following script was run to find all the trivial locations where > del_timer() or del_timer_sync() is called in the same function that the > object holding the timer is freed. It also ignores any locations where the > timer->function is modified between the del_timer*() and the free(), as > that is not considered a "trivial" case. > > This was created by using a coccinelle script and the following commands: > > $ cat timer.cocci > @@ > expression ptr, slab; > identifier timer, rfield; > @@ > ( > - del_timer(&ptr->timer); > + timer_shutdown(&ptr->timer); > | > - del_timer_sync(&ptr->timer); > + timer_shutdown_sync(&ptr->timer); > ) > ... when strict > when != ptr->timer > ( > kfree_rcu(ptr, rfield); > | > kmem_cache_free(slab, ptr); > | > kfree(ptr); > ) > > $ spatch timer.cocci . > /tmp/t.patch > $ patch -p1 < /tmp/t.patch > > Link: https://lore.kernel.org/lkml/20221123201306.823305113@linutronix.de/ > > Signed-off-by: Steven Rostedt (Google) For wireless: > .../broadcom/brcm80211/brcmfmac/btcoex.c | 2 +- > drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c | 2 +- > drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 2 +- > drivers/net/wireless/intersil/hostap/hostap_ap.c | 2 +- > drivers/net/wireless/marvell/mwifiex/main.c | 2 +- > drivers/net/wireless/microchip/wilc1000/hif.c | 6 +++--- Acked-by: Kalle Valo -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 23400418A1 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 0094641730 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671648479; bh=hTuIjHBHd+Tec1DAOqqIPFW5jFXlpQ7ZWnftXs2hg6Q=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=XiS53svtnGlZKUpJLWpjIb00pvlTavkGyE/yhXeS7hKFYS8V/5Xav/+mlpRGezW6h BljUFnHKQWw/igsJKn42+z68Zwy3Z5sPZrjhFME/Kwqkbwjx7njFSsJY/zjJWCYIs2 hg7VB/Upxxl01DViL7TGCOLjNQW9ZDg1YFt1aai4iFOc2yVu8ujua8wy7VEyZXvui4 /1bJ/zTi5VZkqa0c9me5b9nyIRR+8AGM7a6aXGScjL7jgysNOOGh6mrX4vs3UGAGXF 1s0aX5L7Ze9A8zWY2oezGwBJF7QaIiwiLIJLyqjhe4qpPeepExO7oc4XqzOCONcDBc /pYLvZHxEpyuQ== From: Kalle Valo References: <20221220134519.3dd1318b@gandalf.local.home> Date: Wed, 21 Dec 2022 20:47:50 +0200 In-Reply-To: <20221220134519.3dd1318b@gandalf.local.home> (Steven Rostedt's message of "Tue, 20 Dec 2022 13:45:19 -0500") Message-ID: <87mt7gk2zt.fsf@kernel.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Bridge] [PATCH] treewide: Convert del_timer*() to timer_shutdown*() List-Id: Linux Ethernet Bridging List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Steven Rostedt Cc: alsa-devel@alsa-project.org, linux-staging@lists.linux.dev, linux-sh@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-leds@vger.kernel.org, drbd-dev@lists.linbit.com, linux-nilfs@vger.kernel.org, linux-scsi@vger.kernel.org, linux-atm-general@lists.sourceforge.net, lvs-devel@vger.kernel.org, linux-acpi@vger.kernel.org, SHA-cyfmac-dev-list@infineon.com, coreteam@netfilter.org, intel-wired-lan@lists.osuosl.org, linux-input@vger.kernel.org, tipc-discussion@lists.sourceforge.net, linux-ext4@vger.kernel.org, Guenter Roeck , linux-media@vger.kernel.org, bridge@lists.linux-foundation.org, intel-gfx@lists.freedesktop.org, linux-nfs@vger.kernel.org, linux-block@vger.kernel.org, cgroups@vger.kernel.org, Thomas Gleixner , Anna-Maria Gleixner , brcm80211-dev-list.pdl@broadcom.com, Stephen Boyd , netdev@vger.kernel.org, linux-usb@vger.kernel.org, linux-wireless@vger.kernel.org, LKML , Julia Lawall , linux-bluetooth@vger.kernel.org, netfilter-devel@vger.kernel.org, Andrew Morton , Linus Torvalds Steven Rostedt writes: > [ > Linus, > > I ran the script against your latest master branch: > commit b6bb9676f2165d518b35ba3bea5f1fcfc0d969bf > > As the timer_shutdown*() code is now in your tree, I figured > we can start doing the conversions. At least add the trivial ones > now as Thomas suggested that this gets applied at the end of the > merge window, to avoid conflicts with linux-next during the > development cycle. I can wait to Friday to run it again, and > resubmit. > > What is the best way to handle this? > ] > > From: "Steven Rostedt (Google)" > > Due to several bugs caused by timers being re-armed after they are > shutdown and just before they are freed, a new state of timers was added > called "shutdown". After a timer is set to this state, then it can no > longer be re-armed. > > The following script was run to find all the trivial locations where > del_timer() or del_timer_sync() is called in the same function that the > object holding the timer is freed. It also ignores any locations where the > timer->function is modified between the del_timer*() and the free(), as > that is not considered a "trivial" case. > > This was created by using a coccinelle script and the following commands: > > $ cat timer.cocci > @@ > expression ptr, slab; > identifier timer, rfield; > @@ > ( > - del_timer(&ptr->timer); > + timer_shutdown(&ptr->timer); > | > - del_timer_sync(&ptr->timer); > + timer_shutdown_sync(&ptr->timer); > ) > ... when strict > when != ptr->timer > ( > kfree_rcu(ptr, rfield); > | > kmem_cache_free(slab, ptr); > | > kfree(ptr); > ) > > $ spatch timer.cocci . > /tmp/t.patch > $ patch -p1 < /tmp/t.patch > > Link: https://lore.kernel.org/lkml/20221123201306.823305113@linutronix.de/ > > Signed-off-by: Steven Rostedt (Google) For wireless: > .../broadcom/brcm80211/brcmfmac/btcoex.c | 2 +- > drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c | 2 +- > drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 2 +- > drivers/net/wireless/intersil/hostap/hostap_ap.c | 2 +- > drivers/net/wireless/marvell/mwifiex/main.c | 2 +- > drivers/net/wireless/microchip/wilc1000/hif.c | 6 +++--- Acked-by: Kalle Valo -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kalle Valo Subject: Re: [PATCH] treewide: Convert del_timer*() to timer_shutdown*() Date: Wed, 21 Dec 2022 20:47:50 +0200 Message-ID: <87mt7gk2zt.fsf@kernel.org> References: <20221220134519.3dd1318b@gandalf.local.home> Mime-Version: 1.0 Return-path: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671648479; bh=hTuIjHBHd+Tec1DAOqqIPFW5jFXlpQ7ZWnftXs2hg6Q=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=XiS53svtnGlZKUpJLWpjIb00pvlTavkGyE/yhXeS7hKFYS8V/5Xav/+mlpRGezW6h BljUFnHKQWw/igsJKn42+z68Zwy3Z5sPZrjhFME/Kwqkbwjx7njFSsJY/zjJWCYIs2 hg7VB/Upxxl01DViL7TGCOLjNQW9ZDg1YFt1aai4iFOc2yVu8ujua8wy7VEyZXvui4 /1bJ/zTi5VZkqa0c9me5b9nyIRR+8AGM7a6aXGScjL7jgysNOOGh6mrX4vs3UGAGXF 1s0aX5L7Ze9A8zWY2oezGwBJF7QaIiwiLIJLyqjhe4qpPeepExO7oc4XqzOCONcDBc /pYLvZHxEpyuQ== In-Reply-To: <20221220134519.3dd1318b@gandalf.local.home> (Steven Rostedt's message of "Tue, 20 Dec 2022 13:45:19 -0500") List-ID: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Steven Rostedt Cc: Linus Torvalds , Thomas Gleixner , LKML , Stephen Boyd , Guenter Roeck , Anna-Maria Gleixner , Andrew Morton , Julia Lawall , linux-sh@vger.kernel.org, cgroups@vger.kernel.org, linux-block@vger.kernel.org, linux-acpi@vger.kernel.org, linux-atm-general@lists.sourceforge.net, netdev@vger.kernel.org, drbd-dev@lists.linbit.com, linux-bluetooth@vger.kernel.org, intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-input@vger.kernel.org, linux-leds@vger.kernel.org, linux-media@vger.kernel.org, intel-wired-lan@lists.osuosl.org, linux-usb@vger.kernel.org, linux-wir Steven Rostedt writes: > [ > Linus, > > I ran the script against your latest master branch: > commit b6bb9676f2165d518b35ba3bea5f1fcfc0d969bf > > As the timer_shutdown*() code is now in your tree, I figured > we can start doing the conversions. At least add the trivial ones > now as Thomas suggested that this gets applied at the end of the > merge window, to avoid conflicts with linux-next during the > development cycle. I can wait to Friday to run it again, and > resubmit. > > What is the best way to handle this? > ] > > From: "Steven Rostedt (Google)" > > Due to several bugs caused by timers being re-armed after they are > shutdown and just before they are freed, a new state of timers was added > called "shutdown". After a timer is set to this state, then it can no > longer be re-armed. > > The following script was run to find all the trivial locations where > del_timer() or del_timer_sync() is called in the same function that the > object holding the timer is freed. It also ignores any locations where the > timer->function is modified between the del_timer*() and the free(), as > that is not considered a "trivial" case. > > This was created by using a coccinelle script and the following commands: > > $ cat timer.cocci > @@ > expression ptr, slab; > identifier timer, rfield; > @@ > ( > - del_timer(&ptr->timer); > + timer_shutdown(&ptr->timer); > | > - del_timer_sync(&ptr->timer); > + timer_shutdown_sync(&ptr->timer); > ) > ... when strict > when != ptr->timer > ( > kfree_rcu(ptr, rfield); > | > kmem_cache_free(slab, ptr); > | > kfree(ptr); > ) > > $ spatch timer.cocci . > /tmp/t.patch > $ patch -p1 < /tmp/t.patch > > Link: https://lore.kernel.org/lkml/20221123201306.823305113@linutronix.de/ > > Signed-off-by: Steven Rostedt (Google) For wireless: > .../broadcom/brcm80211/brcmfmac/btcoex.c | 2 +- > drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c | 2 +- > drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 2 +- > drivers/net/wireless/intersil/hostap/hostap_ap.c | 2 +- > drivers/net/wireless/marvell/mwifiex/main.c | 2 +- > drivers/net/wireless/microchip/wilc1000/hif.c | 6 +++--- Acked-by: Kalle Valo -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A9E5DC46467 for ; Wed, 21 Dec 2022 18:48:06 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 2C20B41730; Wed, 21 Dec 2022 18:48:06 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 2C20B41730 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=osuosl.org; s=default; t=1671648486; bh=6ZzmcaMWESGBTF6Q1t2YQndiVZTGnnjaQvH6Pb3mWNA=; h=From:To:References:Date:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: Cc:From; b=2Dmsnn5kraQr63eBifOb0W7ukLGXV9+ZQGEgpJb7pmIQRmBUA8JO6dXjaZgu4JIDg HITyR4XMc6RhfbXDSwqXsoloI6plSmW/6e4GEVU/UrRcECq/aFpP+DEH5Wnj+x2PDF EM1SYk9rCCo7xs/voYyUM8sIqRum5yVmq2oxJqw1zN+5lLVwDmP/7rAMhH5PKfCPr3 PJ0dtVikR+UMpFHR1qAiV4mIj4IB61C8bSBy0vYG4x7SOQnxqjz/ICxhcAzH7l0w6X FU+kXb8IK+1kpsTCHQ6wHTPdl7yJRaS3ka9Bu0pSQoqB9VV3BMgzbIklgd3eE3ah6R yvgYw6wgYGyPw== X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id PXrSeZP3gY4t; Wed, 21 Dec 2022 18:48:05 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id E8BD1418A1; Wed, 21 Dec 2022 18:48:04 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org E8BD1418A1 Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 304851BF3A6 for ; Wed, 21 Dec 2022 18:48:03 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 0684E81DF8 for ; Wed, 21 Dec 2022 18:48:03 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 0684E81DF8 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dbXZWURTTE82 for ; Wed, 21 Dec 2022 18:48:01 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org F2CF581D34 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by smtp1.osuosl.org (Postfix) with ESMTPS id F2CF581D34 for ; Wed, 21 Dec 2022 18:48:00 +0000 (UTC) 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 E71FD618E5; Wed, 21 Dec 2022 18:47:59 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0F6C4C433EF; Wed, 21 Dec 2022 18:47:52 +0000 (UTC) From: Kalle Valo To: Steven Rostedt References: <20221220134519.3dd1318b@gandalf.local.home> Date: Wed, 21 Dec 2022 20:47:50 +0200 In-Reply-To: <20221220134519.3dd1318b@gandalf.local.home> (Steven Rostedt's message of "Tue, 20 Dec 2022 13:45:19 -0500") Message-ID: <87mt7gk2zt.fsf@kernel.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671648479; bh=hTuIjHBHd+Tec1DAOqqIPFW5jFXlpQ7ZWnftXs2hg6Q=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=XiS53svtnGlZKUpJLWpjIb00pvlTavkGyE/yhXeS7hKFYS8V/5Xav/+mlpRGezW6h BljUFnHKQWw/igsJKn42+z68Zwy3Z5sPZrjhFME/Kwqkbwjx7njFSsJY/zjJWCYIs2 hg7VB/Upxxl01DViL7TGCOLjNQW9ZDg1YFt1aai4iFOc2yVu8ujua8wy7VEyZXvui4 /1bJ/zTi5VZkqa0c9me5b9nyIRR+8AGM7a6aXGScjL7jgysNOOGh6mrX4vs3UGAGXF 1s0aX5L7Ze9A8zWY2oezGwBJF7QaIiwiLIJLyqjhe4qpPeepExO7oc4XqzOCONcDBc /pYLvZHxEpyuQ== X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=XiS53svt Subject: Re: [Intel-wired-lan] [PATCH] treewide: Convert del_timer*() to timer_shutdown*() X-BeenThere: intel-wired-lan@osuosl.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Wired Ethernet Linux Kernel Driver Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alsa-devel@alsa-project.org, linux-staging@lists.linux.dev, linux-sh@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-leds@vger.kernel.org, drbd-dev@lists.linbit.com, linux-nilfs@vger.kernel.org, linux-scsi@vger.kernel.org, linux-atm-general@lists.sourceforge.net, lvs-devel@vger.kernel.org, linux-acpi@vger.kernel.org, SHA-cyfmac-dev-list@infineon.com, coreteam@netfilter.org, intel-wired-lan@lists.osuosl.org, linux-input@vger.kernel.org, tipc-discussion@lists.sourceforge.net, linux-ext4@vger.kernel.org, Guenter Roeck , linux-media@vger.kernel.org, bridge@lists.linux-foundation.org, intel-gfx@lists.freedesktop.org, linux-nfs@vger.kernel.org, linux-block@vger.kernel.org, cgroups@vger.kernel.org, Thomas Gleixner , Anna-Maria Gleixner , brcm80211-dev-list.pdl@broadcom.com, Stephen Boyd , netdev@vger.kernel.org, linux-usb@vger.kernel.org, linux-wireless@vger.kernel.org, LKML , Julia Lawall , linux-bluetooth@vger.kernel.org, netfilter-devel@vger.kernel.org, Andrew Morton , Linus Torvalds Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: intel-wired-lan-bounces@osuosl.org Sender: "Intel-wired-lan" Steven Rostedt writes: > [ > Linus, > > I ran the script against your latest master branch: > commit b6bb9676f2165d518b35ba3bea5f1fcfc0d969bf > > As the timer_shutdown*() code is now in your tree, I figured > we can start doing the conversions. At least add the trivial ones > now as Thomas suggested that this gets applied at the end of the > merge window, to avoid conflicts with linux-next during the > development cycle. I can wait to Friday to run it again, and > resubmit. > > What is the best way to handle this? > ] > > From: "Steven Rostedt (Google)" > > Due to several bugs caused by timers being re-armed after they are > shutdown and just before they are freed, a new state of timers was added > called "shutdown". After a timer is set to this state, then it can no > longer be re-armed. > > The following script was run to find all the trivial locations where > del_timer() or del_timer_sync() is called in the same function that the > object holding the timer is freed. It also ignores any locations where the > timer->function is modified between the del_timer*() and the free(), as > that is not considered a "trivial" case. > > This was created by using a coccinelle script and the following commands: > > $ cat timer.cocci > @@ > expression ptr, slab; > identifier timer, rfield; > @@ > ( > - del_timer(&ptr->timer); > + timer_shutdown(&ptr->timer); > | > - del_timer_sync(&ptr->timer); > + timer_shutdown_sync(&ptr->timer); > ) > ... when strict > when != ptr->timer > ( > kfree_rcu(ptr, rfield); > | > kmem_cache_free(slab, ptr); > | > kfree(ptr); > ) > > $ spatch timer.cocci . > /tmp/t.patch > $ patch -p1 < /tmp/t.patch > > Link: https://lore.kernel.org/lkml/20221123201306.823305113@linutronix.de/ > > Signed-off-by: Steven Rostedt (Google) For wireless: > .../broadcom/brcm80211/brcmfmac/btcoex.c | 2 +- > drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c | 2 +- > drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 2 +- > drivers/net/wireless/intersil/hostap/hostap_ap.c | 2 +- > drivers/net/wireless/marvell/mwifiex/main.c | 2 +- > drivers/net/wireless/microchip/wilc1000/hif.c | 6 +++--- Acked-by: Kalle Valo -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches _______________________________________________ Intel-wired-lan mailing list Intel-wired-lan@osuosl.org https://lists.osuosl.org/mailman/listinfo/intel-wired-lan From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D3EC8C4332F for ; Wed, 21 Dec 2022 20:19:54 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 1DED510E4B4; Wed, 21 Dec 2022 20:19:45 +0000 (UTC) Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by gabe.freedesktop.org (Postfix) with ESMTPS id DCCDC10E47C; Wed, 21 Dec 2022 18:48:33 +0000 (UTC) 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 E71FD618E5; Wed, 21 Dec 2022 18:47:59 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0F6C4C433EF; Wed, 21 Dec 2022 18:47:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671648479; bh=hTuIjHBHd+Tec1DAOqqIPFW5jFXlpQ7ZWnftXs2hg6Q=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=XiS53svtnGlZKUpJLWpjIb00pvlTavkGyE/yhXeS7hKFYS8V/5Xav/+mlpRGezW6h BljUFnHKQWw/igsJKn42+z68Zwy3Z5sPZrjhFME/Kwqkbwjx7njFSsJY/zjJWCYIs2 hg7VB/Upxxl01DViL7TGCOLjNQW9ZDg1YFt1aai4iFOc2yVu8ujua8wy7VEyZXvui4 /1bJ/zTi5VZkqa0c9me5b9nyIRR+8AGM7a6aXGScjL7jgysNOOGh6mrX4vs3UGAGXF 1s0aX5L7Ze9A8zWY2oezGwBJF7QaIiwiLIJLyqjhe4qpPeepExO7oc4XqzOCONcDBc /pYLvZHxEpyuQ== From: Kalle Valo To: Steven Rostedt References: <20221220134519.3dd1318b@gandalf.local.home> Date: Wed, 21 Dec 2022 20:47:50 +0200 In-Reply-To: <20221220134519.3dd1318b@gandalf.local.home> (Steven Rostedt's message of "Tue, 20 Dec 2022 13:45:19 -0500") Message-ID: <87mt7gk2zt.fsf@kernel.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Mailman-Approved-At: Wed, 21 Dec 2022 20:19:41 +0000 Subject: Re: [Intel-gfx] [PATCH] treewide: Convert del_timer*() to timer_shutdown*() X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alsa-devel@alsa-project.org, linux-staging@lists.linux.dev, linux-sh@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-leds@vger.kernel.org, drbd-dev@lists.linbit.com, linux-nilfs@vger.kernel.org, linux-scsi@vger.kernel.org, linux-atm-general@lists.sourceforge.net, lvs-devel@vger.kernel.org, linux-acpi@vger.kernel.org, SHA-cyfmac-dev-list@infineon.com, coreteam@netfilter.org, intel-wired-lan@lists.osuosl.org, linux-input@vger.kernel.org, tipc-discussion@lists.sourceforge.net, linux-ext4@vger.kernel.org, Guenter Roeck , linux-media@vger.kernel.org, bridge@lists.linux-foundation.org, intel-gfx@lists.freedesktop.org, linux-nfs@vger.kernel.org, linux-block@vger.kernel.org, cgroups@vger.kernel.org, Thomas Gleixner , Anna-Maria Gleixner , brcm80211-dev-list.pdl@broadcom.com, Stephen Boyd , netdev@vger.kernel.org, linux-usb@vger.kernel.org, linux-wireless@vger.kernel.org, LKML , Julia Lawall , linux-bluetooth@vger.kernel.org, netfilter-devel@vger.kernel.org, Andrew Morton , Linus Torvalds Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Steven Rostedt writes: > [ > Linus, > > I ran the script against your latest master branch: > commit b6bb9676f2165d518b35ba3bea5f1fcfc0d969bf > > As the timer_shutdown*() code is now in your tree, I figured > we can start doing the conversions. At least add the trivial ones > now as Thomas suggested that this gets applied at the end of the > merge window, to avoid conflicts with linux-next during the > development cycle. I can wait to Friday to run it again, and > resubmit. > > What is the best way to handle this? > ] > > From: "Steven Rostedt (Google)" > > Due to several bugs caused by timers being re-armed after they are > shutdown and just before they are freed, a new state of timers was added > called "shutdown". After a timer is set to this state, then it can no > longer be re-armed. > > The following script was run to find all the trivial locations where > del_timer() or del_timer_sync() is called in the same function that the > object holding the timer is freed. It also ignores any locations where the > timer->function is modified between the del_timer*() and the free(), as > that is not considered a "trivial" case. > > This was created by using a coccinelle script and the following commands: > > $ cat timer.cocci > @@ > expression ptr, slab; > identifier timer, rfield; > @@ > ( > - del_timer(&ptr->timer); > + timer_shutdown(&ptr->timer); > | > - del_timer_sync(&ptr->timer); > + timer_shutdown_sync(&ptr->timer); > ) > ... when strict > when != ptr->timer > ( > kfree_rcu(ptr, rfield); > | > kmem_cache_free(slab, ptr); > | > kfree(ptr); > ) > > $ spatch timer.cocci . > /tmp/t.patch > $ patch -p1 < /tmp/t.patch > > Link: https://lore.kernel.org/lkml/20221123201306.823305113@linutronix.de/ > > Signed-off-by: Steven Rostedt (Google) For wireless: > .../broadcom/brcm80211/brcmfmac/btcoex.c | 2 +- > drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c | 2 +- > drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 2 +- > drivers/net/wireless/intersil/hostap/hostap_ap.c | 2 +- > drivers/net/wireless/marvell/mwifiex/main.c | 2 +- > drivers/net/wireless/microchip/wilc1000/hif.c | 6 +++--- Acked-by: Kalle Valo -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3EFF8C4167B for ; Wed, 21 Dec 2022 18:48:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234565AbiLUSsD (ORCPT ); Wed, 21 Dec 2022 13:48:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49808 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234296AbiLUSsC (ORCPT ); Wed, 21 Dec 2022 13:48:02 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CA2E01E70C; Wed, 21 Dec 2022 10:48:01 -0800 (PST) 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 8D247B81BA6; Wed, 21 Dec 2022 18:48:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0F6C4C433EF; Wed, 21 Dec 2022 18:47:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671648479; bh=hTuIjHBHd+Tec1DAOqqIPFW5jFXlpQ7ZWnftXs2hg6Q=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=XiS53svtnGlZKUpJLWpjIb00pvlTavkGyE/yhXeS7hKFYS8V/5Xav/+mlpRGezW6h BljUFnHKQWw/igsJKn42+z68Zwy3Z5sPZrjhFME/Kwqkbwjx7njFSsJY/zjJWCYIs2 hg7VB/Upxxl01DViL7TGCOLjNQW9ZDg1YFt1aai4iFOc2yVu8ujua8wy7VEyZXvui4 /1bJ/zTi5VZkqa0c9me5b9nyIRR+8AGM7a6aXGScjL7jgysNOOGh6mrX4vs3UGAGXF 1s0aX5L7Ze9A8zWY2oezGwBJF7QaIiwiLIJLyqjhe4qpPeepExO7oc4XqzOCONcDBc /pYLvZHxEpyuQ== From: Kalle Valo To: Steven Rostedt Cc: Linus Torvalds , Thomas Gleixner , LKML , Stephen Boyd , Guenter Roeck , Anna-Maria Gleixner , Andrew Morton , Julia Lawall , linux-sh@vger.kernel.org, cgroups@vger.kernel.org, linux-block@vger.kernel.org, linux-acpi@vger.kernel.org, linux-atm-general@lists.sourceforge.net, netdev@vger.kernel.org, drbd-dev@lists.linbit.com, linux-bluetooth@vger.kernel.org, intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-input@vger.kernel.org, linux-leds@vger.kernel.org, linux-media@vger.kernel.org, intel-wired-lan@lists.osuosl.org, linux-usb@vger.kernel.org, linux-wireless@vger.kernel.org, brcm80211-dev-list.pdl@broadcom.com, SHA-cyfmac-dev-list@infineon.com, linux-scsi@vger.kernel.org, linux-staging@lists.linux.dev, linux-ext4@vger.kernel.org, linux-nilfs@vger.kernel.org, bridge@lists.linux-foundation.org, netfilter-devel@vger.kernel.org, coreteam@netfilter.org, lvs-devel@vger.kernel.org, linux-nfs@vger.kernel.org, tipc-discussion@lists.sourceforge.net, alsa-devel@alsa-project.org Subject: Re: [PATCH] treewide: Convert del_timer*() to timer_shutdown*() References: <20221220134519.3dd1318b@gandalf.local.home> Date: Wed, 21 Dec 2022 20:47:50 +0200 In-Reply-To: <20221220134519.3dd1318b@gandalf.local.home> (Steven Rostedt's message of "Tue, 20 Dec 2022 13:45:19 -0500") Message-ID: <87mt7gk2zt.fsf@kernel.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org Steven Rostedt writes: > [ > Linus, > > I ran the script against your latest master branch: > commit b6bb9676f2165d518b35ba3bea5f1fcfc0d969bf > > As the timer_shutdown*() code is now in your tree, I figured > we can start doing the conversions. At least add the trivial ones > now as Thomas suggested that this gets applied at the end of the > merge window, to avoid conflicts with linux-next during the > development cycle. I can wait to Friday to run it again, and > resubmit. > > What is the best way to handle this? > ] > > From: "Steven Rostedt (Google)" > > Due to several bugs caused by timers being re-armed after they are > shutdown and just before they are freed, a new state of timers was added > called "shutdown". After a timer is set to this state, then it can no > longer be re-armed. > > The following script was run to find all the trivial locations where > del_timer() or del_timer_sync() is called in the same function that the > object holding the timer is freed. It also ignores any locations where the > timer->function is modified between the del_timer*() and the free(), as > that is not considered a "trivial" case. > > This was created by using a coccinelle script and the following commands: > > $ cat timer.cocci > @@ > expression ptr, slab; > identifier timer, rfield; > @@ > ( > - del_timer(&ptr->timer); > + timer_shutdown(&ptr->timer); > | > - del_timer_sync(&ptr->timer); > + timer_shutdown_sync(&ptr->timer); > ) > ... when strict > when != ptr->timer > ( > kfree_rcu(ptr, rfield); > | > kmem_cache_free(slab, ptr); > | > kfree(ptr); > ) > > $ spatch timer.cocci . > /tmp/t.patch > $ patch -p1 < /tmp/t.patch > > Link: https://lore.kernel.org/lkml/20221123201306.823305113@linutronix.de/ > > Signed-off-by: Steven Rostedt (Google) For wireless: > .../broadcom/brcm80211/brcmfmac/btcoex.c | 2 +- > drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c | 2 +- > drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 2 +- > drivers/net/wireless/intersil/hostap/hostap_ap.c | 2 +- > drivers/net/wireless/marvell/mwifiex/main.c | 2 +- > drivers/net/wireless/microchip/wilc1000/hif.c | 6 +++--- Acked-by: Kalle Valo -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by mail19.linbit.com (LINBIT Mail Daemon) with ESMTP id 0FD9942210F for ; Wed, 21 Dec 2022 19:48:00 +0100 (CET) From: Kalle Valo To: Steven Rostedt References: <20221220134519.3dd1318b@gandalf.local.home> In-Reply-To: <20221220134519.3dd1318b@gandalf.local.home> (Steven Rostedt's message of "Tue, 20 Dec 2022 13:45:19 -0500") Message-ID: <87mt7gk2zt.fsf@kernel.org> MIME-Version: 1.0 Content-Type: text/plain Cc: alsa-devel@alsa-project.org, linux-staging@lists.linux.dev, linux-sh@vger.kernel.org, dri-devel@lists.freedesktop.org, SHA-cyfmac-dev-list@infineon.com, linux-leds@vger.kernel.org, drbd-dev@lists.linbit.com, lvs-devel@vger.kernel.org, linux-nilfs@vger.kernel.org, linux-scsi@vger.kernel.org, Anna-Maria, linux-atm-general@lists.sourceforge.net, Julia Lawall , linux-acpi@vger.kernel.org, coreteam@netfilter.org, intel-wired-lan@lists.osuosl.org, linux-input@vger.kernel.org, tipc-discussion@lists.sourceforge.net, linux-ext4@vger.kernel.org, Guenter Roeck , linux-media@vger.kernel.org, bridge@lists.linux-foundation.org, intel-gfx@lists.freedesktop.org, linux-nfs@vger.kernel.org, linux-block@vger.kernel.org, cgroups@vger.kernel.org, Thomas Gleixner , Gleixner , brcm80211-dev-list.pdl@broadcom.com, Stephen Boyd , netdev@vger.kernel.org, linux-usb@vger.kernel.org, linux-wireless@vger.kernel.org, LKML , linux-bluetooth@vger.kernel.org, netfilter-devel@vger.kernel.org, Andrew Morton , Linus Torvalds Subject: Re: [Drbd-dev] [PATCH] treewide: Convert del_timer*() to timer_shutdown*() List-Id: "*Coordination* of development, patches, contributions -- *Questions* \(even to developers\) go to drbd-user, please." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Date: Wed, 21 Dec 2022 18:48:01 -0000 Steven Rostedt writes: > [ > Linus, > > I ran the script against your latest master branch: > commit b6bb9676f2165d518b35ba3bea5f1fcfc0d969bf > > As the timer_shutdown*() code is now in your tree, I figured > we can start doing the conversions. At least add the trivial ones > now as Thomas suggested that this gets applied at the end of the > merge window, to avoid conflicts with linux-next during the > development cycle. I can wait to Friday to run it again, and > resubmit. > > What is the best way to handle this? > ] > > From: "Steven Rostedt (Google)" > > Due to several bugs caused by timers being re-armed after they are > shutdown and just before they are freed, a new state of timers was added > called "shutdown". After a timer is set to this state, then it can no > longer be re-armed. > > The following script was run to find all the trivial locations where > del_timer() or del_timer_sync() is called in the same function that the > object holding the timer is freed. It also ignores any locations where the > timer->function is modified between the del_timer*() and the free(), as > that is not considered a "trivial" case. > > This was created by using a coccinelle script and the following commands: > > $ cat timer.cocci > @@ > expression ptr, slab; > identifier timer, rfield; > @@ > ( > - del_timer(&ptr->timer); > + timer_shutdown(&ptr->timer); > | > - del_timer_sync(&ptr->timer); > + timer_shutdown_sync(&ptr->timer); > ) > ... when strict > when != ptr->timer > ( > kfree_rcu(ptr, rfield); > | > kmem_cache_free(slab, ptr); > | > kfree(ptr); > ) > > $ spatch timer.cocci . > /tmp/t.patch > $ patch -p1 < /tmp/t.patch > > Link: https://lore.kernel.org/lkml/20221123201306.823305113@linutronix.de/ > > Signed-off-by: Steven Rostedt (Google) For wireless: > .../broadcom/brcm80211/brcmfmac/btcoex.c | 2 +- > drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c | 2 +- > drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 2 +- > drivers/net/wireless/intersil/hostap/hostap_ap.c | 2 +- > drivers/net/wireless/marvell/mwifiex/main.c | 2 +- > drivers/net/wireless/microchip/wilc1000/hif.c | 6 +++--- Acked-by: Kalle Valo -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches