Bug 109 - DMA mode for CDROM/DVD doesn't work wih HPT370 controler
Summary: DMA mode for CDROM/DVD doesn't work wih HPT370 controler
Status: CLOSED WILL_FIX_LATER
Alias: None
Product: IO/Storage
Classification: Unclassified
Component: IDE (show other bugs)
Hardware: IA-32 Linux
: P2 normal
Assignee: Alan
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-11-20 15:03 UTC by F
Modified: 2007-06-18 08:01 UTC (History)
1 user (show)

See Also:
Kernel Version:
Subsystem:
Regression: ---
Bisected commit-id:


Attachments

Description F 2002-11-20 15:03:44 UTC
Sorry for my poor english.

Exact Kernel version: 2.5.48
============================

There is the same problem with 2.5.47-ac6

Distribution:
=============

RedHat 8.0

Hardware Environment:
=====================

$ lspci
00:00.0 Host bridge: VIA Technologies, Inc. VT8367 [KT266]
00:01.0 PCI bridge: VIA Technologies, Inc. VT8367 [KT333 AGP]
00:05.0 Unknown mass storage controller: Triones Technologies, Inc.
HPT366/368/370/370A/372 (rev 03)
00:06.0 Multimedia controller: Sigma Designs, Inc. REALmagic Hollywood Plus DVD
Decoder (rev 02)
00:07.0 Multimedia audio controller: Ensoniq ES1371 [AudioPCI-97] (rev 06)
00:08.0 ATM network controller: SGS Thomson Microelectronics: Unknown device
0500 (rev 10)
00:09.0 Multimedia video controller: Brooktree Corporation Bt848 Video Capture
(rev 12)
00:11.0 ISA bridge: VIA Technologies, Inc. VT8233 PCI to ISA Bridge
00:11.1 IDE interface: VIA Technologies, Inc. VT82C586B PIPC Bus Master IDE (rev 06)
01:00.0 VGA compatible controller: ATI Technologies Inc 3D Rage IIC AGP (rev 7a)

disks :
HPT370: chipset revision 3
HPT370: not 100%% native mode: will probe irqs later
HPT37X: using 33MHz PCI clock
    ide2: BM-DMA at 0xdc00-0xdc07, BIOS settings: hde:pio, hdf:pio
    ide3: BM-DMA at 0xdc08-0xdc0f, BIOS settings: hdg:DMA, hdh:pio
VP_IDE: IDE controller at PCI slot 00:11.1
VP_IDE: chipset revision 6
VP_IDE: not 100%% native mode: will probe irqs later
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
VP_IDE: VIA vt8233 (rev 00) IDE UDMA100 controller on pci00:11.1
    ide0: BM-DMA at 0xfc00-0xfc07, BIOS settings: hda:DMA, hdb:pio
    ide1: BM-DMA at 0xfc08-0xfc0f, BIOS settings: hdc:DMA, hdd:pio
hda: Maxtor 90340D2, ATA DISK drive
hdc: Maxtor 90340D2, ATA DISK drive
hde: SAMSUNG CD-R/RW SW-240B, ATAPI CD/DVD-ROM drive
hdf: CREATIVE DVD-ROM DVD1243E, ATAPI CD/DVD-ROM drive
hdg: WDC WD205AA-00BAA0, ATA DISK drive

Software Environment:
=====================

$ bash /usr/src/linux-2.5.48/scripts/ver_linux
If some fields are empty or look unusual you may have an old version.
Compare to the current minimal requirements in Documentation/Changes.

Linux localhost.localdomain 2.5.48 #1 Tue Nov 19 17:27:42 CET 2002 i686 athlon
i386 GNU/Linux

Gnu C                  3.2
Gnu make               3.79.1
util-linux             2.11r
mount                  2.11r
modutils               directory
e2fsprogs              1.27
Linux C Library        2.2.93
Dynamic linker (ldd)   2.2.93
Procps                 2.0.7
Net-tools              1.60
Kbd                    1.06
Sh-utils               2.0.12
Modules Loaded

I am not able to load ide-cd module under 2.5.48. insmod show me something like
"not enough memory".

Problem Description:
====================

