Re: [PATCH 4/6] rust: rbtree: add `RBTreeIteratorMut`

From: Alice Ryhl
Date: Fri Feb 09 2024 - 08:06:56 EST


On Mon, Feb 5, 2024 at 4:50 PM <mattgilbride@xxxxxxxxxx> wrote:
>
> From: Wedson Almeida Filho <wedsonaf@xxxxxxxxx>
>
> Add mutable Iterator implementation (`RBTreeIteratorMut`) for `RBTree`,
> allowing iteration over (key, value) pairs in key order. Only values are
> mutable, as mutating keys implies modifying a node's position in the tree.
>
> Mutable iteration is used by the binder driver during shutdown to
> clean up the tree maintained by the "range allocator" [1].
>
> Link: https://lore.kernel.org/rust-for-linux/20231101-rust-binder-v1-6-08ba9197f637@xxxxxxxxxx/ [1]
> Signed-off-by: Wedson Almeida Filho <wedsonaf@xxxxxxxxx>
> Signed-off-by: Matt Gilbride <mattgilbride@xxxxxxxxx>

I have looked at these bindings many times over the past year. They
look good to me.

Reviewed-by: Alice Ryhl <aliceryhl@xxxxxxxxxx>

These abstractions have been very heavily exercised by the Rust Binder
driver.

Tested-by: Alice Ryhl <aliceryhl@xxxxxxxxxx>