logo
Published on KernelTrap (http://kerneltrap.org)

Linux: IDE Layer Dissension

By Jeremy
Created Apr 29 2005 - 09:29

Alan Cox [interview [1]] maintained the 2.4 Linux kernel's IDE layer. Then, in August of 2003 he began a one year sabbatical [story [2]], and in early 2.5 development Bartlomiej Zolnierkiewicz took over maintainership of the IDE layer. In a recent posting to the lkml [3] Alan complained [4] about broken functionality in 2.6.12-rc3 saying, "now I come back to look at the ide layer ready for a 2.6.12 merge and its all a bit messy. The open code was clean and is now duplicated. Copies of subtly different per driver gendisk/disk layer open routines have appeared that should be shared. The default driver handling has been removed and half the options for obscure systems have been marked obsolete in some Gnome like purge of functionality that might scare small children."

Bartlomiej replied by suggesting, "maybe you should mail [the] current maintainer before spreading FUD?" pointing out that, "these patches were posted at least two times to both linux-ide and linux-kernel, they were in -mm for ages". He went on to explain, "there was a lot new stuff added when you were away (i.e. driver-model and IDE code needs to conform with it to get sane power management and sysfs support) and that a lot of other things have changed (influencing IDE)." The less than cordial exchange included Alan commenting, "I had hoped that I wouldnt have to totally fork the 2.6 IDE code in order to get back to where 2.4-ac was and get the locking working so you can't oops it via /proc", and Bartlomiej replying, "feel free to fork so you'll be wasting your time only and not mine."


From: Alan Cox [5] [email blocked]
To:  linux-ide, [email blocked]
Subject: Multiple functionality breakages in 2.6.12rc3 IDE layer
Date: 	Thu, 28 Apr 2005 16:48:05 +0100

Ages ago we added an ide_default driver to clean up all the corner cases
like spurious IRQs for a device with no matching driver (eg ide-cd and
no CD driver) as well as ioctls and file access. 

2.6.12rc removes it. Unfortunately it also means that if your only IDE
interface is one you hand configure you can no longer run Linux. It also
changes other aspects of behaviour although they don't look problematic
for most users. You can no longer
	- Control the bus state of an interface
	- Reset an interface
	- Add an interface if none exist
	- Issue raw commands
	- Get an objects bios geometry
	- Read the identify data by ioctl (its still in proc but may be stale)

without having a device specific driver loaded matching the media - and
that only works if its already detected the device correctly.

I don't have the tools at the moment to generate spurious IRQ's for
devices with no driver loaded but it does look like the code may well
then crash. From the way the changes were done it appears the current
IDE maintainers never appreciated that ide_default existed for far more
than just cleaning up ide-proc but also to handle IRQ's, opening of
empty slots, ioctls and power
management ?

The ability to specify the IDE ports on the command line as needed for
some Sony laptop installs have also become "obsolete" over time. They
still appear to work but spew a warning that the user will soon be
screwed.

Alan


From: Bartlomiej Zolnierkiewicz [email blocked] Subject: Re: Multiple functionality breakages in 2.6.12rc3 IDE layer Date: Thu, 28 Apr 2005 22:41:00 +0200 On 4/28/05, Alan Cox [email blocked] wrote: > Ages ago we added an ide_default driver to clean up all the corner cases s/clean up/hide/ > like spurious IRQs for a device with no matching driver (eg ide-cd and > no CD driver) as well as ioctls and file access. > > 2.6.12rc removes it. Unfortunately it also means that if your only IDE > interface is one you hand configure you can no longer run Linux. It also > changes other aspects of behaviour although they don't look problematic > for most users. You can no longer > - Control the bus state of an interface > - Reset an interface > - Add an interface if none exist > - Issue raw commands > - Get an objects bios geometry > - Read the identify data by ioctl (its still in proc but may be stale) Details please. > without having a device specific driver loaded matching the media - and > that only works if its already detected the device correctly. > > I don't have the tools at the moment to generate spurious IRQ's for > devices with no driver loaded but it does look like the code may well > then crash. From the way the changes were done it appears the current > IDE maintainers never appreciated that ide_default existed for far more > than just cleaning up ide-proc but also to handle IRQ's, opening of > empty slots, ioctls and power > management ? Maybe you should mail current maintainer before spreading FUD? No functionality was removed AFAIK, see the patches. I spend quite a bit of time making sure that nothing breaks up (I missed one special case but somebody already posted patch to LKML fixing it). These patches were posted at least two times to both linux-ide and linux-kernel, they were in -mm for ages - were you hiding under the rock? > The ability to specify the IDE ports on the command line as needed for > some Sony laptop installs have also become "obsolete" over time. They > still appear to work but spew a warning that the user will soon be > screwed. This was discussed few times already. Alan, seriously, what is your problem? Bartlomiej
From: Alan Cox [6] [email blocked] Subject: Re: Multiple functionality breakages in 2.6.12rc3 IDE layer Date: Thu, 28 Apr 2005 23:32:03 +0100 On Iau, 2005-04-28 at 21:41, Bartlomiej Zolnierkiewicz wrote: > On 4/28/05, Alan Cox [email blocked] wrote: > > Ages ago we added an ide_default driver to clean up all the corner cases > > s/clean up/hide/ Matter of opinion. > > for most users. You can no longer > > - Control the bus state of an interface > > - Reset an interface > > - Add an interface if none exist > > - Issue raw commands > > - Get an objects bios geometry > > - Read the identify data by ioctl (its still in proc but may be stale) > > Details please. If you need details you shouldn't be maintaining that code. Its obvious why. You've disabled open() of a device with no bound driver. > No functionality was removed AFAIK, see the patches. I spend quite > a bit of time making sure that nothing breaks up (I missed one special > case but somebody already posted patch to LKML fixing it). Build a kernel without ide-cd. Now try and issue ioctls on it. Doesn't work any more does it. > > These patches were posted at least two times to both linux-ide and > linux-kernel, they were in -mm for ages - were you hiding under the > rock? No, just doing an MBA thesis, a job, learning a second language and trying to beat sense into our politicians. Now I come back to look at the ide layer ready for a 2.6.12 merge and its all a bit messy. The open code was clean and is now duplicated. Copies of subtly different per driver gendisk/disk layer open routines have appeared that should be shared. The default driver handling has been removed and half the options for obscure systems have been marked obsolete in some Gnome like purge of functionality that might scare small children. > > The ability to specify the IDE ports on the command line as needed for > > some Sony laptop installs have also become "obsolete" over time. They > > still appear to work but spew a warning that the user will soon be > > screwed. > > This was discussed few times already. And the discussion lead to no fixes > Alan, seriously, what is your problem? The fact that the IDE layer appears to be getting worse not better, which given the starting point is a remarkable achievement. Alan
From: Bartlomiej Zolnierkiewicz [email blocked] Subject: Re: Multiple functionality breakages in 2.6.12rc3 IDE layer Date: Fri, 29 Apr 2005 01:00:06 +0200 On 4/29/05, Alan Cox [email blocked] wrote: > On Iau, 2005-04-28 at 21:41, Bartlomiej Zolnierkiewicz wrote: > > On 4/28/05, Alan Cox [email blocked] wrote: > > > Ages ago we added an ide_default driver to clean up all the corner cases > > > > s/clean up/hide/ > > Matter of opinion. No, it hided holes in the locking which is getting fixed finally. > > > for most users. You can no longer > > > - Control the bus state of an interface > > > - Reset an interface > > > - Add an interface if none exist > > > - Issue raw commands > > > - Get an objects bios geometry > > > - Read the identify data by ioctl (its still in proc but may be stale) > > > > Details please. > > If you need details you shouldn't be maintaining that code. Its obvious Give details or quit whining. > why. You've disabled open() of a device with no bound driver. Guess what open() for ide-default was doing in 2.6? return -ENXIO; and no it wasn't my change - it was the effect of fixing locking of the higher layers. > > No functionality was removed AFAIK, see the patches. I spend quite > > a bit of time making sure that nothing breaks up (I missed one special > > case but somebody already posted patch to LKML fixing it). > > Build a kernel without ide-cd. Now try and issue ioctls on it. Doesn't > work any more does it. > > > > > These patches were posted at least two times to both linux-ide and > > linux-kernel, they were in -mm for ages - were you hiding under the > > rock? > > No, just doing an MBA thesis, a job, learning a second language and > trying to beat sense into our politicians. Now I come back to look at It seems that they influenced you heavily... > the ide layer ready for a 2.6.12 merge and its all a bit messy. The open > code was clean and is now duplicated. Copies of subtly different per You must be joking. > driver gendisk/disk layer open routines have appeared that should be Each change was given rationale and detailed changelog, maybe you should get familiar with them. Also look for patch converting device drivers to sysfs (posted few times). > shared. The default driver handling has been removed and half the > options for obscure systems have been marked obsolete in some Gnome like > purge of functionality that might scare small children. > > > > The ability to specify the IDE ports on the command line as needed for > > > some Sony laptop installs have also become "obsolete" over time. They > > > still appear to work but spew a warning that the user will soon be > > > screwed. > > > > This was discussed few times already. > > And the discussion lead to no fixes So fix the real bugs and leave debugging stuff alone. > > Alan, seriously, what is your problem? > > The fact that the IDE layer appears to be getting worse not better, > which given the starting point is a remarkable achievement. Personal insults are easy, get technical facts. Bartlomiej
From: Alan Cox [7] [email blocked] Subject: Re: Multiple functionality breakages in 2.6.12rc3 IDE layer Date: Fri, 29 Apr 2005 00:43:27 +0100 On Gwe, 2005-04-29 at 00:00, Bartlomiej Zolnierkiewicz wrote: > > why. You've disabled open() of a device with no bound driver. > > Guess what open() for ide-default was doing in 2.6? > > return -ENXIO; > > and no it wasn't my change - it was the effect of fixing > locking of the higher layers. Yes so it needed fixing and without all the kref, kmalloc, unique object structure per ide driver code spew too. > > The fact that the IDE layer appears to be getting worse not better, > > which given the starting point is a remarkable achievement. > > Personal insults are easy, get technical facts. I consider that a technical fact. The last IDE code I maintained fully in 2.4 had mostly working locking, drive hotplug, open for unbound drivers, didnt oops on spurious irqs and wasn't losing all sorts of useful boot options. I had hoped that I wouldnt have to totally fork the 2.6 IDE code in order to get back to where 2.4-ac was and get the locking working so you can't oops it via /proc Alan
From: Bartlomiej Zolnierkiewicz [email blocked] Subject: Re: Multiple functionality breakages in 2.6.12rc3 IDE layer Date: Fri, 29 Apr 2005 02:23:39 +0200 On 4/29/05, Alan Cox [email blocked] wrote: > On Gwe, 2005-04-29 at 00:00, Bartlomiej Zolnierkiewicz wrote: > > > why. You've disabled open() of a device with no bound driver. > > > > Guess what open() for ide-default was doing in 2.6? > > > > return -ENXIO; > > > > and no it wasn't my change - it was the effect of fixing > > locking of the higher layers. > > Yes so it needed fixing and without all the kref, kmalloc, unique object > structure per ide driver code spew too. IDE is similar to SCSI now in this respect. Are you claiming that SCSI needs fixing too? > > > The fact that the IDE layer appears to be getting worse not better, > > > which given the starting point is a remarkable achievement. > > > > Personal insults are easy, get technical facts. > > I consider that a technical fact. The last IDE code I maintained fully > in 2.4 had mostly working locking, drive hotplug, open for unbound > drivers, didnt oops on spurious irqs and wasn't losing all sorts of > useful boot options. I had hoped that I wouldnt have to totally fork the > 2.6 IDE code in order to get back to where 2.4-ac was and get the > locking working so you can't oops it via /proc Somehow you seem to forget that I took maintaince over 2.5.5x (or 2.5.6x) and there was a lot new stuff added when you were away (i.e. driver-model and IDE code needs to conform with it to get sane power management and sysfs support) and that a lot of other things have changed (influencing IDE). Feel free to fork so you'll be wasting yours time only and not mine.



Read the full thread [8].


Source URL:
http://kerneltrap.org/node/5062