Bug 437163

Summary: Anaconda loads pata_acpi too early
Product: [Fedora] Fedora Reporter: ryuhei yokokawa <ryuheixys>
Component: module-init-toolsAssignee: Jon Masters <jcm>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 8CC: alan, alex, fkooman, jcm, kernel-maint, slacker
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-01-09 07:43:30 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
dmesg output
none
dmesg output for 2.6.23.1-42.fc8 none

Description ryuhei yokokawa 2008-03-12 18:12:39 UTC
Description of problem:
The data flow from my IDE drive is excruciatingly slow since upgrading kernel to
the 2.6.24 series.  I singled into my 2.6.23 and did hdparm -tT to find that the
drive was functioning normally (buffered disk read of ~70mb/s).  When using
kernel version 2.6.24.3-12.fc8, the buffered disk read is at ~1mb/s which is
pathetic.  Also, the CPU usage is at 100% during any read/write on the IDE disk.
My other SATA disk seems to be doing fine on both kernel versions.  Details below.

Version-Release number of selected component (if applicable):
kernel 2.6.24.3-12.fc8

How reproducible:
Every time I use the  2.6.24.3-12.fc8 kernel.

Steps to Reproduce:
1.Install the newest 2.6.24 kernel
2.Reboot
3.Slow disk read/write for IDE drives
  
Actual results:
Slow disk read/write and 100% CPU usage

Expected results:
Fast disk read/write and low CPU usage

