Linus Pooh-Pooh's Real-Time Patch 262
An anonymous reader submits "Speaking with CNet via email, Linus Torvalds appears to be in no hurry to accept the latest real-time patches from embedded specialist MontaVista into the mainstream kernel, at least not "at this time." Nontheless, MontaVista's new open-source real-time Linux project could broadly expand commercial opportunities for the open source OS, especially in telecom initially, where real-time Linux will likely play on "both ends of the wire." For example, Linux is already making progress in smartphones."
Better link (Score:5, Informative)
Re:Better link (Score:2, Interesting)
Anyone finding this suspicious? (Score:3, Interesting)
Many embedded systems have a block of non-volatile RAM seperate from normal system memory, i.e. of which the kernel maintains no memory page descriptors. For such systems it would be beneficial to mount a fast read/write filesystem over this "I/O memory", for storing frequently accessed data that must survive system reboots and power cycles. An example usage might be system logs under
Re:Anyone finding this suspicious? (Score:4, Informative)
Re:Anyone finding this suspicious? (Score:2)
This is what the big buzz around NVRAM is: Non-volatile! Doesn't need any refreshing or battery!
(and still as fast as ordinary RAM)
Patents ? (Score:2, Interesting)
Re:Patents ? (Score:2, Interesting)
Re:Patents ? (Score:4, Funny)
DOS did this back in the 80's....
Re:Patents ? (Score:4, Informative)
Re:Patents ? (Score:5, Insightful)
Re:Patents ? (Score:4, Interesting)
Re:Patents ? (Score:4, Informative)
Re:Patents ? (Score:5, Informative)
A hard realtime operating system is one where calls to the operating system are guaranteed to be executed within a certain timeframe.
is Linus ever in a hurry? (Score:2, Funny)
RTOS (Score:4, Informative)
Real Time Operating Systems. [wikipedia.org] Now you know!
Good for you! (Score:5, Funny)
Might not be in a hurry.... (Score:3, Insightful)
Re:Might not be in a hurry.... (Score:5, Informative)
I'd be shocked if he didn't realize exactly how this patch would impact Linux. From the article: Iduno what else there is to discuss...
Re:Might not be in a hurry.... (Score:3, Funny)
Re:Might not be in a hurry.... (Score:5, Insightful)
Especially given the current sue-happy folks who're looking at suing everything that is Open Source, maybe Linus is just playing it safe.
For all you know, he's trying to see if there are any IP violations before accepting them into the code-base. You never know.
Re:Might not be in a hurry.... (Score:5, Funny)
Re:Might not be in a hurry.... (Score:3, Informative)
Actually, the article hints at Linus' mastery of the issue by clueing the reader in on a few consequences of hard real time systems. The problem is that while the OS would be capable of guaranteeing a response within tens or hundreds of microseconds, the overall response time of the system is reduced. Linus is quoted as saying he believes most people, even in the embedded space, don't want this as a standard feature of the OS. This is because there's a comparatively easy fix for getting quick response ti
Re:Might not be in a hurry.... (Score:3, Insightful)
For all you know, he's trying to see if there are any IP violations before accepting them into the code-base. You never know.
Very unlikely. With respect to copyrights, Linus requires contributors to take responsibility for the ownership of their contributions, and takes them at their word. He doesn't really have any way to do anything else since our screwed up copyright regime provides protection to unpublished works -- so how could he even check? Same holds with trade secrets. With respect to paten
Re:Might not be in a hurry.... (Score:5, Insightful)
People throw around bloat with great abandon, and usually without any real rationale behind the term. In this case, you have the creator and current maintainer of one of the world's most complex pieces of software which handles millions of different configurations across hundreds of devices and architectures saying, in effect, "this patch would make the kernel too complex." That speaks to me of a level of complexity which I cannot even reasonably grasp (and I can grasp a hell of a lot of complexity).
Personally, I'd love to see RT linux for real (as opposed to semi-real-time features like low-latency and preemptability), but not at the cost of the stability of the OS. Let it mature the way PCMCIA did. Linus didn't accept that right off the bat either, and we were better off for it in the long run, as I think the PCMCIA subsystem had to work hard to maitain itself coherently while not shipping with the OS, and/or not being updated regularly.
As for bloat... I've yet to see anything that is not modularly removable from the kernel which was not essential to a modern OS. There are many cases where I'd love to drop old hardware, but that's not usually realistic. There are many modules which I have no use for, but I can always turn those off. There are many features for hardware I don't use, but removing them would be unfair to people on those platforms.
What bloat did you have in mind?
Re:Might not be in a hurry.... (Score:3, Insightful)
My point? Get off my lawn you damn kids! Heh heh heh...
inflected English (Score:3, Funny)
My OS is full-featured. Yours has feature creep. His is bloated.
Re:Might not be in a hurry.... (Score:5, Insightful)
Re:Might not be in a hurry.... (Score:5, Funny)
Sooo.. Linus is real-time, but Linux is not.
(yes, my jokes are that lame.)
Re:Might not be in a hurry.... (Score:5, Insightful)
I'd suggest the reason he is not in a hurry is that he does realize how this could help Linux, and also how it could hurt Linux. Adding real-time capability is not a free lunch.
As the original C|NET article suggests, there is a class of applications that need real-time capability (which, BTW, is mostly about being able to say that interrupt X will be handled in not more than N time units). But for most applications, real-time capability is neither needed nor really desirable: having it comes at a cost in average processing efficiency.
Incidentally, telecoms is mentioned as a possible application. I don't know enough about cellular telephony to say if it fits, and maybe there are some VoIP applications where it would make sense. But for conventional circuit-switched telecoms (e.g., a telephone switch), it really is not needed.
Re:Might not be in a hurry.... (Score:5, Insightful)
Other things are things like priority inheritance support, to prevent problems caused by priority inversion (which caused problems in the original Mars rover).
For voice support, if you don't mind crappy sound or are only handling one or two calls, you can get away without real-time, but for serious use, it is essential.
Maybe for control path processing it isn't essential, but as soon as it becomes part of the data path, real-time is essential.
It is the scope and magnitude of the patch (Score:5, Insightful)
Linus has even told IBM "no" on occasion. Not hurrying things like this is far better for the quality of Linux than any feature a contributor may want in. Linus isn't flatly refusing Montavista. He most certainly isn't flatly refusing a major feature like hard real time. He is expecting Montavista to participate the way other developers are expected to participate. In particular, Montavista doesn't get to disrupt the work of hundreds of developers because their gargantuan patch was simply dumped in the main dev tree.
This isn't petty dictatorship. The kernel devs are a battle scarred lot who don't just chuck things in because it would be "cool".
Re:It is the scope and magnitude of the patch (Score:5, Informative)
Note also that the patch hasn't really even been submitted for inclusion. The Montavista people posted it to LKML with a lot of warnings, making it clear this was intended as a way to get early feedback on the direction of their project, rather than as an example of a finished implementation.
So the slashdot headline is more than a little misleading; everybody agrees this is early in the process, and it's no suprise no-one's rushing to apply the patch.
--Bruce Fields
Re:Might not be in a hurry.... (Score:2)
Re:Might not be in a hurry.... (Score:3)
I think that Linux has a real opportunity
Linus is right. (Score:4, Insightful)
Re:Linus is right. (Score:5, Insightful)
There are many good reasons for contributors to merge their patches into the kernel. For one thing, it means you don't have to play catch-up with the kernel releases and manage the patch on top of it, and also you get to offer your code for free review and testing.
As for why Linus is always reluctant to accept new code in the kernel? simple: Firstly, if he accepted all (good or less good) ideas into the kernel, the damn thing would make coffee already, and I don't blame him to want to narrow the kernel's focus. But most importantly, just look at the size of the flippin' tarball already and you'll see why he doesn't want to include forever code that'll serve less than 0.5% of all Linux users.
Re:Linus is right. (Score:5, Insightful)
why he doesn't want to include forever code that'll serve less than 0.5% of all Linux users.
If the patched Linux goes into embedded devices there is a much bigger market than for conventional servers and desktop computers.
The millions of current desktops and servers could become 0.5% of all Linux users if embedded devices run Linux.
But I still agree that Linus' go-slow approach is wise and judicious.
Hmmm... (Score:3, Insightful)
Re:Hmmm... (Score:3, Insightful)
It's not just adding support for a filesystem. It's fundimentally changing how the kernel creates and schedules userland processes and kernel threads, prioritizes I/O, allocates memory and handles interupts. This in turn has a ripple effect on how applications work.
Re:Hmmm... (Score:2)
From what I understand of it, the issue is that it is a big chunk of code that touches and changes the core kernel code in many many places (which naturally has a lot of flow on effects down the line). That makes it a lot harder to make it a single config switch. I understand Linux is not fundamentally opposed, just opposed to trying to merge the patch in its current form in. I series of smaller modularised patche
Re:Linus is right. (Score:3, Insightful)
Aren't they just being good citizens by offering up their patches for inclusion? You know, like that GPL thing says they should?
Re:Linus is right. (Score:3, Informative)
Just to fight this stupid urban myth: The GPL doesn't say that. Please read at least the FAQ [gnu.org]. kthx.
Re:Linus is right. (Score:2)
That's not what the GPL says they should do. The GPL specifies that, if they redistribute a program, or any other work, based on the source code of Linux outside of "fair" uses [wikipedia.org] allowed by law, then that program or work must be licensed under the terms of the GPL as well. MontaVista could fork the kernel and provide their version of Linux as Montix under the GPL. Nothing say
Re:Linus is right. (Score:2, Informative)
If you read MontaVista's original announcement, it was not posted for inclusion in the mainstream kernel, no one (including MontaVista) is claiming that it is ready. They merely posted their work to stimulate discussion and to avoid duplication of effort. So of course Linus is right, no one ever said it _should_ go in the kernel now or even anytime soon.
Why was this modded "I
Re:agree 100% (Score:2)
I have a machine that has both arcnet and token ring, and I'd like a PCI HIPPI card for it (anyone have one they want to get rid of?). Slip is maybe archaic, but useful to anyone connecting older machines. Touchscreens usually present as ps/2 or serial mice... dump them too?
I've personally used the amiga and macintosh filesystems when recovering files.
But hey, let's make linux less useful to people like me. I've only been using it
Re:agree 100% (Score:2)
Re:agree 100% (Score:2)
Barely a story. (Score:5, Insightful)
Re:Barely a story. (Score:2)
remember how linus stonewalled loadable modules?
Re:Barely a story. (Score:3, Interesting)
Kernel cleanly done kernel-preemption patch went in, but the "lock-break" patch which predated it did not . That's because the latter peppered "reschedule me" calls all over the code tree. If he hadn't said "no" the first time, the later clean solution probably would not have come.
Blackadder quote (Sorry, I couldn't resist) (Score:4, Funny)
Cpt. Blackadder: Well, perhaps a little.
Gen. Melchett: Well then, damn it all, how much more evidence do you need? The pooh-poohing alone is a court-martial offence!
Cpt. Blackadder: I can assure you, sir, that the pooh-poohing was purely circumstantial.
Gen. Melchett: Well, I hope so, Blackadder. You know, if there's one thing I've learned from being in the army, it's never ignore a pooh-pooh. I knew a major: got pooh-poohed; made the mistake of ignoring the pooh-pooh -- he pooh-poohed it. Fatal error, because it turned out all along that the soldier who pooh-poohed him had been pooh-poohing a lot of other officers, who pooh-poohed their pooh-poohs. In the end, we had to disband the regiment -- morale totally destroyed
Linus "appears to be in no hurry to accept" (Score:4, Insightful)
Is it just me, or does this article sound like it's fueling steam for a fork of Linux development? If not adding steam for a fork, I have to say it's arrogant
Re:Linus "appears to be in no hurry to accept" (Score:5, Insightful)
Linus saying it looks too invasive at the moment for him to roll-in without other testing? NO ONE is going to fault him for that. Linux has gotten where it is because people can actually use it, in contrast to plenty of other experimental efforts.
No one is going to think he is arrogant for doing his jobs. These patches can work their way into some feeder kernels first, and the usual cycle can work itself out.
Too many uninformed folks like to say, "Fork!" or "Arrrogant!" without ever having actually maintained any type of code base.
What the dear poster probably doesn't realize is that there are ALREADY real time Linux kernel varients in use out there, moving stuff mainline is hardly a fork, if anything montevista is trying to get out of the separate kernel maintenance business.
Am I missing something obviou here?
Re:Linus "appears to be in no hurry to accept" (Score:4, Funny)
Yes, an s
Real Time enhancements as a fork (Score:5, Insightful)
Re:Real Time enhancements as a fork (Score:2)
[ ] Real time scheduler
[x] regular schedular (suggested for desktops and servers)
Re:Real Time enhancements as a fork (Score:2, Informative)
1: Cut Head Open
2: Poke brain with stick
3: Close Brain.
It's just a little harder than you make it out to be. Look how many of the subsystems have to be touched by this driver.
Probably because it's not "integrated" enough? (Score:2, Insightful)
Perhaps Linus objects to this topsy-turvey approach and would prefer Linux to be re-written so it's actually completely preemptible, capable of handling interrupts with RT guarantees all by itself, etc?
From LKML (Score:4, Informative)
finally, i went for correctness primarily, not latencies. I checked
out the MontaVista patches and they categorize roughly 30 spinlocks
as the ones that are necessary to be 'raw'. Unfortunately this is
inadequate, my patch excludes 90 such locks and it's still probably
not a 100% correct conversion. The core kernel needs changes in the
locking infrastructure to get rid of most of the these 90 non-mutex
locks.
What's a spinlock? (Score:2)
Re:What's a spinlock? (Score:5, Informative)
while (CheckOKtoProceed());
You see, the program "spins" until CheckOKtoProceed() returns true. The alternative is a call to a Yield(), Wait() or Sleep() function that 1) blocks execution until some condition is satisfied, and 2) tries to yield control to some other pending process while that is happening.
The trouble with a spin lock is that it hogs the processor. The trouble with the other kind of lock is that it allows another process to proceed, but it may not be safe to allow that on account of a data structure not being in a coherent state of update. A mutex is a kind of lock that by agreement of its use allows only one such process to proceed. A non-mutex lock doesn't offer such protection.
The argument is that the proposed modification make the kernel much more preemptable and do less spin locking that can kill response, but each element of the proposed modification would need to be checked and tested very carefully that after the change there aren't issues regarding the protection of data structures from multiple processes that could change it along with all kinds of mind-bending subtle bugs that can arise.
Links to better KernelTrap articles/email threads (Score:5, Informative)
Ingo Molnar - a RedHat employee/kernel hacker - has some patches that are similar in scope but different (and most likely preferable from a performance and maintainability viewpoint) in approach.
Read about them here and form your own opinion:
Linux: Real Time Kernel Prototype [kerneltrap.org]
Linux: Realtime Preemption [kerneltrap.org]
Another unexplained submission? (Score:3, Funny)
I had a feeling about this (Score:2)
I cannot wait till this functionality does finally make it into the kernel though.
Poo Poos? (Score:5, Funny)
Re:Poo Poos? (Score:2)
Billy G isn't doing Windows for the kudos of it, hes making money and stimulating an economy of babysitting a broken closed and not readily fork and fixable bit of software. And he has enough money that he can prolly buy you off if you dare suggest he Poo Poos anything.
All things being equal, this wouldn't be noteworthy.
Re:Poo Poos? (Score:2)
News flash: (Score:3, Funny)
Re:News flash: (Score:2)
There are TONS of non-mainstream things there (Score:3, Interesting)
But it's there as an option, if you want it, like most everything else. Have a tulip ethernet card? Include the driver. If you don't, leave it out. Old BIOS doesn't do ACPI? Leave it out. Don't need a keyboard driver because it's an appliance system? Leave it out.
Why the hell not just include the real-time business as options? Is the maintenance really that much more challenging?
Answer: (Score:5, Informative)
Yes. All the other obscure things which only 0.1% of everybody uses, they are small isolated pieces of code (like some random driver). What we're talking about here is adding lots of highly non-trivial code to the core of linux (you know the kernel/ subdirectory of the kernel source) which only 0.01% of people will actually need/use. So, yes.
I also think it would be quite arrogant of the RT people to expect this to be added without serious thought (and possible reworking). (NOTE: I'm not saying they do/did expect it to, just that it would be arrogant to do so)
Re:There are TONS of non-mainstream things there (Score:5, Insightful)
Let me start out by saying that I'm not a kernel developer, as are most people on /., but I do get to maintain some C and C++ code on a regular basis.
A lot of the stuff in 2.6 may be useless to most people, but it's there because it's being maintained, is 99% stable and compatible with the current kernel ABI. You see, thread locking in general is a complicated matter, and I can only imagine how complicated all the locking code in the kernel is.
The RTL patch does some major adjustments to the internals of the linux kernel, and from what I gather has been just dumped into Linus' and co's mailbox. This is simply not done in ANY development project. Maintainers don't accept huge patches that change stuff everywhere on the belief that source code works. Hell, if there's a lock somewhere that isn't freed in some exceptional case your shiny new version of software X grinds to a halt often leaving end-users scratching their heads and developers gritting their teeth.
I was on a development project once where one of the coders had an inspirational idea and rewrote some shabby but working code into (what he called) clean and efficient code. It was a hefty patch and didn't break the program at first. But due to a bug in thread locking in "some" conditions, only 2 months later we found out some really nasty things about this "clean and efficient" code. Alas, it was too late to revert to our old model, and eventually spent a lot of time debugging and banging our heads against the wall. The guy was fired.
The point I'm trying to make is that you shouldn't judge people for being wary of accepting large globs of patches for software that already works great. Sure, linux can benefit a lot from this if it provides a foot in the door of telecom, but at the moment it's being used actively in many other areas. This article just seems bent on critisizing Linus for not including something because he believes there may be issues.
Real time Linux could win the house. (Score:3, Informative)
Re:Real time Linux could win the house. (Score:2)
Now, if you were cont
Alternatives? (Score:3, Interesting)
Re:Alternatives? (Score:3, Informative)
RT-Linux (and RTAI which is roughly based on RT-Linux but offers a different API) is very different. It runs as a hard real-time micro-kernel which takes over your system and then runs all of Linux as a thread. When you run your hard real-time code it runs in that micro-kernel space r
It is not only embedded systems that will benefit (Score:2)
Never looked back, especially since they made us all red
The rah-rah supporters are missing the real issue (Score:5, Insightful)
Imagine that you run a pizza shop that MUST meet a certain delivery time guarantee or fail (go out of business--an RTOS MUST meet the guarantee to "be in business" at all). Before you were an RTOS, you could afford to promise pizzas in 15 minutes, with a 90%+ success rate, but if your head will roll if you fail at all, you won't advertise anything better than 30 -or even 60- minutes. I mean, what happens if a custom pizza gets ruined in the oven? You need time to make a new one.
You'll also need more hardware for the same tasks (more delivery cars), restrict services (smaller delivery area, fewer options), and institute effort-intensive safeguards to assure that no pizza order slips through the cracks. As I said: RTOS isn't magic; adding NEW performance demands won''t magically enable you to do more with less. Quite the contrary, it usually means doing less with more -- but presumably doing it better (assuming that the new requirement *is* better for your specific needs).
Would you embrace a hardware technology that slowed down your computers, and offered little or no benefit for most (or all) of the tasks you do? There are plenty of examples in he market, and we rightfully shun them as "unnecessary for us". That's the choice Linus faces: most users won't experience any benefit, so why include it in the kernel and make everyone pay the (performance and complexity) price?
I applaud the availability of a Real-Time patch or variant (I've wanted one for a long time, and I've used Wind River for those applications), but for most people or even 99% of my applications, it's pure downside, even if reworking the kernel to allow its inclusion only decreases performance or complicates programming by 1%.
Sure, in time --maybe a couple of years-- it may be streamlined until the RTOS burden is miniscule. Until then, Let the Real Time people deal with the issues and limitations inherent in their task. 99.99% of us don't need the unnecessary baggage in our OS. It'd be like mandating infan/child car seats in all cars, whether they carry kids or not.
Re:The rah-rah supporters are missing the real iss (Score:2)
Some of Ingo Molnar's work is just to push down kernel latency in a general way, which is acceptable and more incremental in the mainline, while laying down an archetecture that makes it easy for a hard RT patch to be maintained, with minimal impact on the kernel.
Linux will never default to being a true RTOS across the board, forever and ever amen. So, while you're ri
What is it needed for? (Score:3, Interesting)
I would hardly call this "pooh-poohing." (Score:5, Insightful)
The Linux kernel is too monolithic for this (Score:5, Informative)
If you want hard real time and protected mode, you need an architecture like that of QNX [qnx.com], where almost everything runs in user space. File systems, drivers, and networking are all user programs, intercommunicating by message passing. The kernel only handles CPU dispatching, memory management, and message passsing.
In an architecture like that, everything in user space is preemptable, without any extra work in the system services. There are no long latencies in the QNX kernel; they were all taken care of years ago.
As Linus points out, though, few consumer embedded devices really need hard real time. Most media-related stuff can paper over delays with buffering. A classic comment is, "You run your web server on Linux. You run your nuclear reactor on QNX".
Automotive systems, though, really need it. QNX is big in that market.
Re:The Linux kernel is too monolithic for this (Score:2)
Re:The Linux kernel is too monolithic for this (Score:2)
I'd rather have a nuclear reactor that has inherent safety mechanisms rather than one that depends on a piece of silicon running human-written software for not going into meltdown.
Re:The Linux kernel is too monolithic for this (Score:3, Informative)
This is where the Linux architecture, with drivers in the kernel, really bites you. Because all the drivers have to be made preemptable, too. This is at odds with the traditional UNIX "top and bottom" driver architecture, with the "top" running as a process and the "bottom" running at interrupt level.
Actually the Linux architecture isn't as bad as you imply in this respect. Although Linux does follow the traditional top/bottom separation (though in Linux terminology, at least, the "bottom" half is the
LKML reference (Score:4, Informative)
Should we be worried? (Score:2)
Huh? Oh.
No big deal (Score:2, Insightful)
If the patches were mature and worked well, and Linus rejected them, it would be news. For now he is just saying "Show me the money". Nothing new, the burden of proof is on people who introduce new features like this to prove them stable, and it just hasn't happened, yet.
Re:first post!!! (Score:4, Funny)
Re:MontaVista Rocks (Score:4, Funny)
Yes, I'm sure he has no idea...
Re:MontaVista Rocks (Score:3, Insightful)
Re:MontaVista Rocks (Score:3, Insightful)
Whether this "aim for everything"-attitude is a good one for the Linux kernel as a whole remains unquestioned for now.
Re:MontaVista Rocks (Score:2)
So thanks for the inside scoop.
Re:MontaVista Rocks (Score:2)
Re:MontaVista Rocks (Score:5, Insightful)
It would not suppise me at all if this lives a long and fruitful life outside of the standard kernel, as a stand-alone patch set. That's not even a bad place to live, especially since the requirements are rather esoteric.
Re:Pooh-Pooh's? (Score:2)
Also, it seems to me that I saw that in a War Games once, that they wanted to get the men out of the loop and let computers start making decisions on their own. Basically, in the movie, that was a bad idea.
Peace Out.
Re:Pooh != Poo (Score:2)
Re:Pooh != Poo (Score:2)
Note to Moderators: SOMETHING CAN'T BE REDUNDANT IF IT WAS THE FIRST ONE.
Re:TELECOM!!! (Score:2)
Re:Can this be a config parameter? (Score:3, Interesting)
#ifdef REAL_TIME_KERNEL
#endif
It's going to change a lot of things in a lot of places. Ideally, it will make infrastructure changes which benefit everyone, by abstracting certain elements of the code, which then makes its own specific features fit in nicely. Unfortunately, this is very difficult to do with real-time sch