Skip to contentSkip to conversation

treewide: Rename del_timer[_sync] in comment

PATCH Applied WangYuli 5 participants 11 messages Apr 14, 2025 – Apr 22, 2025

Subsystems (8)
lore
Share & tools
lore

WangYuli

author
#0 lore raw

v2 cover treewide: Rename del_timer[_sync] in comment

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()") switched del_timer[_sync] to timer_delete[_sync], but did not modify some comments. Now fix them.

NOTE:
1. This is not a straightforward global replacement operation.
Certain changelogs located within comments should be skipped.
2. Commit ("cfs2: o2net_idle_timer: Rename del_timer_sync in comment")
has been already added in the -mm mm-nonmm-unstable branch.[1] This change introduces the addition of an "Acked-by" tag from Joseph Qi.[2]

[1]. https://lore.kernel.org/all/[email protected]/
[2]. https://lore.kernel.org/all/[email protected]/

WangYuli (5):
bna: bnad_dim_timeout: Rename del_timer_sync in comment
ocfs2: o2net_idle_timer: Rename del_timer_sync in comment
scsi: scsi_transport_fc: Rename del_timer in comment
ipvs: ip_vs_conn_expire_now: Rename del_timer in comment
ALSA: korg1212: snd_korg1212_prepare: Rename del_timer in comment

 drivers/net/ethernet/brocade/bna/bnad.c | 2 +-
 drivers/scsi/scsi_transport_fc.c        | 2 +-
 fs/ocfs2/cluster/tcp.c                  | 2 +-
 net/netfilter/ipvs/ip_vs_conn.c         | 2 +-
 sound/pci/korg1212/korg1212.c           | 2 +-
 5 files changed, 5 insertions(+), 5 deletions(-)
Signature · 1 line
2.49.0
author
#1 lore raw

PATCH v2 1/5 bna: bnad_dim_timeout: Rename del_timer_sync in comment

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()") switched del_timer_sync to timer_delete_sync, but did not modify the comment for bnad_dim_timeout(). Now fix it.

Cc Rasesh Mody <[email protected]>
Cc Sudarsana Kalluru <[email protected]>
Cc Andrew Lunn <[email protected]>
Cc David S. Miller <[email protected]>
Cc Eric Dumazet <[email protected]>
Cc Jakub Kicinski <[email protected]>
Cc Paolo Abeni <[email protected]>
---
 drivers/net/ethernet/brocade/bna/bnad.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/brocade/bna/bnad.c +1 -1
index a03eff3d4425..50eb54ecf1ba 100644
@@ -1735,7 +1735,7 @@ bnad_iocpf_sem_timeout(struct timer_list *t)
  *	Time	CPU m	CPU n
  *	0       1 = test_bit
  *	1			clear_bit
- *	2			del_timer_sync
+ *	2			timer_delete_sync
  *	3	mod_timer
  */
 
Signature · 1 line
2.49.0
#2 lore raw

Re: [PATCH v2 1/5] bna: bnad_dim_timeout: Rename del_timer_sync in comment

This series was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Hello:

This series was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Quoted 16 lines · On Mon, 14 Apr 2025 12:26:25 +0800 you wrote:

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()") switched del_timer_sync to timer_delete_sync, but did not modify the comment for bnad_dim_timeout(). Now fix it.

Cc Rasesh Mody <[email protected]>
Cc Sudarsana Kalluru <[email protected]>
Cc Andrew Lunn <[email protected]>
Cc David S. Miller <[email protected]>
Cc Eric Dumazet <[email protected]>
Cc Jakub Kicinski <[email protected]>
Cc Paolo Abeni <[email protected]>
Quoted 1 line

[...]

Here is the summary with links:
- [v2,1/5] bna: bnad_dim_timeout: Rename del_timer_sync in comment

    https://git.kernel.org/netdev/net-next/c/1450e4525f9a

- [v2,4/5] ipvs: ip_vs_conn_expire_now: Rename del_timer in comment (no matching commit)

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
author
#3 lore raw

PATCH v2 2/5 ocfs2: o2net_idle_timer: Rename del_timer_sync in comment

In reply to WangYuli

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()") switched del_timer_sync to timer_delete_sync, but did not modify the comment for o2net_idle_timer(). Now fix it.

Cc Mark Fasheh <[email protected]>
Cc Joel Becker <[email protected]>
Cc Joseph Qi <[email protected]>
Cc Thomas Gleixner <[email protected]>
Cc Andrew Morton <[email protected]>
Cc Jakub Kicinski <[email protected]>
Cc WangYuli <[email protected]>
Cc Jens Axboe <[email protected]>
Cc Dmitry Antipov <[email protected]>