Additional info:
Here is my lsmod for the 2.6.24 kernel:
Module                  Size  Used by
autofs4                20292  2 
nf_conntrack_ipv4      11589  2 
xt_state                5953  2 
nf_conntrack           51713  2 nf_conntrack_ipv4,xt_state
xt_tcpudp               6849  4 
ipt_REJECT              7361  2 
iptable_filter          6337  1 
ip_tables              14085  1 iptable_filter
x_tables               14149  4 xt_state,xt_tcpudp,ipt_REJECT,ip_tables
cpufreq_ondemand       10317  1 
dm_mirror              21569  0 
dm_multipath           18505  0 
dm_mod                 49029  2 dm_mirror,dm_multipath
ipv6                  228357  10 
snd_ca0106             32993  3 
snd_usb_audio          79681  0 
snd_usb_lib            18241  1 snd_usb_audio
snd_rawmidi            22465  2 snd_ca0106,snd_usb_lib
snd_hwdep              10693  1 snd_usb_audio
snd_seq_dummy           6725  0 
snd_atiixp             19149  3 
snd_ac97_codec         93413  2 snd_ca0106,snd_atiixp
snd_seq_oss            31553  0 
snd_seq_midi_event      9665  1 snd_seq_oss
snd_seq                48945  5 snd_seq_dummy,snd_seq_oss,snd_seq_midi_event
snd_seq_device         10317  4 snd_rawmidi,snd_seq_dummy,snd_seq_oss,snd_seq
snd_pcm_oss            44353  0 
snd_mixer_oss          17217  3 snd_pcm_oss
firewire_ohci          18881  0 
firewire_core          36353  1 firewire_ohci
snd_pcm                70981  5
snd_ca0106,snd_usb_audio,snd_atiixp,snd_ac97_codec,snd_pcm_oss
8139cp                 21441  0 
snd_timer              21317  2 snd_seq,snd_pcm
crc_itu_t               5953  1 firewire_core
snd                    48453  23
snd_ca0106,snd_usb_audio,snd_usb_lib,snd_rawmidi,snd_hwdep,snd_seq_dummy,snd_atiixp,snd_ac97_codec,snd_seq_oss,snd_seq,snd_seq_device,snd_pcm_oss,snd_mixer_oss,snd_pcm,snd_timer
8139too                24513  0 
nvidia               7816064  24 
ac97_bus                5825  1 snd_ac97_codec
button                 10321  0 
mii                     8257  2 8139cp,8139too
soundcore               9505  3 snd
i2c_piix4              11213  0 
parport_pc             26725  0 
k8temp                  8129  0 
hwmon                   6341  1 k8temp
i2c_core               21057  2 nvidia,i2c_piix4
parport                32393  1 parport_pc
sr_mod                 17381  0 
snd_page_alloc         11593  3 snd_ca0106,snd_atiixp,snd_pcm
usb_storage            77057  0 
pcspkr                  6465  0 
floppy                 52741  0 
cdrom                  33761  1 sr_mod
sg                     32209  0 
pata_atiixp             9281  1 
pata_acpi               8641  0 
ata_generic             8773  0 
sata_sil               11593  2 
libata                128561  4 pata_atiixp,pata_acpi,ata_generic,sata_sil
sd_mod                 26689  5 
scsi_mod              123341  5 sr_mod,usb_storage,sg,libata,sd_mod
ext3                  111945  2 
jbd                    40533  1 ext3
mbcache                10049  1 ext3
uhci_hcd               23633  0 
ohci_hcd               22725  0 
ehci_hcd               32333  0 
[root@localhost xys]# /sbin/lsmod 
Module                  Size  Used by
autofs4                20292  2 
nf_conntrack_ipv4      11589  2 
xt_state                5953  2 
nf_conntrack           51713  2 nf_conntrack_ipv4,xt_state
xt_tcpudp               6849  4 
ipt_REJECT              7361  2 
iptable_filter          6337  1 
ip_tables              14085  1 iptable_filter
x_tables               14149  4 xt_state,xt_tcpudp,ipt_REJECT,ip_tables
cpufreq_ondemand       10317  1 
dm_mirror              21569  0 
dm_multipath           18505  0 
dm_mod                 49029  2 dm_mirror,dm_multipath
ipv6                  228357  10 
snd_ca0106             32993  3 
snd_usb_audio          79681  0 
snd_usb_lib            18241  1 snd_usb_audio
snd_rawmidi            22465  2 snd_ca0106,snd_usb_lib
snd_hwdep              10693  1 snd_usb_audio
snd_seq_dummy           6725  0 
snd_atiixp             19149  3 
snd_ac97_codec         93413  2 snd_ca0106,snd_atiixp
snd_seq_oss            31553  0 
snd_seq_midi_event      9665  1 snd_seq_oss
snd_seq                48945  5 snd_seq_dummy,snd_seq_oss,snd_seq_midi_event
snd_seq_device         10317  4 snd_rawmidi,snd_seq_dummy,snd_seq_oss,snd_seq
snd_pcm_oss            44353  0 
snd_mixer_oss          17217  3 snd_pcm_oss
firewire_ohci          18881  0 
firewire_core          36353  1 firewire_ohci
snd_pcm                70981  5
snd_ca0106,snd_usb_audio,snd_atiixp,snd_ac97_codec,snd_pcm_oss
8139cp                 21441  0 
snd_timer              21317  2 snd_seq,snd_pcm
crc_itu_t               5953  1 firewire_core
snd                    48453  23
snd_ca0106,snd_usb_audio,snd_usb_lib,snd_rawmidi,snd_hwdep,snd_seq_dummy,snd_atiixp,snd_ac97_codec,snd_seq_oss,snd_seq,snd_seq_device,snd_pcm_oss,snd_mixer_oss,snd_pcm,snd_timer
8139too                24513  0 
nvidia               7816064  24 
ac97_bus                5825  1 snd_ac97_codec
button                 10321  0 
mii                     8257  2 8139cp,8139too
soundcore               9505  3 snd
i2c_piix4              11213  0 
parport_pc             26725  0 
k8temp                  8129  0 
hwmon                   6341  1 k8temp
i2c_core               21057  2 nvidia,i2c_piix4
parport                32393  1 parport_pc
sr_mod                 17381  0 
snd_page_alloc         11593  3 snd_ca0106,snd_atiixp,snd_pcm
usb_storage            77057  0 
pcspkr                  6465  0 
floppy                 52741  0 
cdrom                  33761  1 sr_mod
sg                     32209  0 
pata_atiixp             9281  1 
pata_acpi               8641  0 
ata_generic             8773  0 
sata_sil               11593  2 
libata                128561  4 pata_atiixp,pata_acpi,ata_generic,sata_sil
sd_mod                 26689  5 
scsi_mod              123341  5 sr_mod,usb_storage,sg,libata,sd_mod
ext3                  111945  2 
jbd                    40533  1 ext3
mbcache                10049  1 ext3
uhci_hcd               23633  0 
ohci_hcd               22725  0 
ehci_hcd               32333  0


Here is my hdparm -tT for 2.6.24 kernel:
/dev/sdb:
 Timing cached reads:   1252 MB in  2.00 seconds = 625.80 MB/sec
 Timing buffered disk reads:    4 MB in  3.83 seconds =   1.04 MB/sec

