Live data from Hacker News

Maestro: A Linux-compatible kernel in Rust

blog.lenot.re

301–310 of 380 posts

Re: Maestro: A Linux-compatible kernel in Rust

#301
post #249

Earlier quoted context omitted.

Seems that the project is dead. The repository does not receive any commit for two years.

No its not. See: https://gitlab.redox-os.org/redox-os/redox/ https://www.redox-os.org/news/development-priorities-2023-09...

The redox-os post mentions cosmic desktop, and future wayland support, which may now already be almost implemented?

The System76 blog appears to have updates regarding COSMIC DE: https://blog.system76.com/post/the-spirit-of-cosmic-december...

Components of Cosmic Desktop Rust-based Desktop Environment: https://github.com/pop-os/cosmic-epoch#components-of-cosmic-...

cosmic-comp/src/wayland/handlers https://github.com/pop-os/cosmic-comp/tree/master_jammy/src/...

Re: Maestro: A Linux-compatible kernel in Rust

#302

Syscalls are easy. Drivers will be tough.

Aren't most drivers kernel modules? In theory, the goal to aim for is that Maestro is able to compatibly load C Linux kernel modules. Then, whether or not the driver module is written in C or Rust is orthogonal to which kernel is used.

(Just bs'ing here, haven't written drivers in over a decade. What other complexity am I missing?)

Re: Maestro: A Linux-compatible kernel in Rust

#303
post #178

Earlier quoted context omitted.

DOS from HN's very own Slashdot effect...

For those who are wondering WTF is a Slashdot, and how does it effect websites. https://tech.slashdot.org/story/24/01/03/0017242/25-years-si... https://en.wikipedia.org/wiki/Slashdot_effect

Weird to think there are now people so young in these types of discussions that wouldn't know about Slashdot.

Re: Maestro: A Linux-compatible kernel in Rust

#304
post #302

Syscalls are easy. Drivers will be tough.

Aren't most drivers kernel modules? In theory, the goal to aim for is that Maestro is able to compatibly load C Linux kernel modules. Then, whether or not the driver module is written in C or Rust is orthogonal to which kernel is used. (Just bs'ing here, haven't written drivers in over a decade. What other complexity am I missing?)

Your sibling comments and responses to them about ABI stability talk about why this is not possible. For example,

https://news.ycombinator.com/item?id=38853047

Re: Maestro: A Linux-compatible kernel in Rust

#305

Earlier quoted context omitted.

I don't think I've ever seen an argument for why "everything is a file" is a desirable thing. It seems like a kitchen where "everything is a bowl". Fine when you want to eat cereal, mix a cake, do some handwashing up, store some fruit; tolerable when you want to bake a cake in the oven. Intolerable when you've got a carrot in a bowl-shaped chopping board and you've got to peel and cut it using a bowl. Why in principl…

I don't think the metaphor applies because kitchen utensils' forms are dictated are their purpose, but software interfaces are abstractions. A fairer analogy would be if everything in the kitchen was bowl-shaped, but you could do bowl-like actions and get non-bowl behavior. Drop the carrot in the peelbowl and it is peeled, drop the carrot in the knifebowl and it is diced, drop the cubes in the stovebowl and they are…

The counter would be that different tasks are different and that's why everything isn't bowl shaped. Analogously, programming languages which are strongly opinionated (purely functional, array-based, strictly static) are far less generally popular than programming languages which are multi-paradigm and flexibly typed.

People have access to user-mode filesystems and FUSE, people could have made everything have a file-like interface by now if that was desirable - apparently it isn't. And because different tasks are different, it makes sense that they would fit different abstractions and interfaces, wouldn't it?

Re: Maestro: A Linux-compatible kernel in Rust

#306

Earlier quoted context omitted.

That's only in terms of the driver interface, right? My understanding is that the userspace interface is extremely stable.

Depends on systemd's considerations these days.

Unless you consider systemd's security features (filtering available syscalls), there's literally no interposition between apps and the kernel.

Re: Maestro: A Linux-compatible kernel in Rust

#307

Earlier quoted context omitted.

I don't think I've ever seen an argument for why "everything is a file" is a desirable thing. It seems like a kitchen where "everything is a bowl". Fine when you want to eat cereal, mix a cake, do some handwashing up, store some fruit; tolerable when you want to bake a cake in the oven. Intolerable when you've got a carrot in a bowl-shaped chopping board and you've got to peel and cut it using a bowl. Why in principl…

> I don't think I've ever seen an argument for why "everything is a file" is a desirable thing. A file system is a tree of named objects. These objects are seamlessly part of the OS and served by a program or kernel driver called a file server which can then be shared over a network. Security is then handled by file permissions so authentication is native through the system and not bolted on. It fits together very we…

