225 points · by exists · 3y ago · 69 comments
This is mostly a restructuring of work many others have already done, and it wouldn't have been possible without them. Important parts of the Linux on M1 experience include:
Asahi Linux's m1n1 bootloader/hypervisor
Asahi Linux's kernel patches
Mark Kettenis' U-boot port
Janne Grunau's kernel configEven if he did not improve as much as he did our discussion, did you have to be so mean. It's Christmas, let him have it.
I find it valuable to skim the original article first before I'm swayed by commenters opinions.
So, welcome, glad to have you here of course.
The answer is a commented "tldr" is widely used on news.ycombinator.com, and, as comments below say, it's become a conventional courtesy: people tend to scan comments for tldrs, in order to possibly avoid digressing into commonly (but not always) long winded posts.
Here's to hoping they get it to work. And wouldn't it be nice if Apple just for once helped out and opened up their hardware.
Considering M1 is directly derived from the SoCs that run the iPhone & iPad, Apple already did a complete 180° from how locked down their mobile platforms are. All the escape hatches to run third-party OS's are easily opened, there were post-release changes to the bootloader & tooling to make booting third-party kernels easier, etc.
We don't get any official docs, but unfortunately it's not like Apple has good docs even for the stuff they do actively support...
That's why it's to easy to run any OS you like on Apple hardware, isn't it?
This would be an outrageous, almost impossible situation in car "ownership", surely resulting in class action - "I want to use my car's trunk!". But, in computers/phones it's begrudgingly accepted or sometimes even argued for.
I'm not grateful to the manufacturer that I've been graciously allowed to use all of the car I bought, and only after a team of amazing volunteer locksmiths worked day and night adapting the trunk so anyone can use it.
Sure, buy a different car, right? But this also happens to be the safest and easiest one available to drive. And this isn't because the trunk is locked. The owner could equally lock it themselves, just like the rest of the car.
Would be great to use it like any other car, and chuck that potential spyware I'm paying extra in gas to haul around with me. Not thankful that the manufacturer didn't put a stronger lock on it. Actually, I've contempt for them.
Meanwhile, other people spend far more time maintaining and protecting their cars that can use cheaper gas and they have full access to. But they have to be much more vigilant about what neighborhoods they park in, and once two years comes around they can no longer get replacement parts, and if the lock has an issue, people can trivially steal their car.
Or maybe this is just a tortured analogy to start with. If you don’t like Apple, just buy something else.
https://www.tesla.com/ownersmanual/model3/en_cn/GUID-2E8E5E0...
> Vehicle Telematics Model 3 is equipped with electronic modules that monitor and record data from various vehicle systems, including the motor, Autopilot components, Battery, braking and electrical systems. The electronic modules record information about various driving and vehicle conditions, including braking, acceleration, trip and other related information regarding your vehicle. These modules also record information about the vehicle’s features such as charging events and status, the enabling/disabling of various systems, diagnostic trouble codes, VIN, speed, direction and location. The data is stored by the vehicle and may be accessed, used and stored by Tesla service technicians during vehicle servicing or periodically transmitted to Tesla wirelessly through the vehicle’s telematics system.
Meanwhile, real men/women drive sports cars they built themselves from scrap parts.
Apple knows that you need to be patient when boiling the frog.
It should also -- at least theoretically — allow me to use Rosetta to run x86 Linux binaries. However, I'm getting segfaults when trying to build certain Nix derivations this way: https://discourse.nixos.org/t/local-x86-64-nix-builder-on-ar...
Can you "prove" that what you use NixOS for isn't overkill?
Everything I read about NixOS is how it's reproducible or something. I set up Cargo for Rust once and never thought about it again. Where does the need to reproduce toolchains come from?
Sure. At work I needed access to the office VPN. I copied a snippet into a single configuration file and everything just worked. It installed the necessary executables, and set up the needed services including the config files for these services.
Could you share that Nix VPN config file example please?
* The author is quite responsive to personal messages or issues / pull requests. * The people who fork it and change a thing or two are champions, they play with adding rust compilation to the kernel, suspend, gpu drivers all before it is added to this repo. * Once you get to just NixOS, and you tweak your editor, battery monitor, etc. It is pretty hard to switch back. Nix is hard to get right, but when you get it right, it stays that way. * I still boot back to OSX every two days when I have to share screen on Microsoft Teams or do a work thing. Takes two minutes to switch to the dark side and then a few days to remember to go back to Linux. Super polished and compatible dev machine vs fast linux on M1 with sane development environment is a great combo.
Very happy I won't need to do the nixos stuff myself!
This is also a difference from the A series which only have a single display controller, so can only drive a single display.
Anything higher than the hardware limit is done in software, like screen mirroring or any of the macOS workarounds to get more displays.
Are you referring to that Sidecar or similar software which lets you use an ipad as a second display, or are there different workarounds you're thinking of?
If there's anything hardware hackers are famous for, it's abusing hardware to get it to do unintended things. I think my favorite that isn't Linux running on a badger is the RTL SDR, so maybe there's a way to get a super shitty software muxer going, or maybe map two displays into one but drive it from software so even if there's a special dongle required, the hard work isn't being done by that dongle making it a $30 piece of kit instead of $150.
I've been patching m1n1 to gain back the extra 64 pixels at the top of the screen in the notch area. I just saw a patch go by a few days ago to add a kernel flag to enable this so I need to switch over to that.
Overall the work in this project to track the asahi changes in the nixos way is being done very well. My system feels just like my other nixos systems.
Well, to be pedantic, ring 0 is the closest thing to ARM EL1 and EL2.
https://stackoverflow.com/questions/18717016/what-are-ring-0... (scroll down to the ARM section)
Other Linux distros will have to piggyback off the work of Asahi, and I think that generally they're avoiding jumping in yet because the hardware support is not very mature.
The end goal of the project is to not require their own distribution/repos.