Please comment and let me know if additional information is required.

Comment 1 ryuhei yokokawa 2008-03-12 18:14:14 UTC
Sorry, I've accidentally added the lsmod twice on my post.

Comment 2 Dave Jones 2008-03-12 18:45:11 UTC
can you attach the dmesg output please?

Comment 3 ryuhei yokokawa 2008-03-12 18:52:09 UTC
Created attachment 297824 [details]
dmesg output

Comment 4 ryuhei yokokawa 2008-03-12 20:00:02 UTC
I forgot to add the Hardware info:

My motherboard is: MSI RS482M-IL 754 ATI Radeon Xpress 200 Micro ATX AMD Motherboard
Here is more info if you need:
http://www.newegg.com/product/product.aspx?Item=N82E16813130526R


IDE drive: (the troubled one)
hdparm -i /dev/sdb

/dev/sdb:

 Model=Maxtor 6L300R0                          , FwRev=BAH41G10,
SerialNo=L6174YYH            
 Config={ Fixed }
 RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=57
 BuffType=DualPortCache, BuffSize=16384kB, MaxMultSect=16, MultSect=?16?
 CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=268435455
 IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120}
 PIO modes:  pio0 pio1 pio2 pio3 pio4 
 DMA modes:  mdma0 mdma1 mdma2 
 UDMA modes: udma0 udma1 udma2 udma3 udma4 udma5 *udma6 
 AdvancedPM=yes: disabled (255) WriteCache=enabled
 Drive conforms to: ATA/ATAPI-7 T13 1532D revision 0:  ATA/ATAPI-1,2,3,4,5,6,7

 * signifies the current active mode

SATA drive: (the one that works fine)
hdparm -i /dev/sda

/dev/sda:

 Model=ST3808110AS                             , FwRev=3.AAH   , SerialNo=     
      5LS3YWT0
 Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs RotSpdTol>.5% }
 RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=4
 BuffType=unknown, BuffSize=8192kB, MaxMultSect=16, MultSect=?16?
 CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=156301488
 IORDY=on/off, tPIO={min:240,w/IORDY:120}, tDMA={min:120,rec:120}
 PIO modes:  pio0 pio1 pio2 pio3 pio4 
 DMA modes:  mdma0 mdma1 mdma2 
 UDMA modes: udma0 udma1 udma2 udma3 udma4 *udma5 
 AdvancedPM=no WriteCache=enabled
 Drive conforms to: Unspecified:  ATA/ATAPI-1,2,3,4,5,6,7

 * signifies the current active mode

If you need more info, please ask.

Comment 5 Chuck Ebbert 2008-03-13 20:51:38 UTC
Please post boot messages from the older kernel too.

Comment 6 ryuhei yokokawa 2008-03-13 23:52:56 UTC
Created attachment 298001 [details]
dmesg output for 2.6.23.1-42.fc8

Comment 7 Chuck Ebbert 2008-03-14 22:25:24 UTC
DMA gets disabled on sdb because of simplex DMA. This doesn't happen on 2.6.23.

2.6.23:
scsi4 : pata_atiixp
scsi5 : pata_atiixp
ata5: PATA max UDMA/100 cmd 0x000101f0 ctl 0x000103f6 bmdma 0x0001ff00 irq 14
ata6: PATA max UDMA/100 cmd 0x00010170 ctl 0x00010376 bmdma 0x0001ff08 irq 15
ata5.00: ATAPI: _NEC DVD_RW ND-3520A, 1.04, max UDMA/33
ata5.00: configured for UDMA/33
ata6.00: ATA-7: Maxtor 6L300R0, BAH41G10, max UDMA/133
ata6.00: 586114704 sectors, multi 16: LBA48 
ata6.00: configured for UDMA/100
scsi 4:0:0:0: CD-ROM            _NEC     DVD_RW ND-3520A  1.04 PQ: 0 ANSI: 5
scsi 5:0:0:0: Direct-Access     ATA      Maxtor 6L300R0   BAH4 PQ: 0 ANSI: 5