---
Changelog:
*v1->v2: Add Joseph Qi's "Acked-by" tag.

---
 fs/ocfs2/cluster/tcp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/ocfs2/cluster/tcp.c +1 -1
index fce9beb214f0..43e652a2adaf 100644
@@ -1483,7 +1483,7 @@ static void o2net_sc_send_keep_req(struct work_struct *work)
 	sc_put(sc);
 }
 
-/* socket shutdown does a del_timer_sync against this as it tears down.
+/* socket shutdown does a timer_delete_sync against this as it tears down.
  * we can't start this timer until we've got to the point in sc buildup
  * where shutdown is going to be involved */
 static void o2net_idle_timer(struct timer_list *t)
Signature · 1 line
2.49.0
author
#4 lore raw

PATCH v2 3/5 scsi: scsi_transport_fc: Rename del_timer in comment

In reply to WangYuli

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()") switched del_timer to timer_delete, but did not modify the comment for fc_remote_port_rolechg(). Now fix it.

Cc James E.J. Bottomley <[email protected]>
Cc Martin K. Petersen <[email protected]>
Cc SCSI SUBSYSTEM <[email protected]>
---
 drivers/scsi/scsi_transport_fc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/scsi_transport_fc.c +1 -1
index 082f76e76721..dda7be02ed9f 100644
@@ -3509,7 +3509,7 @@ fc_remote_port_rolechg(struct fc_rport  *rport, u32 roles)
 		 *  state as the LLDD would not have had an rport
 		 *  reference to pass us.
 		 *
-		 * Take no action on the del_timer failure as the state
+		 * Take no action on the timer_delete failure as the state
 		 * machine state change will validate the
 		 * transaction.
 		 */
Signature · 1 line
2.49.0
#5 lore raw

Re: [PATCH v2 3/5] scsi: scsi_transport_fc: Rename del_timer in comment

Quoted 4 lines

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()") switched del_timer to timer_delete, but did not modify the comment for fc_remote_port_rolechg(). Now fix it.

Applied to 6.16/scsi-staging, thanks!

Signature · 1 line
Martin K. Petersen
author
#6 lore raw

PATCH v2 4/5 ipvs: ip_vs_conn_expire_now: Rename del_timer in comment

In reply to WangYuli

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()") switched del_timer to timer_delete, but did not modify the comment for ip_vs_conn_expire_now(). Now fix it.

Cc Simon Horman <[email protected]>
Cc Julian Anastasov <[email protected]>
Cc Pablo Neira Ayuso <[email protected]>
Cc Jozsef Kadlecsik <[email protected]>
Cc David S. Miller <[email protected]>
Cc Eric Dumazet <[email protected]>
Cc Jakub Kicinski <[email protected]>
Cc Paolo Abeni <[email protected]>
---
 net/netfilter/ipvs/ip_vs_conn.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/netfilter/ipvs/ip_vs_conn.c +1 -1
index 8699944c0baf..ccc39c6557ee 100644
@@ -926,7 +926,7 @@ static void ip_vs_conn_expire(struct timer_list *t)
 void ip_vs_conn_expire_now(struct ip_vs_conn *cp)
 {
 	/* Using mod_timer_pending will ensure the timer is not
-	 * modified after the final del_timer in ip_vs_conn_expire.
+	 * modified after the final timer_delete in ip_vs_conn_expire.
 	 */
 	if (timer_pending(&cp->timer) &&
 	    time_after(cp->timer.expires, jiffies))
Signature · 1 line
2.49.0
author
#7 lore raw

PATCH v2 5/5 ALSA: korg1212: snd_korg1212_prepare: Rename del_timer in comment

In reply to WangYuli

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()") switched del_timer to timer_delete, but did not modify the comment for snd_korg1212_prepare(). Now fix it.

Cc Jaroslav Kysela <[email protected]>
Cc Takashi Iwai <[email protected]>
Cc Bjorn Helgaas <[email protected]>
Cc Philipp Stanner <[email protected]>
---
 sound/pci/korg1212/korg1212.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
sound/pci/korg1212/korg1212.c +1 -1
index 49b71082c485..5e69bb25d420 100644
@@ -1553,7 +1553,7 @@ static int snd_korg1212_prepare(struct snd_pcm_substream *substream)
 		return -EAGAIN;
 		/*
 		korg1212->sharedBufferPtr->cardCommand = 0;
-		del_timer(&korg1212->timer);
+		timer_delete(&korg1212->timer);
 		korg1212->stop_pending_cnt = 0;
 		*/
 	}
Signature · 1 line
2.49.0
#8 lore raw

Re: [PATCH v2 5/5] ALSA: korg1212: snd_korg1212_prepare: Rename del_timer in comment

