Rust for Linux List
 help / color / mirror / Atom feed
From: Andreas Hindborg <a.hindborg@kernel.org>
To: "Onur Özkan" <work@onurozkan.dev>
Cc: "Miguel Ojeda" <ojeda@kernel.org>, "Gary Guo" <gary@garyguo.net>,
	"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
	"Benno Lossin" <lossin@kernel.org>,
	"Alice Ryhl" <aliceryhl@google.com>,
	"Trevor Gross" <tmgross@umich.edu>,
	"Danilo Krummrich" <dakr@kernel.org>,
	"Boqun Feng" <boqun@kernel.org>,
	"Daniel Almeida" <daniel.almeida@collabora.com>,
	linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org,
	"Lorenzo Stoakes" <ljs@kernel.org>,
	"Vlastimil Babka" <vbabka@kernel.org>,
	"Liam R. Howlett" <liam@infradead.org>,
	"Uladzislau Rezki" <urezki@gmail.com>
Subject: Re: [PATCH v2] rust: add a ring buffer implementation
Date: Mon, 08 Jun 2026 09:28:31 +0200	[thread overview]
Message-ID: <878q8pij8g.fsf@kernel.org> (raw)
In-Reply-To: <20260608062555.19400-1-work@onurozkan.dev>

Onur Özkan <work@onurozkan.dev> writes:

> On Fri, 05 Jun 2026 15:10:30 +0200
> Andreas Hindborg <a.hindborg@kernel.org> wrote:
>

<cut>

>> +
>> +use super::{
>> +    allocator::{KVmalloc, Kmalloc, Vmalloc},
>> +    Allocator, Flags, Vec,
>> +};
>
> nit: Vertical style import missing.
>

<cut>

>> +    /// Returns `true` if the buffer is full.
>> +    ///
>> +    /// When the buffer is full, any call to [`push_head`] will return an error.
>> +    ///
>> +    /// [`push_head`]: Self::push_head
>> +    pub fn full(&self) -> bool {
>> +        (self.head + 1) % self.nodes.len() == self.tail
>
> Nit: This seems short enough to inline.
>

Thanks, I'll be sure to fix these for next spin.


Best regards,
Andreas Hindborg



      reply	other threads:[~2026-06-08  7:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-05 13:10 [PATCH v2] rust: add a ring buffer implementation Andreas Hindborg
2026-06-08  6:25 ` Onur Özkan
2026-06-08  7:28   ` Andreas Hindborg [this message]

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=878q8pij8g.fsf@kernel.org \
    --to=a.hindborg@kernel.org \
    --cc=aliceryhl@google.com \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun@kernel.org \
    --cc=dakr@kernel.org \
    --cc=daniel.almeida@collabora.com \
    --cc=gary@garyguo.net \
    --cc=liam@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ljs@kernel.org \
    --cc=lossin@kernel.org \
    --cc=ojeda@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=tmgross@umich.edu \
    --cc=urezki@gmail.com \
    --cc=vbabka@kernel.org \
    --cc=work@onurozkan.dev \
    /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