DMA mode doesn't work with HPT370 controler (BIOS version 1.0.0622) and
CDROM/DVD drivers.
I tested it with :
CDROM (/dev/hde) : SAMSUNG CD-R/RW SW-240B
DVD (/dev/hdf) : CREATIVE DVD-ROM DVD1243E

I don't have problem with Linux 2.4.18 et kernel-2.4.18-18.8.0 (from RedHat)
expect this :
# hdparm -d 1 /dev/hde              # doesn't work
# hdparm -d 1 -X mdma2 /dev/hde     # work
# hdparm -d 1 /dev/hdf              # doesn't work
# hdparm -d 1 -X udma2 /dev/hdf     # work

With Linux 2.4.18 i use :
# hdparm -u 1 -c 1 -d 1 -X mdma2 /dev/hde
# hdparm -u 1 -c 1 -d 1 -X udma2 /dev/hdf
and this work perfectly.

Note that this problem seems to existe in 2.4.x (x > 18).

Default configuration (with Linux 2.4.18)
-----------------------------------------

# hdparm -iv /dev/hde
 HDIO_GET_MULTCOUNT failed: Invalid argument
 HDIO_GETGEO failed: Invalid argument

/dev/hde:
 IO_support   =  0 (default 16-bit)
 unmaskirq    =  0 (off)
 using_dma    =  0 (off)
 keepsettings =  0 (off)
 readonly     =  1 (on)
 readahead    =  8 (on)

 Model=SAMSUNG CD-R/RW SW-240B, FwRev=R402, SerialNo=
 Config={ Fixed Removeable DTR<=5Mbs DTR>10Mbs nonMagnetic }
 RawCHS=0/0/0, TrkSize=0, SectSize=0, ECCbytes=0
 BuffType=unknown, BuffSize=0kB, MaxMultSect=0
 (maybe): CurCHS=0/0/0, CurSects=0, LBA=yes, LBAsects=0
 IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120}
 PIO modes:  pio0 pio1 pio2 pio3 pio4
 DMA modes:  sdma0 sdma1 sdma2 mdma0 mdma1 *mdma2
 AdvancedPM=no
 Drive conforms to: ATA/ATAPI-5 T13 1321D revision 3:  5

# hdparm -iv /dev/hdf
 HDIO_GET_MULTCOUNT failed: Invalid argument
 HDIO_GETGEO failed: Invalid argument

/dev/hdf:
 IO_support   =  0 (default 16-bit)
 unmaskirq    =  0 (off)
 using_dma    =  0 (off)
 keepsettings =  0 (off)
 readonly     =  1 (on)
 readahead    =  8 (on)

 Model=CREATIVE DVD-ROM DVD1243E, FwRev=IC01, SerialNo=
 Config={ Fixed Removeable DTR<=5Mbs DTR>10Mbs nonMagnetic }
 RawCHS=0/0/0, TrkSize=0, SectSize=0, ECCbytes=0
 BuffType=unknown, BuffSize=0kB, MaxMultSect=0
 (maybe): CurCHS=0/0/0, CurSects=0, LBA=yes, LBAsects=0
 IORDY=yes, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120}
 PIO modes:  pio0 pio1 pio2 pio3 pio4
 DMA modes:  sdma0 sdma1 sdma2 mdma0 mdma1 mdma2
 UDMA modes: udma0 udma1 *udma2
 AdvancedPM=no

Linux 2.4.19
------------

DMA mode doesn't work with /dev/hdf (DVD). DMA automatically disabled for
/dev/hdf. So it still work.
"hdparm -iv /dev/hdf" doesn't show the valeur of "UDMA mode". it don't print
"*udma2" but only "udma2".

Linux 2.4.19-ac4
----------------

DMA mode doesn't work with /dev/hde and /dev/hdf (CDROM and DVD).
"hdparm -iv /dev/hde" doesn't show the valeur of "DMA mode". it don't print
"*mdma2" but only "mdma2".
"hdparm -iv /dev/hdf" doesn't show the valeur of "UDMA mode". it don't print
"*udma2" but only "udma2".

Linux 2.4.20-rc1-ac4
--------------------

DMA mode doesn't work with /dev/hde and /dev/hdf (CDROM and DVD).
"hdparm -iv /dev/hdf" doesn't show the valeur of "UDMA mode". it don't print
"*udma2" but only "udma2".