2.6.24:
scsi4 : pata_atiixp
scsi5 : pata_atiixp
ata5: PATA max UDMA/100 cmd 0x1f0 ctl 0x3f6 bmdma 0xff00 irq 14
ata6: PATA max UDMA/100 cmd 0x170 ctl 0x376 bmdma 0xff08 irq 15
ata5.00: ATAPI: _NEC DVD_RW ND-3520A, 1.04, max UDMA/33
ata5.00: configured for UDMA/33
ata6.00: ATA-7: Maxtor 6L300R0, BAH41G10, max UDMA/133
ata6.00: 586114704 sectors, multi 16: LBA48 
ata6.00: simplex DMA is claimed by other device, disabling DMA
ata6.00: configured for PIO4
scsi 4:0:0:0: CD-ROM            _NEC     DVD_RW ND-3520A  1.04 PQ: 0 ANSI: 5
scsi 5:0:0:0: Direct-Access     ATA      Maxtor 6L300R0   BAH4 PQ: 0 ANSI: 5


Comment 8 Alan Cox 2008-03-15 22:01:54 UTC
The simplex would explain the bug. Quite why atiixp has decided to report
simplex now is a bit unclear. I'll take a look


Comment 9 Alan Cox 2008-03-17 18:13:38 UTC
Nothing obvious - no changes in the official base code that would explain it,
some in 2.6.25-rc are candidates if anyone backported the quirks changes.

Quick fix is to set ATA_FLAG_IGN_SIMPLEX but I would really like to understand
what has changed to trigger this


Comment 10 ryuhei yokokawa 2008-03-17 22:54:41 UTC
Interestingly enough, my laptop also uses the atiixp module and has an ide
drive.  It is currently using the 2.6.24 kernel and is working just fine.  The
model of this computer is Fujitsu S2110.

