Core 2 Duo mobos and Linux

xtknight

Elite Member
Oct 15, 2004
12,974
0
71
Lots of Linux distros have issues with the JMicron PATA chip and Intel ICH8 SATA chip (apparently the ISA bridge chip as well) on many C2D-compatible mobos. Some get freezing even though they get past the installation.

If you've successfully been using a C2D CPU with Linux, please post your specs (mobo, IDE/SATA controllers, SATA mode [ahci or pata]).

For me, none of the Ubuntus (Dapper or Edgy) worked properly. One couldn't detect the JMicron chip and one couldn't detect either. The ethernet worked with neither. The Ubuntu Feisty LiveCD actually works great, but the installer has serious bugs in it (which is no surprise given Feisty's current state).

OpenSuse 10.2 worked without issue on my system (other than the fact my 7800GT still gets corrupted graphics, but that is an easy fix), under both PATA emulation and AHCI mode.

My specs:

Gigabyte GA-965P-DS3 [ICH8-ahci mode, JMicron-ide mode]
Intel Core 2 Duo E6300

(SATA) Maxtor DM10 250GB--->ICH8 (AHCI mode)
(SATA) WD Caviar 250GB--->ICH8 (AHCI mode)
(PATA) Toshiba-Samsung DVD burner--->JMicron ("Gigabyte SATA2") (IDE mode)
(PATA) HP DVD burner--->JMicron ("Gigabyte SATA2") (IDE mode)

Some people have gotten by by disabling local APIC and ACPI, but it's my understanding that these are needed for multicore function. Whatever the case, it didn't work for me, and neither did the "all-generic-ide irqpoll" kernel parameters.
 

xtknight

Elite Member
Oct 15, 2004
12,974
0
71
I got a modified version of Debian Sarge to install without issue (it is just Sarge with a new kernel).

sarge-custom-1023.iso here: http://kmuto.jp/debian/d-i/

I'm working on modifying the Ubuntu Edgy CD so I can get it to install.

A BIOS update..hmm..what would that do?
 

drag

Elite Member
Jul 4, 2002
8,708
0
0
I saw mentioned several places about there being a bug in the intel-provided bios that goobered Linux up some. Several motherboard makers have released updates that fixed that issue.

But I am not sure what the issue actually was or what the update accomplishes.
 

xtknight

Elite Member
Oct 15, 2004
12,974
0
71
Well, I haven't had much luck with modifying the Ubuntu LiveCD/textmode install ISOs. That was harder than I thought. I copied the Feisty installer kernel into the Edgy one and it gets so far but then reports "kernel: not found, Intel PCIC ISA bridge". That actually sounds like the message I got when I tried the Feisty alternate text-mode install. But I was testing my modified ISO in VMware so it must affect everything.

The Feisty Fawn LiveCD actually boots fine into the desktop (well, it freezes on startup 1/5 of the time). It looks like the installer (ubiquity) is broken, at least for me. It reports something to the extent of "couldn't get active partition". Is there any way to copy a LiveCD installation to the hard disk without using their installer? I would really like to get Ubuntu on here somehow, and I know it works because I booted the Ubuntu Linux (Edgy) off my old HD and it worked fine on this machine. Then I decided to wipe it so I could install fresh, and ever since then I have had little luck installing Ubuntu on this machine.

I'll have to see if Edgy supports ICH8, but IIRC it didn't support my JMicron controller so it couldn't install off the CD. I'll have to figure out how to get a netinst image of Ubuntu onto a floppy or USB key.

Maybe updating my BIOS will allow the "all-generic-ide irqpoll" options to work like they do for most others. It wouldn't fix the fact that ICH8 and JMicron support is non-existent in the Dapper/Edgy install kernels, though. I did read something about the IRQ routing tables being screwed up in some BIOSes, so maybe that's what you're speaking of. Have any links to where this is discussed?

What continually puzzles me is how Windows XP reads my CD/DVD drives on the JMicron controller just fine without any extra drivers, and XP is over 5 years old. ICH8 support was no problem once I told the BIOS to emulate IDE mode. What's going on there?
 

stars

Golden Member
Feb 27, 2002
1,068
0
0
I had the same problem with Feisty Fawn. Its a known and documented bug. So atleast it will most likely be fixed before the final release in April. You could look at the changelogs at kernel.org and then go to distrowatch.com and find a distro with the default kernel youre needing.
 

xtknight

Elite Member
Oct 15, 2004
12,974
0
71
Well this JMicron adapter or its drivers are a piece of ******. I get random messages and freezes like this:

[ 211.655845] hde: timeout waiting for DMA
[ 216.851704] hde: status timeout: status=0xd0 { Busy }
[ 216.851710] ide: failed opcode was: unknown
[ 216.851741] hde: drive not ready for command
[ 216.902180] hde: ATAPI reset complete

It's just as if random faulty data was flowing through the controller every 5 minutes when I don't even have a CD in the drives. Then ten minutes later there's no messages or freezes at all and everything unmounts/mounts fine. It's so sporadic. I did remove 'pata_jmicron' and 'ata_generic' from my kernel, so maybe that helped something. Instead it should be using libata.

I'm going to wait a couple days and see if I can find any more info on how to get JMicron working properly under Linux. I'm ready to just buy another controller. Does anyone have a recommendation for a good, reliable, fast, name-brand, fully Linux-compatible IDE controller?

I get this plenty of times too: [ 884.154322] hdf: cdrom_pc_intr: The drive appears confused (ireason = 0x01). Trying to recover by ending request.

It also does not lock my drives when they're mounted.

More errors from doing hdparm -Tt:

OK, these were just from being in PIO mode. hdparm -d1 put them in DMA and fixed the issue.
 

MintBoy

Senior member
Oct 10, 1999
328
0
0
So far one successful and one unsuccessful. Here are the details:

--== #1 ==--

SUCCESSFUL

CPU = e6300 1.3v@443x7
Mobo = Biostar Tforce P965PT (non deluxe)
HD = SATA WD Raptor connected to ICH8

This setup works great with Slackware 11 (my distro of choice). The PATA controller is a Via VT6410 which has had support in Linux for quite a while. To install the OS you must boot the test26.s kernel in order for SATA drives attached to the ICH8 controller to be detected. Any HD's detected will be /dev/sdX. Format your / (root) and /boot (if you created one) partitions as ext2 because iirc the 2.6.18 kernel doesn't have ext3 support out of the box (could be very wrong on that, perhaps my install was mangled somewhere along the line). Install proceeds normally, install the 2.4.33 kernel even though it doesn't support ICH8. You'll understand why later in the post. Select packages to install and proceed all the way until it asks you to select a kernel to use. Instruct it to use the default kernel that was installed in the package selection section. Don't bother creating a boot disk. Write lilo to wherever you like (MBR for this setup).

**** NOTE**** Unless the DVD version of Slackware 11 is used the /testing directory on the install discs may be on a disc that is not in your CD/DVD drive. Unmount the cd with 'umount /var/log/mount', eject the disc (eject /dev/hdX), then remount using 'mount -t iso9660 /dev/hdX /var/log/mount. ****NOTE****

Once installation is completed do not select Exit. If you do the install disk will be unmounted from /var/log/mount and ejected. You need to activate another console (CTRL + F1/F2/F3 etc.). Once in console cd to /var/log/mount/testing/packages/linux-2.6.18/. The root partition is mounted to /mnt by the installer. Install the 2.6.18 packages using installpkg. YOU MUST USE THE -root SWITCH IN ORDER TO SPECIFY AN ALTERNATE ROOT DIRECTORY PATH. For example, type the following: installpkg -root /mnt kernel-generic-2.6.18.tgz (package name is probably actually different). Make sure you install the modules and headers as well. If you want the source that's your call, but 2.6.19 from ftp.kernel.org works great with this board.

Once the 2.6.18 packages have been installed LILO must be rerun. Type in the following to fix that:

chroot /mnt
cd /boot
rm -rf vmlinuz
ln -s vmlinuz-generic-2.6.18 vmlinuz
rm -rf System.map
ln -s System.map-generic-2.6.18 System.map
rm -rf config
ln -s config-generic-2.6.18 config
lilo

Go back to the first console (CTRL + F1), exit the installer and reboot. Slackware 11 should now boot. Two items to note. Firstly, remember that you must install the 2.4.33 kernel or lilo will not install during setup. Second, I believe the / (root) and /boot partitions must be ext2 for the initial boot. After I rebooted the first time it returned an error saying it could not mount root due to a missing ext3 module. This isn't a big deal since you can convert ext2 to ext3 after the install using: tune2fs -j /dev/sdXn. If someone can verify the lack of ability to boot ext3 after initial install, that would be great. It seems highly unlikely Pat V would leave ext3 support out of the 2.6.18 kernel/module packages. Should this be true though, just boot off of the Slackware install disc using the command 'test26.s root=/dev/sdXn noinitrd', and then compile a kernel with ext3 support.

Kernel compiles are beyond the scope of this post.

--== #2 ==--

UNSUCCESSFUL

CPU = e6300 1.3@7x444
Mobo = Gigabyte DS3
HD = SATA WD Raptor connected to ICH8

This board has been very weird with Slackware 11. First off, setting SATA Native Mode to disabled in the BIOS forces the ICH8 SATA ports on this motherboard to present hard disks as /dev/hdX devices and the test26.s kernel fails to detect any CD/DVD drives connected to the JMicron controller. Changing SATA Native to enabled fixed that and they then were detected as /dev/sdX and CD/DVD drives connected to the JMicron were then found at /dev/hde and /dev/hdf (master/slave respectively).

Installation proceeds smoothly using the same method as above with the Biostar 965PT motherboard. LILO installs without a problem. Upon reboot it always complains that it can not mount root (VFS panic). The only fixed tried so far was to boot off the install disc using 'test26.s root=/dev/sda5 noinitrd' and then compiling a 2.6.19 kernel with ICH8 and JMicron support. AHCI was compiled in as well. Both the legacy and new ICH8 and JMicron modules were compiled into the kernel. Can anyone verify if this causes conflict issues?

Even after compiling and installing a custom kernel with the proper modules compiled in, the same VFS panic, unable to mount root error appears. Honestly I haven't watched the screen very closely so it could be a simple problem of the /etc/fstab not pointing to the proper drive which leads to another strange point about this motherboard. If SATA Native Mode is DISABLED in the BIOS the ICH8 SATA 0 and 1 ports are swapped. Any device detected to port 1 is detected prior to port 0. Switching SATA Native Mode to enabled forces them to be detected in the proper order.

The other cause of the problem could be the ICH8 and/or JMicron modules must be placed into an initrd image and booted along with the kernel. Experience tells me this is only necessary for true SCSI drives attached to SCSI controllers (not SATA which although detected as /dev/sdX devices actually use the libata module). The nullification to that theory is this configuration works fine on a different Intel 965 board with ICH8 but no JMicron controller. It's very strange because the SATA disk is not connected to the JMicron SATA controller.

Given a few more hours of hacking away at this problem should present a solution. In the meantime, if anyone else has any experience with this please post your experience(s).
 

VirtualLarry

No Lifer
Aug 25, 2001
56,587
10,227
126
Originally posted by: xtknight
I'm going to wait a couple days and see if I can find any more info on how to get JMicron working properly under Linux. I'm ready to just buy another controller. Does anyone have a recommendation for a good, reliable, fast, name-brand, fully Linux-compatible IDE controller?
CMD/SI 0680, perhaps? Or a Promise Ultra100TX2, if you don't care about ATAPI device support. The 0680 appears as a standard IDE device, the Promise looks like a SCSI.

 

MintBoy

Senior member
Oct 10, 1999
328
0
0
Alright. The JMicron JMB363 controller code in the latest 2.6.19 kernels seems to work, sort of. Any HD's attached to them will not go into any UDMA modes beyond UMDA2. Trying to force UDMA5 using 'hdparm -X UDMA5 /dev/hdX' returns no error but verifying the update reports devices are still UDMA2*.

There is one big problem with all of this and Slackware-current (Slackware 11). It seems the 2.6.19.x kernels are not compatible with the binary of iptables shipped with Slackware 11. Compiling iptables from source may fix this but I have yet to try it.

This is very disappointing that the code for the JMB363 chips works in 2.6.19 but due to whatever changes were made in 2.6.19 some binaries do not work.

Hopefully this all get sorted out soon and Hopefully Pat V releases a new version of Slackware-current.

Anyone else having luck with this issue?
 

OSX

Senior member
Feb 9, 2006
662
0
0
Fedora Core 6 detects my NEC ND3550A with all-generic-ide, but the disks are not detected in IDE emulation mode. Have not tried AHCI, as that does not work with XP. Damn you, Intel!
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
This is very disappointing that the code for the JMB363 chips works in 2.6.19 but due to whatever changes were made in 2.6.19 some binaries do not work.

I don't have a JMicron controller but I do have a box running 2.6.9 and iptables works just fine, I didn't have to do anything. If you really do see some sort of userland incompatibility with 2.6.19 that's a bug and should be reported.
 

MintBoy

Senior member
Oct 10, 1999
328
0
0
The iptables issue with 2.6.19 was pretty easy to fix. Slackware 11 ships v1.3.5 which is pretty old (~10 months). Compiling iptables 1.3.7 from source fixed those issues.

The only real complaint now would be that the JMicron controller will not communicate with IDE devices at speeds greater than UDMA2. One other issue is the SKY2 driver for Marvell Yukon 8053 NIC's is still EXPERIMENTAL and I have experienced a few times where networking ceases to function. This is all with 2.6.19.1 BTW.
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
The iptables issue with 2.6.19 was pretty easy to fix. Slackware 11 ships v1.3.5 which is pretty old (~10 months). Compiling iptables 1.3.7 from source fixed those issues.

That's still not right, unless it was a 64-bit kernel -> 32-bit userland problem, I remember reading about a few of those in the past.
 

xtknight

Elite Member
Oct 15, 2004
12,974
0
71
Mint_Boy: do you check your dmesg? Have you gotta any weird error messages originating from the JMicron controller? I keep getting stuff like cdrom_intr...the drive is confused, ireason=0x01....something about SeekComplete. Every time it happens it freezes my PC. Sometimes my dmesg is full of it from the night before. Frustrating and I can't find anyone else experiencing the same thing. I doubt that the chip is damaged because it works just fine in Windows.

VirtualLarry: thanks I'll check those out though I've never heard of CMD/SI but I know Promise generally has great Linux support. Either will work with DVD burners right (read and write)?
 

MintBoy

Senior member
Oct 10, 1999
328
0
0
There are no ATAPI devices connected to the JMicron controller, only a single WD hard drive. The DVD drive used during installation was connected to a Promise Ultra133TX2 PCI controller.

Driver support for the JMicron chips is flaky. Also, the SKY2 driver for the Marvell GigE chips on the Rev. 1 DS3's is shaky as well. There are comments about the driver actually regressing in the latest 2.6.20 release candidates. Hopefully they'll fix it soon. It's been ongoing for a year now. In the meantime, a good old Realtek 8139 NIC was put back in action.
 

xtknight

Elite Member
Oct 15, 2004
12,974
0
71
Well I'm sick of this, I'm going to pick up that controller. I'll be so glad when I can just disable that JMicron chip completely in the BIOS. It's even weird in Windows: if I set it to anything other than IDE I get yellow question marks in my device manager.

sky2 on my DS3 rev 2.0 appears to be working flawlessly.
 

MintBoy

Senior member
Oct 10, 1999
328
0
0
Note that 2.6.19 introduces an mmap bug which can corrupt writes to ext3 file systems. The patch to fix this was introduced in 2.6.20-rc3 which is what I'll be installing tonight. This really only affects people who use rtorrent for downloading through bittorrent.
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
Note that 2.6.19 introduces an mmap bug which can corrupt writes to ext3 file systems. The patch to fix this was introduced in 2.6.20-rc3 which is what I'll be installing tonight. This really only affects people who use rtorrent for downloading through bittorrent.

rtorrent was the most reproducible test case but it's not the only one, infact one of the reporters was having problems with a Debian installation on ARM because apt uses mmap in a similar fashion, I just think most other people haven't noticed because you also need a decent amount of memory pressure.
 

drag

Elite Member
Jul 4, 2002
8,708
0
0
also remember that it was a latent bug that was present in previous kernels.. It wasn't introduced with 2.6.19, but changes in how 2.6.19 made it stand out more. (IIRC)

It took a lot of people a lot of time and recompiled kernels before they figured out what was happenning...