Beta
×

Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

Linux 2.6.22 Kernel Released

kdawson posted more than 7 years ago | from the when-you-must-have-the-latest dept.

Software 273

An anonymous reader writes "Linux creator Linus Torvalds announced the official release of the 2.6.22 kernel: 'It's out there now (or at least in the process of mirroring out — if you don't see everything, give it a bit of time).' The previous stable kernel, 2.6.21, was released a little over two months ago. New features in the 2.6.22 kernel include a SLUB allocator which replaces the slab allocator, a new wireless stack, a new Firewire stack, and support for the Blackfin architecture. Source-level changes can be tracked via the gitweb interface to Linus' kernel tree."

Sorry! There are no comments related to the filter you selected.

fr0sty p1ss (-1, Offtopic)

Anonymous Coward | more than 7 years ago | (#19797787)

first post!!!

Re:fr0sty p1ss (-1, Offtopic)

Anonymous Coward | more than 7 years ago | (#19797791)

Damn... and I wanted to serve up a tall mug of the frosty piss to all, you bartard!
 

Re:fr0sty p1ss (-1, Offtopic)

Anonymous Coward | more than 7 years ago | (#19797953)

who's stopping you? I, for one, welcome our new frosty piss serving overlords.

What is this? (5, Funny)

Whiney Mac Fanboy (963289) | more than 7 years ago | (#19797789)

Seriously, what the fuck is going on with slashdot?

I've read & reread the linked articles, and not a single mention of the iPhone - and it's been over 48 hours since an iPhone story. Seriously - it's like slashdot's turned into a linux site, instead of an iPhone site.

Let's not forget our roots folks - just because linux is the big hype story today.

Re:What is this? (5, Funny)

Corporate Troll (537873) | more than 7 years ago | (#19797835)

You do justice to your nickname.

Re:What is this? (5, Funny)

Whiney Mac Fanboy (963289) | more than 7 years ago | (#19797923)

You do justice to your nickname.

Thank you, but I do feel that there's a little too much redundancy in my nick. I mean, if I was called "mac fanboy", you'd assume whiney.

For that matter, if I was just called 'mac', everyone would read the implied 'whiney fanboy'

Re:What is this? (3, Funny)

Corporate Troll (537873) | more than 7 years ago | (#19797959)

Nah, redundancy just enhances your whiney-ness, making it effectively recursive and without a stop condition that makes you infinitely whiney. Perfect for a Mac fanboy ;-) (1, Infinite Loop... and all...)

Re:What is this? (3, Informative)

smitty_one_each (243267) | more than 7 years ago | (#19798315)

Indeed, you are a double pleonasm [reference.com] , and should take pride in your superfluous redundancy.

Re:What is this? (0, Troll)

iMac Were (911261) | more than 7 years ago | (#19798573)

Redundancy is like cock up your ass. You can never, never, have too much of it.

Re:What is this? (0)

Anonymous Coward | more than 7 years ago | (#19798595)

Doesn't take much common sense to see that we needn't put the pee-pee in the poo-poo.
Form follows function.

Re:What is this? (2, Funny)

Bob54321 (911744) | more than 7 years ago | (#19798447)

I only just noticed that it was Whiney. I always read Whitney. I should have realized - I mean girls on slashdot, what next?

Fire and brimstone coming down from the skies. Rivers and seas boiling. Forty years of darkness. Earthquakes, volcanoes... The dead rising from the grave. Human sacrifice, dogs and cats living together - mass hysteria.

Re:What is this? (1)

Whiney Mac Fanboy (963289) | more than 7 years ago | (#19798479)

I only just noticed that it was Whiney. I always read Whitney.

Whitney mac fanboy? Is that someone called whitney who's a mac fanboy? Or a fanboy of whitney macs? Either way, I'm going to assume you watched the bodyguard waaaaaaaaaaaaaaaaay to many times ;-)

Re:What is this? (1)

Bob54321 (911744) | more than 7 years ago | (#19798531)

I honestly can say I have never seen the Bodyguard (or Titanic). I hardly ever have time to watch movies at the cinema and by the time they get to video I just can not bring myself to listen to the soundtrack one more time...

Re:What is this? (0)

Anonymous Coward | more than 7 years ago | (#19798865)

I beg to differ. If you were just called "Mac", I would assume you're a large trucker wearing plaid who somehow bumped into slashdot by mistake. (Perhaps you assumed that slashing dots had something to do with truck racing?)

Re:What is this? (0)

Anonymous Coward | more than 7 years ago | (#19797861)

You will be returned to regularly scheduled programming once they get the iphone to koad the linux kernel.

Not even a direct download link! (0)

Anonymous Coward | more than 7 years ago | (#19797981)

And there isn't even a direct download link [kernel.org] the full file in question...

Ummm, I guess now is the opportune time to wish the kernel.org sysops some good luck?

Re:What is this? (4, Funny)

CopaceticOpus (965603) | more than 7 years ago | (#19798059)

Seriously - get 2.6.22 running on an iPhone, THEN we'll have a story!

Re:What is this? (2, Interesting)

smitty_one_each (243267) | more than 7 years ago | (#19798443)

2.6.22 certainly has the scalability, but does it hate itself sufficiently?

Re:What is this? (2, Funny)

Anonymous Coward | more than 7 years ago | (#19798627)

I've read & reread the linked articles

You must be new here, then

Re:What is this? (-1, Redundant)

Anonymous Coward | more than 7 years ago | (#19798839)

Correction: This is NOT an 'iphone' site. Try www.apple.com The iphone was featured on the main site however, not this, the Linux section of the Slashdot.

What's SLUB? (1, Interesting)

borizz (1023175) | more than 7 years ago | (#19797803)

TFA is /.ed and wikipedia doesn't help me. What's so good about the SLUB allocater?

Re:What's SLUB? (5, Informative)

b1ufox (987621) | more than 7 years ago | (#19797877)

http://lwn.net/Articles/229984/ [lwn.net]

There for you, help yourself.

BTW in short plain english, it adds some voodoo stuff to struct page, removes a lot of metadata cruft from the slab allocator, adds lesser and simple locking after removing most of locks which are not required because of the changes in the cache layer.

So if you are running your kernel on a huge farm of processors of the order of thousand(s), you ll find a remarkable memory saving, which is a big overhead in slab allocation.

HTH

Re:What's SLUB? (5, Funny)

hmallett (531047) | more than 7 years ago | (#19798177)

it adds some voodoo stuff to struct page

I believe that brings the amount of the Linux kernel containing Voodoo to 13%.

Re:What's SLUB? (1)

mrbluze (1034940) | more than 7 years ago | (#19798025)

I dunno.. maybe it means it'll run Linux.

question on the wireless (-1, Offtopic)

Adult film producer (866485) | more than 7 years ago | (#19797841)

I just installed ubuntu on an old laptop (presario p3-600.) The installation was a breeze, answered about a dozen questions and everything installed.. automatically restarted and the gnome desktop loaded up and was working the first try. I figured linux would have a lot of issues with laptop hardware but it seems to be handling it very well, touchpad works, battery applet recognizes whether its plugged in or not.. etc etc. Anyways, I was thinking of adding one of these USB wireless accessories.. could anybody here recommend one that has a good track record of working in linux ?

Re:question on the wireless (1)

nowhere.elysium (924845) | more than 7 years ago | (#19797879)

It's a wee bit offtopic, but try this: http://www.linuxquestions.org/questions/showthread .php?t=462105 [linuxquestions.org] Insofar as I'm aware, Linksys ones tend to work ok.

Re:question on the wireless (1)

the Hewster (734122) | more than 7 years ago | (#19798589)

Linksys ones tend to work ok.
No, Linksys, like most manufacturers, often change the chipset they use in their wifi cards. So you basically don't know what your buying when you get a Linksys card and it's hit or miss to get it working. When using Linux you need to look for a wifi card with either a ZyDAS or Ralink chipset. If you can't find out what chipset the card is using, don't buy it! Find one where you can tell.

Re:question on the wireless (1)

nowhere.elysium (924845) | more than 7 years ago | (#19798623)

Fair enough. The last couple of USB WiFi dongles I used were Linksys, and they were fine. Nonetheless, you're right: they do have a habit of buggering about with the chipset every so often...

Re:question on the wireless (1)

paxmark1 (636441) | more than 7 years ago | (#19797907)

I got a Hawking USB with an antenna on it. That really helps me to leech, er, acess the web. It is RT73. I had to configure it manually, but works well now. Documentation a little turgid, but it works. The Edi-Max site probably has a slick set up for it by now. Kubuntu.

The USB ones can be exceedingly difficult to get to work. The directional antenna on this one really does work for me.

Re:question on the wireless: easy answer (1)

the Hewster (734122) | more than 7 years ago | (#19797991)

Anyways, I was thinking of adding one of these USB wireless accessories.. could anybody here recommend one that has a good track record of working in linux ?
anything from ZyDAS or Ralink should have good (and ever improving) fully supported, GPL drivers.

Re:question on the wireless (0)

Anonymous Coward | more than 7 years ago | (#19798011)

dude go back to digg

Re:question on the wireless (3, Informative)

Technician (215283) | more than 7 years ago | (#19798221)

Anyways, I was thinking of adding one of these USB wireless accessories.. could anybody here recommend one that has a good track record of working in linux ?

I would recommend using one of the PCMCIA cards instead. Find one that uses the Anthros chipset. I picked up a D-LINK one that was recognised by Dapper Drake. I didn't need to install NDIS Wrapper of Network Manager. I don't remember the model number of the card, but setting it up was as easy as setting it up in Windows except I didn't need to use the setup CD that came with it. Dapper recognised it as an Unknown Wireless. Properties showed it has an Anthros chipset made by D-Link. From there I gave it a static IP on my LAN and plugged in the WEP key after picking my SSID from a list. I added some DNS listings and put in the gateway address of my router and I was online. There have been some difficulty with configuring many of the USB cards. Check the forums and purchase carefully.

Re:question on the wireless (1)

TeknoHog (164938) | more than 7 years ago | (#19798609)

Check the forums and purchase carefully.

The purchasing part is hard to do when the same model comes with a different chipset each day, depending on constellations and sunspot activity.

Re:question on the wireless (2, Informative)

vtcodger (957785) | more than 7 years ago | (#19798643)

*** Anyways, I was thinking of adding one of these USB wireless accessories.. could anybody here recommend one that has a good track record of working in linux ?***

I'd be careful about anything with a Broadcom chip. There is a Broadcom driver for Linux, but it doesn't always work. The alternative is ndiswrapper which can somehow make a Windows driver work under Linux. My experience was that setting up ndiswrapper was not much fun. Not knocking ndiswrapper -- I'm utterly astounded that it works at all

GPL v3 (-1, Troll)

Anonymous Coward | more than 7 years ago | (#19797881)

This new Linux release is licensaed under GPL v3, which means
(i) you can't use it on proprietary hardware in case users have difficulty applying versions of your software that have security turned off and
(b) if you run a web server, you have to release all software on that server under GPLv3 as well as any databases etc

Re:GPL v3 (-1, Troll)

Anonymous Coward | more than 7 years ago | (#19797901)

Dude people like you just whine and post pathetic and lousy comments for false propaganda.

I bet you work for Microsoft or Sun Microsystems i guess.

Idiotic newbie junk when can't spell what a kernel is, bullshit.

----- parent is a troll ------ (-1, Troll)

Anonymous Coward | more than 7 years ago | (#19797921)

Please ignore the parent comment. It is a spelling troll with personal attacks. Mod down please.

YOU are the troll (2, Informative)

Aldric (642394) | more than 7 years ago | (#19797969)

Linus has repeatedly stated that his code will not be converted to GPLv3. You are either grossly misinformed, or on someone's payroll. If so, they are not getting their money's worth.

User "Aldric" is a cyber-vandal (-1, Troll)

Anonymous Coward | more than 7 years ago | (#19798049)

The information in my comment came directly from the Free Software Foundation (http://www.fsf.org/)

The comment by user Aldric is a troll. If you read Aldric's posting history you will see that he supports spam and virus writing, as well as posting troll comments to Slashdot.

Please mod parent down.

Re:GPL v3 (2, Informative)

derrida (918536) | more than 7 years ago | (#19797911)

I think this is just not true (yet). I haven't read anything in the changelogs.

Re:GPL v3 (0)

Anonymous Coward | more than 7 years ago | (#19797949)

Mod parent down! Nonsense generator would do a better job.

Re:GPL v3 (0)

Anonymous Coward | more than 7 years ago | (#19797977)

No, it's all true. See the Free Software Foundation website (http://www.fsf.org/) for more info. Grandparent was *not* randomly generated. Parent is flamebait. Please mod down.

Re:GPL v3 (5, Funny)

Anonymous Coward | more than 7 years ago | (#19798063)

Some other possibly unnoticed effects of the GPLv3 include:
- You can't use a CPU of the same manufacturer that has previously executed GPLv3 code in the same room as a computer running a Microsoft operating system. If you have exhausted all the alternatives and you still need to run your GPLv3-infected hardware in the same room, you can negate this by drawing a chalk circle around the machines running the MS software and sprinkling a ground-up printed copy of the GPLv3 over and around them. This is all standard as per Section 5.
- In the case the Richard Stallman's or any of his buddies' computer blows up (for any reason - read the license for full details), he's allowed to walk into your house and take your computer right off your desk and keep it, even if it has never run GPLv3 code!
- If left unattended, disks containing copies of the GPLv3 can become corrupted and mutate into GPVv3 (General Public Virus version 3), which will assimilate all carbon and silicon-based matter with in a 3 mile radius into a demonic, electronic, GPLv3 spreading zombie ox (or it might be a buffalo - that part is unclear).

This is why we should all boycott GPLv3. It is just too evil and virusy.

Re:GPL v3 (0)

Anonymous Coward | more than 7 years ago | (#19798175)

Good lord! Perhaps if the major media conglomerates cooperate with Microsoft and SCO, they can create a way to save us from this menace!

Wow; Informative? (2, Insightful)

WindBourne (631190) | more than 7 years ago | (#19798089)

The fact that you were modded up informative really shows that somebody is out here doing a a REAL FUD jobber. Few here, would say that if the kernel did switch to GPL3, that it would not even have a mention in the posting. That means that the modders are deliberate, not just ignorant. Considering that they are modding, shows that most of the time, they do not step off the deep end. That pretty much means that several ppl (30% informative), are most likely on a payroll.

R:Wow; ===parent is troll=== (0, Insightful)

Anonymous Coward | more than 7 years ago | (#19798563)

If you hate the Slashdot moderation system so much, why post comments here?

Mod parent down please

SLUB much better than slab (5, Funny)

Anonymous Coward | more than 7 years ago | (#19797891)

Great improvement! SLUB is obviously better than slab, since it's all uppercase. I get a lot of emails these days using uppercase to distinguish their importance. I think it's a good thing the linux community is catching on to this IT trend.

Re:SLUB much better than slab (1)

smitty_one_each (243267) | more than 7 years ago | (#19798367)

Some Lamers Upbraid BLUS
Savvy Llamas Understand Better.
Should Linus Use Buckshot?

Anybody (3, Interesting)

Jaaay (1124197) | more than 7 years ago | (#19797927)

have any information on how good the new wireless stack is? That's what I'm most interested in.

Re:Anybody (1)

ThatSandersKid (1068182) | more than 7 years ago | (#19797971)

Still probably better than the "messy piles" you get with Windows.

Re:Anybody (1)

Erwos (553607) | more than 7 years ago | (#19798117)

I have similar questions about what happened with the Firewire stack. I run a large number of 1394 drives, and I've always suspected the performance I was getting from them was rather sub-par, even when using the good TI chipets for the controllers.

If anyone could shine a little light on this, I'd be quite pleased.

Re:Anybody (3, Informative)

b1ufox (987621) | more than 7 years ago | (#19798651)

Current firewire stack is way too small in size as compared to old firewire stack.

Second now there are less threads in the firewire subsystem, which is indeed good because kernel threads are really really a very stupid idea.

Last but not the least i have used TI firewire chipset with Basler IEE1394 cameras under Linux and trust me they knock teeth out of Windows Firewire stack.It was good and performed good even with two cameras working in real time image inspections.

I suspect the current stack is going to work atleast similar if not better, though i ll bet on it being better.This is a good sign also, as there is no point in patching things but point is in writing the whole messy thing again.And here we are.... hey wait TTY layer ...any takers? please :-)

But is disk IO fixed on amd64? (2, Informative)

Anonymous Coward | more than 7 years ago | (#19797955)

For anyone in the dark, disk IO has been broken sometime after 2.6.17 on amd64.
I thought I was going crazy, being on 2.6.18 and discovering that any disk activity slows down the whole system, let alone accesses to any other disk.

Then I found a 19-page thread on the gentoo forums that says I'm not alone and it's not unique to a particular chipset:
http://forums.gentoo.org/viewtopic-t-482731-start- 450.html [gentoo.org]
(with evidence that the deadline scheduler may alleviate _some_ of the problem but not the root cause)

And more importantly the kernel bug report here:
http://bugzilla.kernel.org/show_bug.cgi?id=7372 [kernel.org]

So I'm happy people aren't ignoring the problem. ...Or should I be worried that something so utterly fundamental has been lost in the shuffle across so many kernels in the past year? Amid all the eagerness to add new features since then (virtualization for example, and now complete rewrites of firewire?!?!).

Why can't we have a 2.7 kernel for this stuff?

Headline does not match the story (3, Insightful)

dbIII (701233) | more than 7 years ago | (#19798243)

Follow the links above if you really want to see how the above poster is misrepresenting things to embrace a much larger picture - it's clear whoever modded them up did not.

Specific complaints should be stated as such instead of rubbish about it all being broken. The Gentoo thread quoted above is about people discovering that writing to optical drives is horribly slow and puts a lot of load on the CPU in comparison to dealing with hard disks - looking up ATAPI may have been a good move at that point instead of a lot of speculation.

Re:Headline does not match the story (2, Informative)

Anonymous Coward | more than 7 years ago | (#19798305)

Dude, you haven't read the links have you?

http://forums.gentoo.org/viewtopic-t-482731-start- 450.html [gentoo.org]
"... And of course all along I've been experiencing the slowdowns with the SATA (now back to IDE) disk access mentioned at the beginning of this thread."

http://bugzilla.kernel.org/show_bug.cgi?id=7372 [kernel.org]
"... The only thing related to libata I can think of is NCQ interacting badly with io scheduler..."
"...Yes, and this means that the problem is getting worse with TCQ/NCQ enabled, but
it is not the root cause."

This issue really is about disk IO performance in general, not specifically CD burning! Please don't make light of what is a very serious problem. It was at a point today where I had a hard time even starting "top" today during some DV video playback. Unacceptable.

Re:Headline does not match the story (2, Informative)

greg1104 (461138) | more than 7 years ago | (#19798599)

It would be helpful were you to actually read all of the attached links completely instead of seeing some bogus reports in the Gentoo area and dismissing the whole thing based on that subset.

I'd suggest http://bugzilla.kernel.org/show_bug.cgi?id=7372#c1 08 [kernel.org] and http://bugzilla.kernel.org/show_bug.cgi?id=7372#c1 12 [kernel.org] as the best summary of the kind of problem people are running into. There are no optical devices involved.

Re:Headline does not match the story (1)

swarsron (612788) | more than 7 years ago | (#19798617)

>The Gentoo thread quoted above is about people discovering that writing to optical drives is horribly slow and puts a lot of load on the CPU in comparison to dealing with hard disks

First sentence of the thread:
"Has anyone noticed a slowness or unresponiveness during disk access on a NForce4 Ultra system with a serial ata disk attached to it?"

So no, no optical drives and i have the same problem with my nforce 4/AMD 64 SATA setup here.

Re:But is disk IO fixed on amd64? (1)

Woy (606550) | more than 7 years ago | (#19798327)

Furthermore, i believe this unbelievable bug is spilling into many reports of "slowdowns" in other apps because nobody expects this in the kernel.

Re:But is disk IO fixed on amd64? (2, Informative)

cerberusss (660701) | more than 7 years ago | (#19798353)

Why can't we have a 2.7 kernel for this stuff?
So, why the trolling at the end of an otherwise good post? I'll quote Wikipedia for the people who have been living under a rock since 2.4:

The development model for Linux 2.6 was a significant change from the development model for Linux 2.5. Previously there was a stable branch (2.4) where only relatively minor and safe changes were merged, and an unstable branch (2.5), where bigger changes and cleanups were allowed. This meant that users would always have a well-tested 2.4 version with the latest security and bug fixes to use, though they would have to wait for the features which went into the 2.5 branch. The 2.5 branch was then eventually declared stable and renamed to 2.6. But instead of opening an unstable 2.7 branch, the kernel developers elected to continue putting major changes into the 2.6 "stable" branch. This had the desirable effect of not having to maintain an old stable branch, making new features quickly available, and getting more testing of the latest code.

However, the new 2.6 development model also meant that there was no stable branch for people just wanting security and bug fixes, and not needing the latest features. Fixes were only put into the latest version, so if a user wanted a version with all known bugs fixed they would also get all the latest features, which had not been well tested, and risked breaking things which had previously worked. A partial fix for this was the previously mentioned fourth version number digit (y in 2.6.x.y), which are series of point releases created by the stable team (Greg Kroah-Hartman, Chris Wright, maybe others). The stable team only released updates for the most recent kernel however, so this did not solve the problem of the missing stable kernel series. Linux distribution vendors, such as Red Hat and Debian, maintain the kernels which ship with their releases, so a solution for some people is to just follow a vendor kernel.

As a response to the lack of a stable kernel tree where people could coordinate the collection of bugfixes, in December of 2005 Adrian Bunk announced that he would keep releasing 2.6.16.y kernels when the stable team moved on to 2.6.17 [2]. He also plans to include driver updates, making the maintenance of the 2.6.16 series very similar to the old rules for maintenance of a stable series such as 2.4 [3].

Re:But is disk IO fixed on amd64? (0)

Anonymous Coward | more than 7 years ago | (#19798439)

Wrt the 2.7: I assume that you mean the unstable branch (like 2.3). That numbering system is not used anymore. Now, we have stable releases on all 2.6.x and the experimentation happens between 2.6.x and 2.6.(x+1).rc1 releases. The .rcN are after the feature freeze, where the stabilization happens.

Linus is doubtful whether there will ever be a 2.7.

(Acording to Andrew Morton anyway, http://video.google.com/videoplay?docid=1742374580 386548257 [google.com] )

Re:But is disk IO fixed on amd64? (0)

Anonymous Coward | more than 7 years ago | (#19798635)

It's not just AMD, I see the same on Intel. It's been bugging me for ages, and I'd never been able to source. Although taring a large dir will trigger it on demand.

Re:But is disk IO fixed on amd64? (1)

wild_berry (448019) | more than 7 years ago | (#19798811)

I suspect libATA is the problem. Are you using the NF4 or do you also have an SIL3114? And which are supported by the newer libATA IDE mechanism? Check here: http://kerneltrap.org/node/11695 [kerneltrap.org]

Welcome to slashdot (1)

sharperguy (1065162) | more than 7 years ago | (#19797983)

The best site out there for only letting you see a small portion of news on other websites, because the site goes down as soon as anything is posted about it.

Re:Welcome to slashdot (1)

Threni (635302) | more than 7 years ago | (#19798653)

> The best site out there for only letting you see a small portion of news on other websites, because the site goes down as soon as
> anything is posted about it.

Clue for the new/clueless - check out the FAQ, under "Slashdot effect".

n00b (1, Insightful)

ddvlad (862846) | more than 7 years ago | (#19798093)

I don't understand 70% of the changes listed and don't care about/don't use the rest of them. I know, I know... I must be new here. *sigh*

Re:n00b (3, Insightful)

Anonymous Coward | more than 7 years ago | (#19798193)

I don't understand 70% of the changes listed and don't care about/don't use the rest of them. I know, I know... I must be new here. *sigh*

Not sure why that is modded Insightful and just above that is another user asking which usb device would be best to buy for a linux box, but that is modded "off-topic." I remember when slashdot was about news for geeks and sharing information about geeky things for linux/bsd/etc.. Now it seems like its just about modding up snarky comments and crap articles about george bush. Sad turn its taken over the last few years.

Re:n00b (4, Funny)

fbjon (692006) | more than 7 years ago | (#19798425)

Slashdot has always been turning for the worse. In fact, it never was any better in the first place.

Re:n00b (1)

niceone (992278) | more than 7 years ago | (#19798301)

You just made me realise that I don't even know what kernel I'm running. I think I should just delete myself right now.

(turns out it is only 2.6.17)

Goto considered harmful? (1)

random0xff (1062770) | more than 7 years ago | (#19798123)

So I have never ever checked source code from Linux, and I don't know C or C++, but I decided to look at some changes. The first code I see has a goto in it. I always thought goto was considered harmful?

http://git.kernel.org/?p=linux/kernel/git/torvalds /linux-2.6.git;a=blobdiff;f=fs/utimes.c;h=b3c88952 465fa28cce7e0bb213fceaf59873fdf9;hp=480f7c8c29da13 ee10941f5cf5e560faffbde0a6;hb=1e5de2837c166535f9bb 4232bfe97ea1f9fc7a1c;hpb=4e99325b462ba180757685826 21af74a6b79d2a5 [kernel.org]

Re:Goto considered harmful? (1)

mrjb (547783) | more than 7 years ago | (#19798261)

Off topic, but the point of not using goto is that program structure may suffer because of it (if you've read mr. Dijkstra's paper you would know this- the result was the whole 'structured programming' movement). As long as one is careful about program structure, however, using goto is no problem.

To beginning and average programmers, 'do not use goto' is the best advice to avoid problems.

But kernel hackers are hardly beginning or average programmers. They know very well when they can use goto without problems, and when to avoid it. When used properly, goto will result in better performing, easier to maintain, more elegant, easier to read code.

Re:Goto considered harmful? (1)

Don_dumb (927108) | more than 7 years ago | (#19798311)

Whoops, forgot to delete that line of code

Re:Goto considered harmful? (2, Informative)

Cyberax (705495) | more than 7 years ago | (#19798363)

See http://kerneltrap.org/node/553/2131 [kerneltrap.org] for explanation. In short, Linus has good reasons to use goto.

Re:Goto considered harmful? (2, Insightful)

vadim_t (324782) | more than 7 years ago | (#19798417)

IMO, goto has been demonized a bit too much.

Yeah, too much of it results in spaghetti code.

But used well, it can compensate for the lack of some things in C. For example, exiting nested loops. In Perl you can say "last NAME", where NAME is the name you gave to the loop, and exit from the outer loop directly.

In C, if you avoid goto what results is a check in every loop to determine whether the inner loop decided that we've got to bail out. This is much uglier than just using goto in the first place, and more error prone too.

Using goto is also handy for error handling: When you're allocating memory, goto allows jumping to the right point in the cleanup process, instead of duplicating bits of code everywhere.

It's my understanding that in kernel programming goto also has advantages in terms of speed over other alternatives.

That's not to say we should use everywhere. But IMO, what to use should be decided on the basis of what is the cleanest and less error prone option -- If goto results in cleaner code, then use it, if it doesn't then don't.

Re:Goto considered harmful? (1)

Ruie (30480) | more than 7 years ago | (#19798641)

The first code I see has a goto in it. I always thought goto was considered harmful?

In a nutshell, yes. But there is an important exception - goto's are ok when you jump down in the code (similar to a break in the loop), usually to a piece that frees allocated storage and exits function. In the code you cite, dput_and_out commits information and exits the function. In a way it is kinda a replacement for try {} catch {}, but with multiple try {} clauses.

Linux 3.0.0 (4, Interesting)

Colin Smith (2679) | more than 7 years ago | (#19798127)

Ok. You have a major release, it's permission to break all backwards compatibility, to completely change the face of computing.

Given the hardware around. What features should Linux 3.0.0 have?

 

Re:Linux 3.0.0 (0, Interesting)

Anonymous Coward | more than 7 years ago | (#19798199)

Ha ha ha. Those days are over, baby. Linux is now about legacy and keeping the corporate customers happy. You'll have to wait till the next wonderboy with a funny name dreams up a new, groundbreaking OS. Actually, I'm not sure that there was anything groundbreaking about Linux as an OS, but I suppose that's beside the point, or is it?

Re:Linux 3.0.0 (5, Funny)

backwardMechanic (959818) | more than 7 years ago | (#19798241)

iPhone support?

Re:Linux 3.0.0 (1)

smitty_one_each (243267) | more than 7 years ago | (#19798385)

Subsequent to your port, sure.

Re:Linux 3.0.0 (2, Interesting)

MichaelSmith (789609) | more than 7 years ago | (#19798255)

Given the hardware around. What features should Linux 3.0.0 have?
  • The ability to scale from supercomputers, mainframes to handhelds, without recompilation
  • Transparent clustering. Run this process somewhere else with as much or as little user control is a required
  • Fine grained security. Maybe something which lets you build a userland which can't be exploited in any way shape or form
  • Built in support for virtual machines. Something like java in the kernel
  • Better APIs for kernel modules. Being able to run some modules in a real sandbox

Re:Linux 3.0.0 (2, Interesting)

LuckyStarr (12445) | more than 7 years ago | (#19798273)

Easy. I'd like it to have these features [wikipedia.org] of course.

Though they gradually sneak into Linux anyway. So no big deal.

Re:Linux 3.0.0 (2)

KiloByte (825081) | more than 7 years ago | (#19798285)

Here [lkml.org] you go.

It's going to be a microkernel using a special message-passing version of Visual Basic.

Re:Linux 3.0.0 (1)

mrogers (85392) | more than 7 years ago | (#19798295)

Subusers: ordinary users should be able to create 'subusers' with subsets of their privileges. That would make it easy for ordinary users to run applications in sandboxes.

For example, I should be able to create a www subuser that has access to my bookmarks and cache, but can only access other parts of the filesystem when I explicitly authorise it. (Authorisation can be seamless: make the file selection dialog into a separate setuid process that runs with my full privileges.)

What kernel changes are needed? The UID field needs to be split into two parts (user ID and subuser ID), and any operation that's allowed for a subuser must also be allowed for that subuser's owner (same user ID, subuser ID == 0). The C library will need to mask out the subuser ID for things like getpwuid. And that's about it. Extra security for users who want it, no extra hassle for users who don't, and no extra hassle for administrators.

Re:Linux 3.0.0 (1)

fbjon (692006) | more than 7 years ago | (#19798451)

Subusers: ordinary users should be able to create 'subusers' with subsets of their privileges. That would make it easy for ordinary users to run applications in sandboxes.
This sounds great, a hierarchy of users instead of a flat-file society. It couldn't even be that difficult to implement, I would guess?

no zfs. no gpl 3 (0)

Anonymous Coward | more than 7 years ago | (#19798187)

lame.

Re:no zfs. no gpl 3 (1)

KoldKompress (1034414) | more than 7 years ago | (#19798527)

Linux has been crafted from so many hands, some of them now dead, GPL3 looks highly unlikely for Linux. That and Linus' dislike of the GPL3.

Stop posting these (-1)

Anonymous Coward | more than 7 years ago | (#19798229)

Don't allow the Linux kernel releases to reach the front page anymore. There was once a time when they were interesting as people were actually building those instantly. Nowadays people just wait for the next release of their distro, or allow the packet manager to fetch and install the new one properly automatically. This sort of "news" is valuable anymore to only some 0.001% of the Linux users.

Furthermore, none of the developments is really remarkable.

New wireless stack? Firewire stack? WTF? (1, Insightful)

brunes69 (86786) | more than 7 years ago | (#19798239)

Whatever happened to the releases being STABLE??

Am I the only one who cringes when someone says they have released a totally new wireless stack in a point release? Does everyone forget the VM switch fiasco already?

I really really regret the switchover to this whole new "accelerated" kernel dev. phase. Since this is just a point release, but has a totally new wireless stack, how do I know that my next OS update won't just break my whole networking setup? Argh.

Re:New wireless stack? Firewire stack? WTF? (1, Interesting)

Viol8 (599362) | more than 7 years ago | (#19798283)

Well said. Its about damn time that they spun off 2.7 and started to fix all the bugs in 2.6. This whole 2.6 series has been one horrible mess after another with new features shoe horned in or current ones radically updated with no thought to people using 2.6 on production systems.

Re:New wireless stack? Firewire stack? WTF? (2, Informative)

smitty_one_each (243267) | more than 7 years ago | (#19798411)

Your arguably insightful post was kinda flattend in advance by GKH at OLS:
http://www.linux.com/feature/115767 [linux.com]

Re:New wireless stack? Firewire stack? WTF? (1)

shani (1674) | more than 7 years ago | (#19798465)

Run 2.6.16 [kerneltrap.org] and quit complaining.

Or, just use whatever your favorite distribution publishes for you.

Re:New wireless stack? Firewire stack? WTF? (1)

oliverthered (187439) | more than 7 years ago | (#19798743)

now all we need is hardware vendors to notice this and start releasing drivers for the 2.6.16 kernel knowing that the api/abi isn't going to change all the time

Re:New wireless stack? Firewire stack? WTF? (1)

blowdart (31458) | more than 7 years ago | (#19798557)

Whatever happened to the releases being STABLE??

Come on, in order to win the desktop Linux needs to be more like windows. More frequent service packs, errr, kernel upgrades will help.

Crashing soon a kernel near you... (5, Funny)

backwardMechanic (959818) | more than 7 years ago | (#19798263)

To quote from the bottom of the page: [The mm-tree] can crash your machine, eat your data (unlikely but not impossible) or kidnap your family (just because it has never happened it doesn't mean you're safe)

I notice the patches being tested include Reiser 4...suddenly the above warning appears a bit more sinister.

If there isn't going to be a 3.0 release... (0, Offtopic)

smitty_one_each (243267) | more than 7 years ago | (#19798467)

What is the point of retaining the 2.6?
Why not just call the thing "22"? This has the advantage of putting the kernel in the same version neighborhood as GNU/Emacs.
Oh, wait...being too close to GNU/Emacs's version number might bring development to a crawl.
Never mind.

TCP Illinois congestion control. (1)

Zombie Ryushu (803103) | more than 7 years ago | (#19798537)

This is an implementation of TCP Illinois invented by Shao Liu at University of Illinois. It is a another variant of Reno which adapts the alpha and beta parameters based on RTT. The basic idea is to increase window less rapidly as delay approaches the maximum.

Illinois Congestion control is helpful with network games as that tends to spike my connection.

2.7.x kernell? (0)

Oxide (92607) | more than 7 years ago | (#19798575)

Are we gonna ever have a 2.7.xx developmental branch? how long are we going to keep adding features and breaking things in the stable branch? why doesn't Linus hand over the 2.6 to another maintainer like he did for 2.4 and begin a developmental branch to try out new stuff?
Load More Comments
Slashdot Login

Need an Account?

Forgot your password?