|
|
Log in / Subscribe / Register

The first half of the 6.6 merge window

The first half of the 6.6 merge window

Posted Sep 1, 2023 14:56 UTC (Fri) by gray_-_wolf (subscriber, #131074)
Parent article: The first half of the 6.6 merge window

I am curious, should we expect the rust version to change often? GCC is still sufficient in 5.1 (pretty old) for example.

Packaging firefox is sometimes a fun exercise in getting it build with the version of rust you have on hand. Should the same be expected from the kernel or is this just a temporary thing and the rust version required will stabilize one day and be not increased this often?

I do not know much about rust backwards compatibility story...


to post comments

The first half of the 6.6 merge window

Posted Sep 1, 2023 15:07 UTC (Fri) by willy (subscriber, #9762) [Link] (10 responses)

https://rust-for-linux.com/rust-version-policy

The first half of the 6.6 merge window

Posted Sep 7, 2023 2:51 UTC (Thu) by milesrout (subscriber, #126894) [Link] (9 responses)

That doesn't answer the question. It says "It remains to be decided how often the Rust version upgrades will land. Ideally we would track the latest Rust release, but it remains to be seen how other kernel developers feel about it." What is the actual policy?

Putting a language into the kernel that is so unstable that the "ideal" solution is to track the *latest release* is so insane I can't believe it's being seriously considered.

The first half of the 6.6 merge window

Posted Sep 7, 2023 16:18 UTC (Thu) by angelsl (subscriber, #144646) [Link] (2 responses)

Why does it being ideal that the latest Rust version is used imply that Rust is unstable?

It's not. It's perfectly fine to stay on some fixed version. But Rust is still getting new features that make it more ergonomic especially for low-level development like the kernel and people want to use those features.

The first half of the 6.6 merge window

Posted Sep 7, 2023 22:22 UTC (Thu) by gray_-_wolf (subscriber, #131074) [Link] (1 responses)

Doesn't that increase the difficulty of using newer kernel on older distribution? I feel there is a difference between difficulty of backporting a new kernel and backporting a new kernel and all the required rust machinery, since the version my distro has can no longer build the current kernel.

In the same vein, I am sure gcc has nice features people would like to use in at least some versions between 5.1 (minimal requirement) and 13.2 (current version).

I am unsure why there is (or will be) difference in policy between those two compilers.

The first half of the 6.6 merge window

Posted Sep 11, 2023 18:08 UTC (Mon) by ojeda (subscriber, #143370) [Link]

> Doesn't that increase the difficulty of using newer kernel on older distribution? I feel there is a difference between difficulty of backporting a new kernel and backporting a new kernel and all the required rust machinery, since the version my distro has can no longer build the current kernel.

Distributions can ignore Rust for the time being if they wish to do so. Some distributions, when I checked with them, told me they would be happy to provide a package (or support in some other way) to compile the kernel with the latest Rust release, assuming they need it.

Ubuntu, for instance, offers experimental support for it, by providing a package with the required Rust toolchain.

> In the same vein, I am sure gcc has nice features people would like to use in at least some versions between 5.1 (minimal requirement) and 13.2 (current version).
>
> I am unsure why there is (or will be) difference in policy between those two compilers.

There is definitely a difference nowadays; however, the plan is to remove that difference as soon as it is possible/reasonable. Please see this section in the webpage: https://rust-for-linux.com/rust-version-policy#after-a-minimum-version-is-declared.

The first half of the 6.6 merge window

Posted Sep 11, 2023 18:06 UTC (Mon) by ojeda (subscriber, #143370) [Link] (5 responses)

> That doesn't answer the question. It says "It remains to be decided how often the Rust version upgrades will land. Ideally we would track the latest Rust release, but it remains to be seen how other kernel developers feel about it." What is the actual policy?

It does answer the questions that gray_-_wolf posed.

As the webpage mentions, we are currently trying out upgrading to the latest Rust release as they land. So far, it has not been a problem for the kernel developers using Rust.

But, to be clear, as the webpage also says, this is just the policy before we can establish a minimum version. Being in the latest one will make it much easier to establish so when it happens, it makes development easier and allows us to give feedback to the Rust teams on the unstable features we need.

> Putting a language into the kernel that is so unstable that the "ideal" solution is to track the *latest release* is so insane I can't believe it's being seriously considered.

The Rust language is stable. Some features we need are not. I will add a note to the webpage to make it clear that Rust promises backwards compatibility (for the stable language).

And it is not an ideal solution: the webpage makes it clear that in the end we want to establish a policy similar to GCC, Clang or other tools used in the kernel.

The first half of the 6.6 merge window

Posted Sep 11, 2023 18:34 UTC (Mon) by pizza (subscriber, #46) [Link] (4 responses)

> The Rust language is stable. Some features we need are not.

That strikes me as a distinction without a difference.

The first half of the 6.6 merge window

Posted Sep 11, 2023 19:25 UTC (Mon) by mb (subscriber, #50428) [Link] (3 responses)

Do you want to wait for all the gcc extensions used by the kernel to land in an official C standard before you can use such a kernel?
It's the same thing.

The first half of the 6.6 merge window

Posted Sep 11, 2023 20:32 UTC (Mon) by pizza (subscriber, #46) [Link] (2 responses)

> Do you want to wait for all the gcc extensions used by the kernel to land in an official C standard before you can use such a kernel? It's the same thing.

It's only the same thing if each kernel release required you to use the latest release of GCC because "C is stable but the features we need are not."

(Meanwhile, the kernel only requires GCC 5.1, which was released over eight years ago. So.. yeah, not the same thing at all)

The first half of the 6.6 merge window

Posted Sep 12, 2023 6:03 UTC (Tue) by Cyberax (✭ supporter ✭, #52523) [Link] (1 responses)

Some kernel features like control flow integrity checking or shadow stacks (just merged) require a much newer GCC.

Yes, Rust is even newer than that. But that's a distinction without a difference: some kernel features require very new toolchains.

The first half of the 6.6 merge window

Posted Sep 12, 2023 6:17 UTC (Tue) by mb (subscriber, #50428) [Link]

Correct.
Some Distributions even used to ship a special gcc compiler just for compiling the kernel.
The kernel has very special requirements. That's true for C and Rust alike.
And I really don't see why that would be a problem.


Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds