News for hackers. Stuff that matters.
Re:Building a faster, smarter, Chromebook experience with th... by gtirloni on Wednesday June 12, 2024 @09:51PM (#40665142)
How's that even an issue in Linux? If anything, vanilla Linux users have way more power over their computing platform and are never locked out of anything.
Re:Building a faster, smarter, Chromebook experience with th... by fooker on Wednesday June 12, 2024 @10:08PM (#40665242)
What is vanilla Linux though?

If you're talking about something like Ubuntu, there's a tonne of work that goes into making sure it works with ..say.. a random three year old laptop with all the binary blobs in place.

Try getting something like wifi or Bluetooth working on some weird ARM dev board and suddenly there's no vanilla Linux unless you're willing to write device drivers.

Re:Building a faster, smarter, Chromebook experience with th... by eddythompson80 on Wednesday June 12, 2024 @11:09PM (#40665539)
> there's a tonne of work that goes into making sure it works with ..say.. a random three year old laptop with all the binary blobs in place.

But that work gets done and "users" of Ubuntu or Debian or Arch get to use it from the sources they trust (aka Ubuntu, Debian or Arch). I'm not claiming to have a full understanding of how every package or kernel module Debian or Arch or Fedora ships works. But I'm trusting Debian or Arch or Fedora for my packages. If it comes to light that debian or fedora maintainers had no idea that they shipped a malware in a release, then I'll seriously question going with that distribution in the future. And without sounding facetious, that has happened multiple times in past especially with debian. But the times it happened it was clear to me that it was merely a mistake rather than extreme incompetence or malice.

With Android, you have Google, which despite the general HN rhetoric I personally trust to not ship straight up malware. But when we're talking about Android that's not what we're talking about. We're often talking about binary ROM blobs from random XDA or RW users. Funny thing is 20 years ago, I'd have shouted about what's the difference between a random anon on XDA or WZBB providing a ROM blob. But now I know better.

Re:Building a faster, smarter, Chromebook experience with th... by fooker on Thursday June 13, 2024 @03:01AM (#40666795)
You trust Canonical, android users trust Google.

Binary blobs are an unfortunate reality and no amount of trust in a company or entity can really solve this.

For the record, Debian and Arch doesn't work very well on non standard hardware. I use arch on my desktop but gave up on using it productively on a new HP laptop.

Re:Building a faster, smarter, Chromebook experience with th... by oblio on Thursday June 13, 2024 @07:30AM (#40668306)
Heh, and you could argue that laptops are standard these days. More laptops are sold than desktops, and HP is definitely a mainstream brand.

I understand your usage of the word, I'm just pointing out that if the mainstream ain't "standard" anymore... it kind of sets the standard in practice.

Re:Building a faster, smarter, Chromebook experience with th... by blackoil on Wednesday June 12, 2024 @10:56PM (#40665466)
That should be true for everything, if no one has written drivers for something it won't work. But once driver is added will it fail/updated for newer versions of Linux?
Re:Building a faster, smarter, Chromebook experience with th... by chem83 on Wednesday June 12, 2024 @11:33PM (#40665671)
The reality is that drivers are not added, as you say. Most companies release an out-of-tree BSP targeting a specific kernel version. They often contain blobs and are often not GPL. Linux doesn't support a stable kernel ABI/API (https://www.kernel.org/doc/Documentation/process/stable-api-...) and the only way to avoid the associated issues is to mainline drivers, which most companies don't want to do (don't want to open source their IP, don't want to invest in maintaining it etc.)

Android GKI/KMI addresses the issues related to this. GKI is relatively recent and OEMs don't offer 5+ years of Android updates because they haven't adopted it yet.

Re:Building a faster, smarter, Chromebook experience with th... by codedokode on Thursday June 13, 2024 @01:20AM (#40666203)
That Linux note about why they don't want a stable API is ridiculous. This shows how unfriendly is Linux to out-of-tree software. They want third-party developers to refactor their working and tested drivers every time they decide to change something.

I think that at least open source community should move to "never break things" concept. So that you can write and test code once and never touch it anymore. Refactoring your code because kernel/library has changed its interface is just a waste of time which gives nothing in return, often time of unpaid volunteers who could do something useful instead.

This should apply to libraries, applications, programming languages, browser extensions. Take upgrading your Python 2 code to Python 3 as an example. You need to put a lot of efforts while gaining nothing. This is not how software should work. You should write a code once and it should work forever without any maintainance.

Re:Building a faster, smarter, Chromebook experience with th... by guitarlimeo on Thursday June 13, 2024 @01:52AM (#40666351)
Correct me if I'm wrong, but I thought that the actual code itself is stable, just that the compiled kernel API/ABI isn't.

So if you open source your drivers and get them accepted into the kernel, then you don't need to rewrite/recompile them for each new kernel version. Just like AMD did with their drivers. And I think this is part a conscious decision that forces people to open source drivers.

But this is honestly just guesswork based on what I've read, would love to learn more!

Re:Building a faster, smarter, Chromebook experience with th... by afiori on Thursday June 13, 2024 @03:43AM (#40667026)
> So if you open source your drivers and get them accepted into the kernel, then you don't need to rewrite[...] them for each new kernel version.

You don't, but someone does. In the note linked above they give an example of how the USB interface changed from synchronous to asynchronous, this must have required some refactoring in all drivers that used USB

Re:Building a faster, smarter, Chromebook experience with th... by vetinari on Thursday June 13, 2024 @04:21AM (#40667215)
That someone updating the drivers is exactly the same person who makes the change in the subsystem that they depend on. They cannot break what is already in the kernel, but they can break what's outside; it is after all an internal API.
Re:Building a faster, smarter, Chromebook experience with th... by codedokode on Thursday June 13, 2024 @06:18AM (#40667854)
And that is wrong because people might have reason not to mainline drivers.
Re:Building a faster, smarter, Chromebook experience with th... by vetinari on Thursday June 13, 2024 @06:55AM (#40668057)
That's fine; but their reason is their problem. They are not entitled to free labor of other people.
Re:Building a faster, smarter, Chromebook experience with th... by pantalaimon on Thursday June 13, 2024 @08:23AM (#40668771)
What reasons are there other that corporate shenanigans? Sure it takes more effort to mainline the driver and address review comments, but if you aren't designing a throw-away product, it's effort well spent.
Re:Building a faster, smarter, Chromebook experience with th... by account42 on Thursday June 13, 2024 @09:10AM (#40669213)
Those reasons tend to be petty ones that benefit the hardware company and noone else. Seems fair that the hardware company should pay for the consequences of their decisions and not the people advancing the kernel.
Re:Building a faster, smarter, Chromebook experience with th... by Propelloni on Thursday June 13, 2024 @04:47AM (#40667345)
The Linux developer community promised almost 20 years ago [1] that no release of the stable kernel will ever break something that worked in a stable kernel before. AFAICT, this promise holds. If you upstream your driver, the community will take care (cf. AMD), if you don't your users experience occasional pain (cf. NVidia).

[1] http://kroah.com/log/blog/2018/02/05/linux-kernel-release-mo...

Re:Building a faster, smarter, Chromebook experience with th... by exe34 on Thursday June 13, 2024 @03:08AM (#40666827)
> They want third-party developers to refactor their working and tested drivers every time they decide to change something.

no, they do it for you for free - you just have to make sure the quality is high enough to merge into mainline.

Re:Building a faster, smarter, Chromebook experience with th... by codedokode on Thursday June 13, 2024 @06:19AM (#40667860)
That's exactly what I meant: Linux is unfriendly to third-party software developers (drivers not in kernel, apps not in distro repositories).
Re:Building a faster, smarter, Chromebook experience with th... by exe34 on Thursday June 13, 2024 @08:07AM (#40668646)
I know a lot of people who are unfriendly towards sloppy work, yes. if the driver is of a good enough quality, they will be happy to take it off your hands and look after it for you!

as a user, I hate apps that aren't in the repository. it takes effort to make sure it doesn't clobber something important just because the developer wanted to use the latest and most broken version of some library. thankfully nixos allows me to run whatever version of every dependency and then nuke the whole mess once I'm done with it.

Re:Building a faster, smarter, Chromebook experience with th... by codedokode on Friday June 14, 2024 @02:59AM (#40678241)
> I hate apps that aren't in the repository

That's not going to be fixed. This is a typical M-N problem. There are too many distros and it would require lot of work to port every app to every distro. Instead, there should be a "platform" (set of APIs) that app can work with and the same app would be able to work in any compatible distro.

Re:Building a faster, smarter, Chromebook experience with th... by exe34 on Friday June 14, 2024 @05:47AM (#40679221)
To be fair, if the app isn't in the nixos distro, it's rarely that useful. The only one I had to figure out was a proprietary logic analyser interface, but it wasn't too hard.
Re:Building a faster, smarter, Chromebook experience with th... by vetinari on Thursday June 13, 2024 @04:19AM (#40667208)
> Take upgrading your Python 2 code to Python 3 as an example. You need to put a lot of efforts while gaining nothing.

Just the python's 3 string/binary distinction and explicit conversion squashed an entire category of bugs. Yes, it required to make explicit what was implicit before, but still, that's huge achievement in my book; saying that it is nothing is a very, very shortsighted.

Re:Building a faster, smarter, Chromebook experience with th... by account42 on Thursday June 13, 2024 @09:11AM (#40669228)
> Just the python's 3 string/binary distinction and explicit conversion squashed an entire category of bugs.

And created an entire category of new ones.

Re:Building a faster, smarter, Chromebook experience with th... by lupusreal on Thursday June 13, 2024 @04:30AM (#40667255)
> and the only way to avoid the associated issues is to mainline drivers, which most companies don't want to do (... don't want to invest in maintaining it etc.)

They wouldn't have to, that would be done for them, for free, if they got their code into the kernel...

Re:Building a faster, smarter, Chromebook experience with th... by fooker on Thursday June 13, 2024 @02:57PM (#40673236)
A driver is not a static one time thing.

Once you mainline it, making improvements, supporting new devices and features become 10x slower.

Re:Building a faster, smarter, Chromebook experience with th... by lupusreal on Thursday June 13, 2024 @03:27PM (#40673559)
Nobody says the old mainlined driver must support new devices. Mainline a new driver, or don't, either way it's better than nothing.
Re:Building a faster, smarter, Chromebook experience with th... by fooker on Thursday June 13, 2024 @04:39PM (#40674450)
Yeah, better than nothing.

With a stable ABI, it would be better than everything. But we can't have it because of ideological reasons.

Re:Building a faster, smarter, Chromebook experience with th... by zamadatix on Wednesday June 12, 2024 @11:13PM (#40665564)
It depends on how open the particular drivers are implemented. E.g. over the last couple of years the Nvidia driver situation for cards from the last 3 generations has changed across pretty much all 3 major levels:

1. Originally you had to use the proprietary binary driver to get anything useful to happen with your card at all. Updating the kernel without updating this would more or less lead to having an expensive brick in your PC. Some Wi-Fi adapters fall into the "can't really be updated" category as well. A _LOT_ of ARM shit is like this.

2. nvidia-open came along (still beta for desktop cards at the moment) and it puts enough in the kernel that you can update the kernel without needing an updated binary driver for your card to function

3. nouveau/nvk have very recently started to come to a decently usable state (i.e. they have reclocking via GSP and somewhat usable graphics API coverage/efficiency) for an even more open driver stack which tracks system updates even better.

If your binary blobs fall into 1/2 then long term upgrades can be anywhere from impossible to unreliable. If they fall into 2/3 they can be anywhere from somewhat reliable to "will be working longer than any sane person would still be trying to update the kernel on that device". E.g. the AMD 7750 is 12 years old but can run OpenGL 4.6 and Vulkan via the latest AMDGPU driver in mainline mesa/kernel.

LTS distros solve this by using LTS kernels and security patching them rather than requiring "actual" underlying OS updates during the version lifecycle.

Re:Building a faster, smarter, Chromebook experience with th... by fooker on Thursday June 13, 2024 @03:04AM (#40666806)
If the kernel had a stable ABI and made it a bit easier for closed source drivers to access kernel APIs, yes.

That's how you can use a random 25 year old peripheral on multiple versions of Windows without anyone having to update a driver.

Re:Building a faster, smarter, Chromebook experience with th... by realusername on Thursday June 13, 2024 @03:55AM (#40667093)
In theory maybe, in practice I'd bet in a better Linux support on a 25 year old peripheral compared to Windows.
Re:Building a faster, smarter, Chromebook experience with th... by fooker on Thursday June 13, 2024 @03:24PM (#40673529)
Out of the box, sure.

For windows you can usually download a binary from some 20 year old website and it'll work.

Re:Building a faster, smarter, Chromebook experience with th... by vetinari on Thursday June 13, 2024 @04:22AM (#40667220)
That's also how you make windows ship with three different USB stacks and their weird interaction.
Re:Building a faster, smarter, Chromebook experience with th... by fooker on Thursday June 13, 2024 @04:40PM (#40674468)
For sure. The real world of devices is messy.

Avoiding that mess for some notion of beauty or purity only gets you so far.

Re:Building a faster, smarter, Chromebook experience with th... by sambazi on Thursday June 13, 2024 @04:55AM (#40667392)
> What is vanilla Linux though?

depends; but may i suggest starting at kernel.org then look at 'linux from scratch'/gentoo then maybe slackware; surely not ubuntu

Re:Building a faster, smarter, Chromebook experience with th... by anthk on Thursday June 13, 2024 @07:25AM (#40668268)
- Linux it's just a kernel.

- Vanilla Linux it's propietary.

- GNU/Linux-Libre it's the proper libre one, rebased from GNU maintainers.

- There's no proper 'Vanilla distro' as LFS or Gentoo. Every one since 1993 has been an external bundle made from volunteers.

- The closest vanilla distro from the GNU project would be Guix as it works as a distro and a universal package manager to ship libre software.

Re:Building a faster, smarter, Chromebook experience with th... by fooker on Thursday June 13, 2024 @02:23PM (#40672885)
May I suggest trying your hand on LFS on a ARM dev board and report how the experience goes?

There's a reason all other kenels have adopted a stable driver API and ABI.

Re:Building a faster, smarter, Chromebook experience with th... by 1oooqooq on Thursday June 13, 2024 @11:36AM (#40670973)
you understand little about what you're talking about.

hardware is either supported or not.

the "work" you mention on old wifi cards is to get a driver that was never contributed in any official way. hence unsupported.

Linux have more hardware support out of the box than anything, ever.

just educate yourself before purchasing.

Re:Building a faster, smarter, Chromebook experience with th... by fooker on Thursday June 13, 2024 @03:21PM (#40673492)
> hardware is either supported or not.

This reminds me of certain countries that define literacy as the ability to sign ones name.

Linux driver support for a large fraction of hardware is incomplete at best.

Re:Building a faster, smarter, Chromebook experience with th... by lmm on Wednesday June 12, 2024 @11:26PM (#40665636)
Linux offers no stable driver API; they claim that submitting your drivers into the kernel tree is a good substitute, but they have strict requirements on what kind of code they will accept and also decline contributions out of basically organisational politics reasons. So in practice you're locked out from any old or obscure hardware unless you have a lot of time to spend playing kernel politics, keeping up with their API changes, or both.
Re:Building a faster, smarter, Chromebook experience with th... by Zambyte on Thursday June 13, 2024 @12:22AM (#40665909)
I wonder if Linus has ever made the connection between this problem and his stance against applying the Unix philosophy to kernels :P
Re:Building a faster, smarter, Chromebook experience with th... by account42 on Thursday June 13, 2024 @09:18AM (#40669304)
> they have strict requirements on what kind of code they will accept and also decline contributions out of basically organisational politics reasons

They accept only code which they will be able to maintain, yes. That excludes spaghetty or implementations of complex undocumented APIs that are useless without a binary blob. Nothing unreasonable about that.

Re:Building a faster, smarter, Chromebook experience with th... by Wytwwww on Thursday June 13, 2024 @11:22AM (#40670798)
It's unreasonable if there aren't any reasonable alternatives.
Re:Building a faster, smarter, Chromebook experience with th... by account42 on Friday June 14, 2024 @03:50AM (#40678583)
How is it unreasonable that the kernel developers expect those that want to rely on their existing and continued work to put in a modicum of effert to not make said kernel developers life more difficult?
Re:Building a faster, smarter, Chromebook experience with th... by lmm on Thursday June 13, 2024 @06:49PM (#40675733)
Perhaps. In my experience a bad driver is better than no driver; not wanting bad code in your codebase is reasonable, but gets less reasonable when you also refuse to offer an API. And even if your code does meet their quality requirements, it can still get rejected for kernel-politics reasons.
Re:Building a faster, smarter, Chromebook experience with th... by account42 on Friday June 14, 2024 @03:48AM (#40678569)
Unless you are going to provide examples then I am going to assume that " kernel-politics" refers to things like rejecting "drivers" that can only used with a closed source userspace blob. In those cases the reasons have technical merit - how are the kernel developers supposed to maintain an effectively proprietary API without any idea how it is being used.
Re:Building a faster, smarter, Chromebook experience with th... by lmm on Sunday June 16, 2024 @06:05PM (#40700509)
No, I'm talking about cases of not liking the way of doing things, e.g. how we ended up with CFS which was a watered-down reimplementation. (ReiserFSv4 is another example of code that met the technical bar and was rejected for purely non-technical reasons, as much as few would disagree with that).
Re:Building a faster, smarter, Chromebook experience with th... by 1oooqooq on Thursday June 13, 2024 @11:42AM (#40671036)
> in practice you're locked out from any old or obscure hardware unless you have a lot of time to spend playing kernel politics, keeping up with their API changes, or both.

no sympathy. you're also out of luck using old hardware in the first place because the manufacturer wants you to buy the new version. they will help you LESS than Linux devs. you're point is very unhelpful to the discussion, unless you got drivers updates from the manufacturer

Re:Building a faster, smarter, Chromebook experience with th... by lmm on Thursday June 13, 2024 @06:47PM (#40675714)
> you're also out of luck using old hardware in the first place because the manufacturer wants you to buy the new version. they will help you LESS than Linux devs.

The manufacturer probably doesn't exist any more. They wrote decent drivers and supported them for a number of years, that should be enough. Or maybe a dedicated fan wrote some OSS drivers at some point in the past. On both Windows and FreeBSD that's good enough; once a driver has been written, it largely stays working, so I can keep using my hardware. This really is a unique downside of Linux.

Re:Building a faster, smarter, Chromebook experience with th... by kccqzy on Wednesday June 12, 2024 @09:57PM (#40665186)
I think you've only experienced Linux on Intel/AMD, not Linux on ARM SOCs.
Re:Building a faster, smarter, Chromebook experience with th... by gtirloni on Thursday June 13, 2024 @10:18AM (#40669998)
I'm looking at several ARM devices running Linux on my desk right now. What's your point?
Re:Building a faster, smarter, Chromebook experience with th... by faust201 on Thursday June 13, 2024 @02:06AM (#40666421)
I dont think they are the target market. E.g. Some people will never buy computers but only assemble them; some will only run freeBSD or linux. For vast majority - just open and use the computer.
Re:Building a faster, smarter, Chromebook experience with th... by jeffbee on Thursday June 13, 2024 @11:20AM (#40670768)
This "power" is hypothetical unless you are willing to DIY all the drivers, which you will be writing blindly without datasheets. Vanilla Linux doesn't support IPU6 webcams, Qualcomm WiFi 7 chips, and dozens of other common parts.