* [PATCH] rust: task: fix `SAFETY` comment for Task::wake_up
@ 2025-03-08 16:49 Panagiotis Foliadis
2025-03-08 16:56 ` Charalampos Mitrodimas
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Panagiotis Foliadis @ 2025-03-08 16:49 UTC (permalink / raw)
To: Miguel Ojeda, Alex Gaynor, Boqun Feng, Gary Guo,
Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
Trevor Gross, Christian Brauner
Cc: rust-for-linux, linux-kernel, Panagiotis Foliadis
The `SAFETY` comment inside the `wake_up` function references
erroneously the `signal_pending` function instead of the
`wake_up_process` which is actually called. Fix the comment
to reference the correct function.
Fixes: fe95f58320e6 ("rust: task: adjust safety comments in Task methods")
Signed-off-by: Panagiotis Foliadis <pfoliadis@posteo.net>
---
| 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--git a/rust/kernel/task.rs b/rust/kernel/task.rs
index 07bc22a7645c0c7d792a0a163dd55b8ff0fe5f92..38da555a2bdbb71d698c671ad1a7a337e50c6600 100644
--- a/rust/kernel/task.rs
+++ b/rust/kernel/task.rs
@@ -320,7 +320,7 @@ pub fn tgid_nr_ns(&self, pidns: Option<&PidNamespace>) -> Pid {
/// Wakes up the task.
pub fn wake_up(&self) {
- // SAFETY: It's always safe to call `signal_pending` on a valid task, even if the task
+ // SAFETY: It's always safe to call `wake_up_process` on a valid task, even if the task
// running.
unsafe { bindings::wake_up_process(self.as_ptr()) };
}
---
base-commit: 2a520073e74fbb956b5564818fc5529dcc7e9f0e
change-id: 20250308-comment-fix-25d09ff1ccb5
Best regards,
--
Panagiotis Foliadis <pfoliadis@posteo.net>
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] rust: task: fix `SAFETY` comment for Task::wake_up
2025-03-08 16:49 [PATCH] rust: task: fix `SAFETY` comment for Task::wake_up Panagiotis Foliadis
@ 2025-03-08 16:56 ` Charalampos Mitrodimas
2025-03-10 9:15 ` Alice Ryhl
2025-03-10 17:11 ` Miguel Ojeda
2 siblings, 0 replies; 4+ messages in thread
From: Charalampos Mitrodimas @ 2025-03-08 16:56 UTC (permalink / raw)
To: Panagiotis Foliadis
Cc: Miguel Ojeda, Alex Gaynor, Boqun Feng, Gary Guo,
Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
Trevor Gross, Christian Brauner, rust-for-linux, linux-kernel
Panagiotis Foliadis <pfoliadis@posteo.net> writes:
> The `SAFETY` comment inside the `wake_up` function references
> erroneously the `signal_pending` function instead of the
> `wake_up_process` which is actually called. Fix the comment
> to reference the correct function.
>
> Fixes: fe95f58320e6 ("rust: task: adjust safety comments in Task methods")
> Signed-off-by: Panagiotis Foliadis <pfoliadis@posteo.net>
> ---
> rust/kernel/task.rs | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
You can add,
Reviewed-by: Charalampos Mitrodimas <charmitro@posteo.net>
--
C. Mitrodimas
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] rust: task: fix `SAFETY` comment for Task::wake_up
2025-03-08 16:49 [PATCH] rust: task: fix `SAFETY` comment for Task::wake_up Panagiotis Foliadis
2025-03-08 16:56 ` Charalampos Mitrodimas
@ 2025-03-10 9:15 ` Alice Ryhl
2025-03-10 17:11 ` Miguel Ojeda
2 siblings, 0 replies; 4+ messages in thread
From: Alice Ryhl @ 2025-03-10 9:15 UTC (permalink / raw)
To: Panagiotis Foliadis
Cc: Miguel Ojeda, Alex Gaynor, Boqun Feng, Gary Guo,
Björn Roy Baron, Benno Lossin, Andreas Hindborg,
Trevor Gross, Christian Brauner, rust-for-linux, linux-kernel
On Sat, Mar 08, 2025 at 04:49:05PM +0000, Panagiotis Foliadis wrote:
> The `SAFETY` comment inside the `wake_up` function references
> erroneously the `signal_pending` function instead of the
> `wake_up_process` which is actually called. Fix the comment
> to reference the correct function.
>
> Fixes: fe95f58320e6 ("rust: task: adjust safety comments in Task methods")
> Signed-off-by: Panagiotis Foliadis <pfoliadis@posteo.net>
Thanks.
Reviewed-by: Alice Ryhl <aliceryhl@google.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] rust: task: fix `SAFETY` comment for Task::wake_up
2025-03-08 16:49 [PATCH] rust: task: fix `SAFETY` comment for Task::wake_up Panagiotis Foliadis
2025-03-08 16:56 ` Charalampos Mitrodimas
2025-03-10 9:15 ` Alice Ryhl
@ 2025-03-10 17:11 ` Miguel Ojeda
2 siblings, 0 replies; 4+ messages in thread
From: Miguel Ojeda @ 2025-03-10 17:11 UTC (permalink / raw)
To: Panagiotis Foliadis
Cc: Miguel Ojeda, Alex Gaynor, Boqun Feng, Gary Guo,
Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
Trevor Gross, Christian Brauner, rust-for-linux, linux-kernel
On Sat, Mar 8, 2025 at 5:49 PM Panagiotis Foliadis <pfoliadis@posteo.net> wrote:
>
> The `SAFETY` comment inside the `wake_up` function references
> erroneously the `signal_pending` function instead of the
> `wake_up_process` which is actually called. Fix the comment
> to reference the correct function.
>
> Fixes: fe95f58320e6 ("rust: task: adjust safety comments in Task methods")
> Signed-off-by: Panagiotis Foliadis <pfoliadis@posteo.net>
Applied to `rust-fixes` -- thanks everyone!
[ Slightly reworded. - Miguel ]
Cheers,
Miguel
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2025-03-10 17:12 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-08 16:49 [PATCH] rust: task: fix `SAFETY` comment for Task::wake_up Panagiotis Foliadis
2025-03-08 16:56 ` Charalampos Mitrodimas
2025-03-10 9:15 ` Alice Ryhl
2025-03-10 17:11 ` Miguel Ojeda
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).