Comment 11 Chuck Ebbert 2008-03-18 16:14:28 UTC
(In reply to comment #9)
> Nothing obvious - no changes in the official base code that would explain it,
> some in 2.6.25-rc are candidates if anyone backported the quirks changes.
> 

Very little change to the libata code in this kernel.
 hpt/serverworks mode masking fix
 disable DMA on ali chipsets for ATAPI

> Quick fix is to set ATA_FLAG_IGN_SIMPLEX but I would really like to understand
> what has changed to trigger this
> 



Comment 12 François Kooman 2008-03-25 17:16:25 UTC
Same issue here on Asus Pundit-R with pata_atiixp (Fedora 9 Beta live CD, so
it's not fixed there yet...)

ata2.00: ATA-7: SAMSUNG HD160JJ, WU100-33, max UDMA7
ata2.00: 312581808 sectors, multi 16: LBA48 NCQ (depth 0/32)
ata2.00: simplex DMA is claimed by other device, disabling DMA
ata2.00: configured for PIO4

There seems to be a fix, the people at the Ubuntu forums seem to have solved it:
http://ubuntuforums.org/showthread.php?t=678153 by some module blacklisting/loading.

Smolt profile:
http://www.smolts.org/client/show_all/pub_4474aae3-fa6c-45c3-90cb-60aef7c38559


Comment 13 Alan Cox 2008-03-25 18:42:06 UTC
See comment #9 for a fix for the moment. It looks like either those bits are
getting bumped by something else. As the IXP is always fully dual channel the
comment #9 fix should sort Fedora out if pushed into the current kernel.


Comment 14 Chuck Ebbert 2008-03-26 21:55:03 UTC
The Ubuntu thread says that blacklisting ata_generic solves the problem.

Comment 15 Alan Cox 2008-03-26 23:34:07 UTC
So I saw - but ata_generic never touches it and in fact it'll not even call the
probe function for it as there are no PCI ident matches. I'll have a poke around
but I think thats a red herring


Comment 16 ryuhei yokokawa 2008-03-27 02:28:15 UTC
I think I've already tried that trick and I remember it not working.  I can try
again if you want me to.

Comment 17 Chuck Ebbert 2008-03-31 21:57:14 UTC
*** Bug 438918 has been marked as a duplicate of this bug. ***

Comment 18 Chuck Ebbert 2008-04-02 00:22:50 UTC
Possible fix went in 2.6.24.4-68:
[PATCH] pata_atiixp: Simplex clear

Comment 19 François Kooman 2008-04-11 09:29:16 UTC
It's not fixed for me in kernel-2.6.23.15-137.fc8 although it should be:

* Wed Apr 02 2008 Chuck Ebbert <cebbert> 2.6.24.4-68
- libata: clear simplex DMA before probing pata_atiixp devices (#437163)

scsi0 : pata_atiixp
scsi1 : pata_atiixp
ata1: PATA max UDMA/100 cmd 0x1f0 ctl 0x3f6 bmdma 0xff00 irq 14
ata2: PATA max UDMA/100 cmd 0x170 ctl 0x376 bmdma 0xff08 irq 15
ata1.00: ATAPI: Optiarc DVD RW AD-7200A, 1.01, max UDMA/66
ata1.00: configured for UDMA/66
ata2.00: ATA-7: SAMSUNG HD160JJ, WU100-33, max UDMA7
ata2.00: 312581808 sectors, multi 16: LBA48 NCQ (depth 0/32)
ata2.00: simplex DMA is claimed by other device, disabling DMA
ata2.00: configured for PIO4
scsi 0:0:0:0: CD-ROM            Optiarc  DVD RW AD-7200A  1.01 PQ: 0 ANSI: 5
scsi 1:0:0:0: Direct-Access     ATA      SAMSUNG HD160JJ  WU10 PQ: 0 ANSI: 5
sd 1:0:0:0: [sda] 312581808 512-byte hardware sectors (160042 MB)
sd 1:0:0:0: [sda] Write Protect is off
sd 1:0:0:0: [sda] Mode Sense: 00 3a 00 00
sd 1:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO
or FUA
sd 1:0:0:0: [sda] 312581808 512-byte hardware sectors (160042 MB)
sd 1:0:0:0: [sda] Write Protect is off
sd 1:0:0:0: [sda] Mode Sense: 00 3a 00 00
sd 1:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO
or FUA
 sda: sda1 sda2
sd 1:0:0:0: [sda] Attached SCSI disk


Comment 20 François Kooman 2008-04-11 09:34:10 UTC
I mean kernel-2.6.24.4-74.fc8, and not kernel-2.6.23.15-137.fc8 (which is the
one that still works)

Comment 21 Alan Cox 2008-04-30 17:16:40 UTC
This has now been root caused thanks to some debugging and a very helpful email
I received.

There are two parts to the problem

1. Fedora incorrectly loads pata_acpi earlier than many other ATA drivers. It
*must* be loaded along with ata_generic/pata_legacy at the end.

2. When the ATI controller is put into power save and back (which occurs as the
acpi drive probes it) the device helpfully lose some configuration data and will
not let us restore it either.

Bug 1 needs fixing at the distro level and will bite other configurations

Bug 2 is being worked on

Comment 22 Alan Cox 2008-05-14 11:15:50 UTC
Kernel bits are fixed upstream. Assigning over to the anaconda team to fix the
installer



Comment 23 Jeremy Katz 2008-05-14 12:47:58 UTC
anaconda just uses udev and thus modprobe for loading modules these days --
they'll get loaded with 'modprobe <modalias>'.  So as long as that does the
right thing, then the right thing will occur in the installer

Comment 24 Chuck Ebbert 2008-05-15 15:30:18 UTC
Multiple devices will get loaded for the same alias. Can we make modprobe load
specific devices before generic ones?

pata_acpi has this alias:  pci:v*d*sv*sd*bc01sc01i*

That matches every PCI IDE controller.


Comment 25 François Kooman 2008-05-24 12:41:23 UTC
I just tested with kernel-2.6.25.4-10.fc8 on Fedora 8, doesn't work yet... Will
the fix be in a later errata update? Is there an update planned for F9? I could
create a respin then on my other machine and install it that way :)

Comment 26 Chuck Ebbert 2008-06-06 00:31:28 UTC
Kernel patch went in 2.6.25.4-18

Comment 27 Fedora Update System 2008-06-12 01:20:23 UTC
kernel-2.6.25.6-24.fc8 has been submitted as an update for Fedora 8

Comment 28 Jon Masters 2008-08-15 19:26:05 UTC
I can update module-init-tools wrt. the modalias matching, is this bug still happening on recent kernels?

(this bug was assigned to another account, reassigning to jcm)

Comment 29 Bug Zapper 2008-11-26 10:08:27 UTC
This message is a reminder that Fedora 8 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 8.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '8'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 8's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 8 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 30 Bug Zapper 2009-01-09 07:43:30 UTC
Fedora 8 changed to end-of-life (EOL) status on 2009-01-07. Fedora 8 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.