Here's a patch which adds IDE support to the Intel 82371EB southbridge.
With this patch I can boot a Linux kernel with FILO up until the login prompt. I can login and use the system, too. Feels a bit slowish, but maybe that's just because the CPU and disk are dead slow...
(Hm, there's an "Enable Ultra DMA/33" setting on the IDE controller -- should I enable that in the southbridge code, or can Linux do that and it's superfluous in the BIOS?)
Anyway, this patch also fixes random other southbridge files, and I'm adding my copyright header to some other files as they're either trivial and/or my changes are pretty much a rewrite...
There's some more stuff missing from the 82371EB (e.g. USB support), but that's for another patch...
Boot log attached.
Uwe.
Uwe Hermann wrote:
Here's a patch which adds IDE support to the Intel 82371EB southbridge.
With this patch I can boot a Linux kernel with FILO up until the login prompt. I can login and use the system, too. Feels a bit slowish, but maybe that's just because the CPU and disk are dead slow...
And perhaps also because you're using a serial console (on said dead slow system)? Still, great work!
(Hm, there's an "Enable Ultra DMA/33" setting on the IDE controller -- should I enable that in the southbridge code, or can Linux do that and it's superfluous in the BIOS?)
Couldn't hurt to enable it (except for a couple extra microseconds spent in the BIOS). Although probably best to have it as a config option. Not that I expect anyone to have any non-dma disks, but some compact flash adapters don't like dma mode, although they tell the BIOS/linux that they support it. On my little file server, debian takes about 3 minutes to boot because it tries every DMA mode before it gives up and disables it. But I can't disable dma outright, because the two hard drives do support it, and I don't want them to be deathly slow.
Anyway, this patch also fixes random other southbridge files, and I'm adding my copyright header to some other files as they're either trivial and/or my changes are pretty much a rewrite...
There's some more stuff missing from the 82371EB (e.g. USB support), but that's for another patch...
Hmm...from the code I've seen for other southbridges, namely vt8235 and i82801ca/db/dbm, most seem to have code for enabling the USB, and then have it commented out, presumably because the developer(s) discovered that it worked fine with whatever normal pci device init linuxbios does. Does linux automagically load the usb modules?
-Corey
On Wed, Nov 10, 2004 at 02:37:54AM -0500, Corey Osgood wrote:
With this patch I can boot a Linux kernel with FILO up until the login prompt. I can login and use the system, too. Feels a bit slowish, but maybe that's just because the CPU and disk are dead slow...
And perhaps also because you're using a serial console (on said dead slow system)?
Nah, I don't think so. The console is pretty fast, certain things (e.g. during boot) just seem to take way longer than they should.
My guess is that the missing IRQ table is also part of the problem.
(Hm, there's an "Enable Ultra DMA/33" setting on the IDE controller -- should I enable that in the southbridge code, or can Linux do that and it's superfluous in the BIOS?)
Couldn't hurt to enable it (except for a couple extra microseconds spent in the BIOS). Although probably best to have it as a config option.
Yeah, I'll enable it (+ add a config option) and then try to do some quick measurements whether speed improves. Even _if_ Linux itself doesn't need this setting, it might still help FILO to read the kernel image faster from disk!?
Hmm...from the code I've seen for other southbridges, namely vt8235 and i82801ca/db/dbm, most seem to have code for enabling the USB, and then have it commented out, presumably because the developer(s) discovered that it worked fine with whatever normal pci device init linuxbios does. Does linux automagically load the usb modules?
Attaching some USB device and then doing 'lsusb' didn't work so far, but that may be because of the missing IRQ table. I'll test both versions...
Oh, and the bootlog is really attached now.
Uwe.
Uwe Hermann wrote:
Here's a patch which adds IDE support to the Intel 82371EB southbridge.
With this patch I can boot a Linux kernel with FILO up until the login prompt. I can login and use the system, too. Feels a bit slowish, but maybe that's just because the CPU and disk are dead slow...
(Hm, there's an "Enable Ultra DMA/33" setting on the IDE controller -- should I enable that in the southbridge code, or can Linux do that and it's superfluous in the BIOS?)
Anyway, this patch also fixes random other southbridge files, and I'm adding my copyright header to some other files as they're either trivial and/or my changes are pretty much a rewrite...
There's some more stuff missing from the 82371EB (e.g. USB support), but that's for another patch...
Boot log attached.
Forgot before, this looks good to me:
Acked-by: Corey Osgood corey_osgood@verizon.net
Just one question though:
#define PCI_DEVICE_ID_INTEL_82371AB 0x7111 #define PCI_DEVICE_ID_INTEL_82371AB_2 0x7112 #define PCI_DEVICE_ID_INTEL_82371AB_3 0x7113 +#define PCI_DEVICE_ID_INTEL_82371AB_ISA 0x7110 +#define PCI_DEVICE_ID_INTEL_82371AB_IDE 0x7111 +#define PCI_DEVICE_ID_INTEL_82371AB_USB 0x7112 +#define PCI_DEVICE_ID_INTEL_82371AB_ACPI 0x7113 /* Same as SMB */ +#define PCI_DEVICE_ID_INTEL_82371AB_SMB 0x7113 /* Same as ACPI */
Why add these and not remove the old ones? I can already hear someone complaining about syncing up with the linux version, but I don't think v2 will ever do that again, and why should we be cursed with linux's obstrufication?
-Corey
On Tue, May 29, 2007 at 03:03:57AM -0400, Corey Osgood wrote:
Acked-by: Corey Osgood corey_osgood@verizon.net
Thanks, committed in r2703.
Just one question though:
#define PCI_DEVICE_ID_INTEL_82371AB 0x7111 #define PCI_DEVICE_ID_INTEL_82371AB_2 0x7112 #define PCI_DEVICE_ID_INTEL_82371AB_3 0x7113 +#define PCI_DEVICE_ID_INTEL_82371AB_ISA 0x7110 +#define PCI_DEVICE_ID_INTEL_82371AB_IDE 0x7111 +#define PCI_DEVICE_ID_INTEL_82371AB_USB 0x7112 +#define PCI_DEVICE_ID_INTEL_82371AB_ACPI 0x7113 /* Same as SMB */ +#define PCI_DEVICE_ID_INTEL_82371AB_SMB 0x7113 /* Same as ACPI */
Why add these and not remove the old ones? I can already hear someone complaining about syncing up with the linux version, but I don't think v2 will ever do that again, and why should we be cursed with linux's obstrufication?
Yeah, I agree, we can remove them. For v3 we already decided _not_ to use the kernel's pci_ids.h but rather maintain our own tight list of just the IDs we really need.
I think we should only use the _ISA/_IDE/etc. versions in the code, the _0/_2/etc. is pretty much useless and unreadable, IMHO.
Uwe.