* [PATCH] rust: kernel: list: fix incorrect pop_back example comment
@ 2026-08-10 15:03 Nikolai Grlica
2026-08-10 15:14 ` Miguel Ojeda
2026-08-24 1:13 ` Miguel Ojeda
0 siblings, 2 replies; 3+ messages in thread
From: Nikolai Grlica @ 2026-08-10 15:03 UTC (permalink / raw)
To: Miguel Ojeda; +Cc: rust-for-linux, linux-kernel, Nikolai Grlica
The example uses pop_back(), but the accompanying comment says
pop_front(). Update the comment to match the example.
Signed-off-by: Nikolai Grlica <nikolai@nikolaigrlica.dev>
---
rust/kernel/list.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/rust/kernel/list.rs b/rust/kernel/list.rs
index 406e3a028c55..0f367264ee2e 100644
--- a/rust/kernel/list.rs
+++ b/rust/kernel/list.rs
@@ -249,7 +249,7 @@
/// assert_eq!(list.iter().count(), 3);
/// }
///
-/// // Pop the items from the list using `pop_front()` and verify the content.
+/// // Pop the items from the list using `pop_back()` and verify the content.
/// {
/// assert_eq!(list.pop_back().ok_or(EINVAL)?.value.foo(), ("a", 15));
/// assert_eq!(list.pop_back().ok_or(EINVAL)?.value.foo(), ("a", 32));
--
2.55.0
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] rust: kernel: list: fix incorrect pop_back example comment
2026-08-10 15:03 [PATCH] rust: kernel: list: fix incorrect pop_back example comment Nikolai Grlica
@ 2026-08-10 15:14 ` Miguel Ojeda
2026-08-24 1:13 ` Miguel Ojeda
1 sibling, 0 replies; 3+ messages in thread
From: Miguel Ojeda @ 2026-08-10 15:14 UTC (permalink / raw)
To: Nikolai Grlica
Cc: Miguel Ojeda, rust-for-linux, linux-kernel, Boqun Feng, Gary Guo,
Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
Trevor Gross, Danilo Krummrich, Daniel Almeida, Tamir Duberstein,
Alexandre Courbot, Onur Özkan
On Mon, Aug 10, 2026 at 5:03 PM Nikolai Grlica
<nikolai@nikolaigrlica.dev> wrote:
>
> The example uses pop_back(), but the accompanying comment says
> pop_front(). Update the comment to match the example.
>
> Signed-off-by: Nikolai Grlica <nikolai@nikolaigrlica.dev>
Good eyes, thanks -- and welcome! I think it is your first patch to
the kernel (?).
Some extra tags I will add when applying it:
Cc: stable@vger.kernel.org
Fixes: bf87a41b85d6 ("rust: list: Add an example for `ListLinksSelfPtr` usage")
By the way, for future patches, please remember to Cc the relevant
reviewers and maintainers -- you can use e.g.
`scripts/get_maintainer.pl` for that. Done here for you! :) I have
some other tips and links here:
https://rust-for-linux.com/contributing
I hope that helps!
Cheers,
Miguel
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] rust: kernel: list: fix incorrect pop_back example comment
2026-08-10 15:03 [PATCH] rust: kernel: list: fix incorrect pop_back example comment Nikolai Grlica
2026-08-10 15:14 ` Miguel Ojeda
@ 2026-08-24 1:13 ` Miguel Ojeda
1 sibling, 0 replies; 3+ messages in thread
From: Miguel Ojeda @ 2026-08-24 1:13 UTC (permalink / raw)
To: Nikolai Grlica; +Cc: Miguel Ojeda, rust-for-linux, linux-kernel
On Mon, Aug 10, 2026 at 5:03 PM Nikolai Grlica
<nikolai@nikolaigrlica.dev> wrote:
>
> The example uses pop_back(), but the accompanying comment says
> pop_front(). Update the comment to match the example.
>
> Signed-off-by: Nikolai Grlica <nikolai@nikolaigrlica.dev>
Applied to `rust-fixes` -- thanks!
Cc: stable@vger.kernel.org
Fixes: bf87a41b85d6 ("rust: list: Add an example for
`ListLinksSelfPtr` usage")
Cheers,
Miguel
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-08-24 1:14 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-10 15:03 [PATCH] rust: kernel: list: fix incorrect pop_back example comment Nikolai Grlica
2026-08-10 15:14 ` Miguel Ojeda
2026-08-24 1:13 ` Miguel Ojeda
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®