History

timers: Rename del_timer() to timer_delete()

The timer related functions do not have a strict timer_ prefixed namespace which is really annoying. Rename del_timer() to timer_delete() and provide del_timer() as a wrapper. Document that del_timer() is not for new code.

Thomas Gleixner committed 3 years ago

Commit bb663f01 parent 9b13df32 files · +17 −4Browse files

Showing the changes to kernel/time/timer.c (1 of 2 files). Show all

Unified · Split

kernel/time/timer.c+3−3
@@ -1257,7 +1257,7 @@ void add_timer_on(struct timer_list *timer, int cpu) · 1256 unmodified lines
12571257 EXPORT_SYMBOL_GPL(add_timer_on);
12581258
12591259 /**
1260− * del_timer - Deactivate a timer.
1260+ * timer_delete - Deactivate a timer
12611261 * @timer: The timer to be deactivated
12621262 *
12631263 * The function only deactivates a pending timer, but contrary to
@@ -1270,7 +1270,7 @@ EXPORT_SYMBOL_GPL(add_timer_on); · 6 unmodified lines
12701270 * * %0 - The timer was not pending
12711271 * * %1 - The timer was pending and deactivated
12721272 */
1273−int del_timer(struct timer_list *timer)
1273+int timer_delete(struct timer_list *timer)
12741274 {
12751275 struct timer_base *base;
12761276 unsigned long flags;
@@ -1286,7 +1286,7 @@ int del_timer(struct timer_list *timer) · 9 unmodified lines
12861286
12871287 return ret;
12881288 }
1289−EXPORT_SYMBOL(del_timer);
1289+EXPORT_SYMBOL(timer_delete);
12901290
12911291 /**
12921292 * try_to_del_timer_sync - Try to deactivate a timer

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t