]> www.infradead.org Git - users/dwmw2/linux.git/commit
rust: types: add `Opaque::pin_init`
authorDanilo Krummrich <dakr@kernel.org>
Thu, 19 Dec 2024 17:04:07 +0000 (18:04 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 20 Dec 2024 16:19:26 +0000 (17:19 +0100)
commit2d3bf6ffe26439444b55dd5af7b06d1aca3a042d
tree3d8ae8220dd28c7e2f87ed3ea864824b60c922a3
parent51158207294108898e5b72bb78fa51a7e848844f
rust: types: add `Opaque::pin_init`

Analogous to `Opaque::new` add `Opaque::pin_init`, which instead of a
value `T` takes a `PinInit<T>` and returns a `PinInit<Opaque<T>>`.

Reviewed-by: Alice Ryhl <aliceryhl@google.com>
Suggested-by: Alice Ryhl <aliceryhl@google.com>
Signed-off-by: Danilo Krummrich <dakr@kernel.org>
Tested-by: Dirk Behme <dirk.behme@de.bosch.com>
Tested-by: Fabien Parent <fabien.parent@linaro.org>
Link: https://lore.kernel.org/r/20241219170425.12036-6-dakr@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
rust/kernel/types.rs