I like the example and the detailed explanation but "it works in some scenarios" is only enough to say that some things work well as files, it's not enough to convince that everything should be a file (or that everything should be the same, whatever the same is).

> "sky's the limit, just put the logic in the fs"

You can, but why is it better to do that? "just" put the logic in a Python script seems much simpler than putting it in a low level pretend filesystem driver, on the other side of an arbitrary interface you had to come up with to satisfy an ideology that everything should have to go through this interface, right?

Over Christmas I set some LED displays running, controlled by an RS-232 serial port. It would be possible to echo a line of text to a pretend filename and have it appear on the sign, but there is a command for whether the text is static or scrolling and one for whether the text appears on the top line or bottom line. That information has to be somewhere, either as different paths in the filesystem e.g. /mnt/sign/static/row/top vs /mnt/sign/scrolling/row/top or as formatted content inside the file, or both.

There's a command to change the colour of the subsequent text, which can be used anywhere in the message, many times over - so that can't easily go in the filesystem path so now there needs to be some intermediate structure which both the shell script and the filesystem driver speak, to be able to pass this command through the file interface. With a COM port in Windows, if one script opens it and another script tries to open it then there's a clear error that the port is in use. If a usermode filesystem driver held the com port open, what would happen if two scripts tried to write to these files? Does one get a mysterious "write failed" filesystem error to catch and debug instead of a proper relevant error message? Do they have to proxy error messages through /mnt/sign/meta/error ?

This is one of the most trivial things a computer can do, sending a short text, which is possible with echoing to a com port /dev/ttyS0, and the abstraction idea of making it a file is already creaking under the weight of the task, adding the burden of arbitrary path decisions and data formatting and task-specific escape codes and control sequences, and bodgy-error handling, while assisting with basically nothing - while you can find /mnt/* you get no help with that, no link to any documentation, no further discovery, no interactivity like you get from a command line binary program interface. Much much easier to put the sign's commands directly in a short Python script, isn't it? And other more complex tasks just get more and more intense, as the "plain text" files in /etc/ are an ad-hoc mix of formats and data types and parsing rules and symbolic links to /opt/ and other random places.

As I say in another comment, usermode filesystems never became the default or popular way to do things, why not?

Re: Maestro: A Linux-compatible kernel in Rust

#308

Earlier quoted context omitted.

>> The amount of hate for GPL on HN is disturbing. I agree. I'm really baffled by the Rust community pretty much standardizing on MIT license. People laugh at "Rewrite it in Rust" which I think is a good thing but completely ignore the whole "strip users of their freedom" that is coming with it one day.

This FUD always comes up from people who support the GPL and it's so annoying. Let's say that Maestro takes off and gains popularity, and then someone decides to turn it into a commercial OS. What, exactly, is supposed to be so bad about that? Nobody loses a damn thing - if you want to use the MIT licensed original project, it hasn't gone anywhere. And for those who find that there's value in the commercial version,…

> What, exactly, is supposed to be so bad about that?

The eventual users of the hypothetical commercial OS lose their freedom. (Or don't get their freedom, depending on your point of view.) Permissive licences grant users freedom, but don't preserve those freedoms in derivative works, so the original work can end up helping derived software disrespect users' freedom. For those who believe that users' freedom should always be respected, this is a very bad thing that needs to be avoided.

Re: Maestro: A Linux-compatible kernel in Rust

#309
post #129

Earlier quoted context omitted.

Just the other day they were full kum ba yah over a holiday-time-released feature that's likely going to greatly increase the likelihood of building race conditions and deadlocks. https://news.ycombinator.com/item?id=38721039

How do you figure? Is it just because it makes async possible?

https://rust-lang.github.io/async-book/03_async_await/01_cha...

Is this all information that should be communicated to a programmer, or is all this info something that should be automatically assessed by a compiler with clear responses automatically to all possible situations specified, black and white, in the code?

If so, if it is the responsibility of the compiler, why release a version of the language, stabilize a spec, where that's not the case?

Re: Maestro: A Linux-compatible kernel in Rust

#310

Earlier quoted context omitted.

For those who are wondering WTF is a Slashdot, and how does it effect websites. https://tech.slashdot.org/story/24/01/03/0017242/25-years-si... https://en.wikipedia.org/wiki/Slashdot_effect

Weird to think there are now people so young in these types of discussions that wouldn't know about Slashdot.

I was only vaguely aware of Slashdot (and never had heard this effect referred to by that name), and at 30, I'm probably more than a decade older than at least someone in this thread. If you want "weird", think of the fact that a baby named after Hurricane Katrina would be old enough to vote in this year's US presidential election.
Post reply on HN