From: "tip-bot2 for Nam Cao" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: Nam Cao <namcao@linutronix.de>,
Thomas Gleixner <tglx@linutronix.de>,
x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: timers/cleanups] hrtimers: Switch to use __htimer_setup()
Date: Fri, 04 Apr 2025 17:34:12 -0000 [thread overview]
Message-ID: <174378805202.31282.4548676701082513893.tip-bot2@tip-bot2> (raw)
In-Reply-To: =?utf-8?q?=3Cd9a45a51b6a8aa0045310d63f73753bf6b33f385=2E17387?= =?utf-8?q?46927=2Egit=2Enamcao=40linutronix=2Ede=3E?=
The following commit has been merged into the timers/cleanups branch of tip:
Commit-ID: 6119cdeeead0552e7dcfde1473a711b494be66e5
Gitweb: https://git.kernel.org/tip/6119cdeeead0552e7dcfde1473a711b494be66e5
Author: Nam Cao <namcao@linutronix.de>
AuthorDate: Wed, 05 Feb 2025 11:55:11 +01:00
Committer: Thomas Gleixner <tglx@linutronix.de>
CommitterDate: Fri, 04 Apr 2025 19:26:43 +02:00
hrtimers: Switch to use __htimer_setup()
__hrtimer_init_sleeper() calls __hrtimer_init() and also setups the
callback function. But there is already __hrtimer_setup() which does both
actions.
Switch to use __hrtimer_setup() to simplify the code.
Signed-off-by: Nam Cao <namcao@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/all/d9a45a51b6a8aa0045310d63f73753bf6b33f385.1738746927.git.namcao@linutronix.de
---
kernel/time/hrtimer.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/kernel/time/hrtimer.c b/kernel/time/hrtimer.c
index b7555ba..2d2835c 100644
--- a/kernel/time/hrtimer.c
+++ b/kernel/time/hrtimer.c
@@ -2061,8 +2061,7 @@ static void __hrtimer_init_sleeper(struct hrtimer_sleeper *sl,
mode |= HRTIMER_MODE_HARD;
}
- __hrtimer_init(&sl->timer, clock_id, mode);
- sl->timer.function = hrtimer_wakeup;
+ __hrtimer_setup(&sl->timer, hrtimer_wakeup, clock_id, mode);
sl->task = current;
}
next reply other threads:[~2025-04-04 17:34 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-04 17:34 tip-bot2 for Nam Cao [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-04-05 8:46 tip-bot2 for Nam Cao
2025-04-04 17:54 tip-bot2 for Nam Cao
2025-04-04 14:36 tip-bot2 for Nam Cao
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=174378805202.31282.4548676701082513893.tip-bot2@tip-bot2 \
--to=tip-bot2@linutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=namcao@linutronix.de \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®