Linux 2.5.47-ac6 and 2.5.48
---------------------------

DMA mode doesn't work with /dev/hde and /dev/hdf (CDROM and DVD).
"hdparm -iv /dev/hdf" doesn't show the valeur of "UDMA mode". it don't print
"*udma2" but only "udma2".

Steps to reproduce:
===================

With Linux 2.5.48 (i have the same behavior and error message with 2.5.47-ac6).

# hdparm -d 1 -X mdma2 /dev/hde

/dev/hde:
 setting using_dma to 1 (on)
 setting xfermode to 34 (multiword DMA mode2)
 using_dma    =  1 (on)

# hdparm -d 1 -X udma2 /dev/hdf

/dev/hdf:
 setting using_dma to 1 (on)
 setting xfermode to 66 (UltraDMA mode2)
 using_dma    =  1 (on)

# mount -t iso9660 -o ro /dev/hde /mnt/cdrom
mount: wrong fs type, bad option, bad superblock on /dev/hde,
       or too many mounted file systems

# # kernel message
hde: 0 bytes in FIFO
hde: timeout waiting for DMA
hde: timeout waiting for DMA
hde: 0 bytes in FIFO
hde: timeout waiting for DMA
hde: (__ide_dma_test_irq) called while not waiting
hde: status error: status=0x58 { DriveReady SeekComplete DataRequest }
hde: status error: error=0x00
hde: drive not ready for command
hde: status error: status=0x58 { DriveReady SeekComplete DataRequest }
hde: status error: error=0x00
hde: drive not ready for command
hde: status error: status=0x58 { DriveReady SeekComplete DataRequest }
hde: status error: error=0x00
hde: drive not ready for command
hde: status error: status=0x58 { DriveReady SeekComplete DataRequest }
hde: status error: error=0x00
hde: drive not ready for command
hde: ATAPI reset complete
hde: tray open
end_request: I/O error, dev hde, sector 4293353888
isofs_fill_super: bread failed, dev=ide2(33,0), iso_blknum=16, block=16
end_request: I/O error, dev hde, sector 0
end_request: I/O error, dev hde, sector 0

# mount -t iso9660 -o ro /dev/hdf /mnt/dvd
mount: No medium found

# # kernel message
hdf: packet command error: status=0x51 { DriveReady SeekComplete Error }
hdf: packet command error: error=0x00
end_request: I/O error, dev hdf, sector 0
end_request: I/O error, dev hdf, sector 0
hdf: request sense failure: status=0x59 { DriveReady SeekComplete DataRequest
Error }
hdf: request sense failure: error=0x00
cdrom: open failed.
hdf: status error: status=0x59 { DriveReady SeekComplete DataRequest Error }
hdf: status error: error=0x00
hdf: drive not ready for command
hdf: packet command error: status=0x51 { DriveReady SeekComplete Error }
hdf: packet command error: error=0x00
end_request: I/O error, dev hdf, sector 0
end_request: I/O error, dev hdf, sector 0
hdf: request sense failure: status=0x59 { DriveReady SeekComplete DataRequest
Error }
hdf: request sense failure: error=0x00
hdf: status error: status=0x59 { DriveReady SeekComplete DataRequest Error }
hdf: status error: error=0x00
hdf: drive not ready for command
hdf: packet command error: status=0x51 { DriveReady SeekComplete Error }
hdf: packet command error: error=0x00
end_request: I/O error, dev hdf, sector 0
end_request: I/O error, dev hdf, sector 0
hdf: request sense failure: status=0x59 { DriveReady SeekComplete DataRequest
Error }
hdf: request sense failure: error=0x00
Comment 1 Alan 2002-11-20 15:59:57 UTC
The insmod bug in 2.5.48 is a bug in the module stuff not in the ide code

The lack of atapi on the highpoint 36x/37x is intentional right now. It may
change at some point in the future
Comment 2 Adrian Bunk 2005-12-29 04:23:26 UTC
Alan, what is the current status of this issue?
Comment 3 Alan 2007-06-18 08:01:05 UTC
Obsolete bug I think

Please re-open if seen on 2.6.20 or later

Note You need to log in before you can comment on or make changes to this bug.