Quoted 23 lines · WangYuli

Commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()")
switched del_timer to timer_delete, but did not modify the comment for
snd_korg1212_prepare(). Now fix it.

Cc Jaroslav Kysela <[email protected]>
Cc Takashi Iwai <[email protected]>
Cc Bjorn Helgaas <[email protected]>
Cc Philipp Stanner <[email protected]>

---
 sound/pci/korg1212/korg1212.c | 2 +-

 1 file changed, 1 insertion(+), 1 deletion(-)
sound/pci/korg1212/korg1212.c +0 -0
index 49b71082c485..5e69bb25d420 100644

sound/pci/korg1212/korg1212.c static int snd_korg1212_prepare(struct · line 1559

Quoted 8 lines
sound/pci/korg1212/korg1212.c +1 -1
@@ -1553,7 +1553,7 @@ static int snd_korg1212_prepare(struct
 snd_pcm_substream *substream)
  		return -EAGAIN;
  		/*
  		korg1212->sharedBufferPtr->cardCommand = 0;
-		del_timer(&korg1212->timer);
+		timer_delete(&korg1212->timer);
  		korg1212->stop_pending_cnt = 0;
  		*/

Wouldn't it be better to just remove all that? Or at least document what it is good for?

P.

Quoted 1 line

  }

author
#9 lore raw

Re: [PATCH v2 5/5] ALSA: korg1212: snd_korg1212_prepare: Rename del_timer in comment

Hi Philipp Stanner,

Quoted 2 lines · Philipp Stanner

Wouldn't it be better to just remove all that? Or at least document what it is good for?

This code comes from commit 4d6dcf60b9 ("ALSA update   - documentation   - control API - added multi-elements to reduce memory usage   - improved preallocation of DMA buffers   - CS46xx driver - added support for secondary codec   - HDSP driver - big update     - firmware is loaded with hdsptool now   - pmac driver updates (fixed oops and beep stuff)   - VIA82xx driver updated   - ymfpci driver updated   - drivers updated to new PnP layer     - wavefront, ad1816a, cs423x, es18xx, interwave, opl3sa2, cmi8330") in the history tree [1] as part of a huge patch.

I couldn't find any useful information about this specific code within that commit.

Since I'm uncertain if we truly don't need it (this code is marked with "FIXME" above), I've kept this comment.

Furthermore, this driver has other sections of commented-out code as well, so a more comprehensive cleanup of this driver might be a better approach in the future.

If possible, I'd also be happy to contribute to that effort.

However, this commit isn't intended for that purpose.

Its sole aim is to clean up the comment that were missed by commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete_sync") and should have been updated.

[1]. https://web.git.kernel.org/pub/scm/linux/kernel/git/tglx/history.git/commit/?id=4d6dcf60b98000c204b309b529c10b2a3884789e

Thanks,

Signature · 1 line
WangYuli
#10 lore raw

Re: [PATCH v2 5/5] ALSA: korg1212: snd_korg1212_prepare: Rename del_timer in comment

Quoted 29 lines · WangYuli

Hi Philipp Stanner,

Quoted 2 lines · Philipp Stanner

Wouldn't it be better to just remove all that? Or at least document what it is good for?

This code comes from commit 4d6dcf60b9 ("ALSA update   - documentation
  - control API - added multi-elements to reduce memory usage   - improved preallocation of DMA buffers   - CS46xx driver - added support for secondary codec   - HDSP driver - big update     - firmware is loaded with hdsptool now   - pmac driver updates (fixed oops and beep stuff)   - VIA82xx driver updated   - ymfpci driver updated   - drivers updated to new PnP layer     - wavefront, ad1816a, cs423x, es18xx, interwave, opl3sa2, cmi8330") in the history tree [1] as part of a huge patch.

I couldn't find any useful information about this specific code within that commit.

Since I'm uncertain if we truly don't need it (this code is marked with "FIXME" above), I've kept this comment.

Furthermore, this driver has other sections of commented-out code as well, so a more comprehensive cleanup of this driver might be a better approach in the future.

If possible, I'd also be happy to contribute to that effort.

Quoted 8 lines

However, this commit isn't intended for that purpose.

Its sole aim is to clean up the comment that were missed by commit 8fa7292fee5c ("treewide: Switch/rename to timer_delete_sync") and should have been updated.

[1]. https://web.git.kernel.org/pub/scm/linux/kernel/git/tglx/history.git/commit/?id=4d6dcf60b98000c204b309b529c10b2a3884789e

Yeah, the code is quite old and dirty, and this timer stuff can be omitted completely by introducing the proper sync_stop PCM ops. Let me rewrite the code instead.

thanks,

Takashi