2023-03-31 21:53:47

by y86-dev

[permalink] [raw]
Subject: [PATCH v4 01/15] rust: enable the `pin_macro` feature

From: Benno Lossin <[email protected]>

This feature enables the use of the `pin!` macro for the `stack_pin_init!`
macro. This feature is already stabilized in Rust version 1.68.

Signed-off-by: Benno Lossin <[email protected]>
Cc: Gary Guo <[email protected]>
Cc: Andreas Hindborg <[email protected]>
Cc: Alice Ryhl <[email protected]>
---
rust/kernel/lib.rs | 1 +
1 file changed, 1 insertion(+)

diff --git a/rust/kernel/lib.rs b/rust/kernel/lib.rs
index 223564f9f0cc..4317b6d5f50b 100644
--- a/rust/kernel/lib.rs
+++ b/rust/kernel/lib.rs
@@ -17,6 +17,7 @@
#![feature(core_ffi_c)]
#![feature(dispatch_from_dyn)]
#![feature(generic_associated_types)]
+#![feature(pin_macro)]
#![feature(receiver_trait)]
#![feature(unsize)]

--
2.39.2



2023-03-31 21:55:10

by Boqun Feng

[permalink] [raw]
Subject: Re: [PATCH v4 01/15] rust: enable the `pin_macro` feature

On Fri, Mar 31, 2023 at 09:51:35PM +0000, [email protected] wrote:
> From: Benno Lossin <[email protected]>
>
> This feature enables the use of the `pin!` macro for the `stack_pin_init!`
> macro. This feature is already stabilized in Rust version 1.68.
>
> Signed-off-by: Benno Lossin <[email protected]>
> Cc: Gary Guo <[email protected]>
> Cc: Andreas Hindborg <[email protected]>
> Cc: Alice Ryhl <[email protected]>

Acked-by: Boqun Feng <[email protected]>

Regards,
Boqun

> ---
> rust/kernel/lib.rs | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/rust/kernel/lib.rs b/rust/kernel/lib.rs
> index 223564f9f0cc..4317b6d5f50b 100644
> --- a/rust/kernel/lib.rs
> +++ b/rust/kernel/lib.rs
> @@ -17,6 +17,7 @@
> #![feature(core_ffi_c)]
> #![feature(dispatch_from_dyn)]
> #![feature(generic_associated_types)]
> +#![feature(pin_macro)]
> #![feature(receiver_trait)]
> #![feature(unsize)]
>
> --
> 2.39.2
>
>

2023-03-31 22:28:41

by Boqun Feng

[permalink] [raw]
Subject: Re: [PATCH v4 01/15] rust: enable the `pin_macro` feature

On Fri, Mar 31, 2023 at 02:52:18PM -0700, Boqun Feng wrote:
> On Fri, Mar 31, 2023 at 09:51:35PM +0000, [email protected] wrote:
> > From: Benno Lossin <[email protected]>
> >
> > This feature enables the use of the `pin!` macro for the `stack_pin_init!`
> > macro. This feature is already stabilized in Rust version 1.68.
> >
> > Signed-off-by: Benno Lossin <[email protected]>
> > Cc: Gary Guo <[email protected]>
> > Cc: Andreas Hindborg <[email protected]>
> > Cc: Alice Ryhl <[email protected]>
>
> Acked-by: Boqun Feng <[email protected]>
>

Hmm.. actually I think you will need to add this in the
scripts/Makefile.build, because the user (stack_pin_init!()) is a macro,
feel free to add my acked-by after that.

Regards,
Boqun

> Regards,
> Boqun
>
> > ---
> > rust/kernel/lib.rs | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/rust/kernel/lib.rs b/rust/kernel/lib.rs
> > index 223564f9f0cc..4317b6d5f50b 100644
> > --- a/rust/kernel/lib.rs
> > +++ b/rust/kernel/lib.rs
> > @@ -17,6 +17,7 @@
> > #![feature(core_ffi_c)]
> > #![feature(dispatch_from_dyn)]
> > #![feature(generic_associated_types)]
> > +#![feature(pin_macro)]
> > #![feature(receiver_trait)]
> > #![feature(unsize)]
> >
> > --
> > 2.39.2
> >
> >