LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   disable dma on scsi emulated ide secondry-slave (https://www.linuxquestions.org/questions/linux-software-2/disable-dma-on-scsi-emulated-ide-secondry-slave-112482/)

qwijibow 11-04-2003 08:48 PM

disable dma on scsi emulated ide secondry-slave
 
Hi.

my system halts when mounting my 2nd cd-wr drive (samsung ide drive with scsi emulation parameter sent to kernel by grub)

from reading other threads on this site i believe it is because of corruption dureing dma (direct memory access)

how do i disable it ????

i cannot refere to it as hdd, (because of scsi)
and i know it has a symbolic link /dev/cdrom1.

i dont know how to find out what the link points to.

anyway, how do i disable dma for this drive only ???

thankyou.

megaspaz 11-04-2003 09:03 PM

do you know what ide channel that cd is on? hdb or hdc, etc.

as root:

hdparm -d0 /dev/hdX

where X is b, c, d, etc...

also check if you enable dma in any scripts on start up or what not and delete that line if there is. for redhat, a common place to enable dma manually is /etc/rc.d/rc.local. and maybe post your grub.conf file.

qwijibow 11-04-2003 09:24 PM

the drive WOULD be hdd (secondry slave)
BUT.. because of scsi emulation is cannot be accessed as ide anymore.

and therefore it is accessed at /dev/scd0 (scsi drive)

i cannot turn dma off with the usual method of hdpram -d 0 /dev/scd0
because. i get the error message hdpram does not suppord scsi.

so, my question is, what is the usual methos of turning offf dma for scsi devices ?

qwijibow 11-04-2003 09:25 PM

and my grub.conf file has a hdd=ide-scsi in the kernel parameter, (scsi emulation on an ide device)

megaspaz 11-04-2003 09:34 PM

no, dma access is still uses /dev/hdX. that's what you want to use for hdparm. scdX is not hdparm accessible. seriously.

hdparm -d0 /dev/hdd

i turn on dma in my /etc/rc.d/rc.local for my scsi emulated cdrw (hdb) and dvdrom (hdc).

Code:

[root prompt]# hdparm -I /dev/hdc

/dev/hdc:

ATAPI CD-ROM, with removable media
        Model Number:          TOSHIBA DVD-ROM SD-C2502
        Serial Number:          3200009153
        Firmware Revision:      1D13
Standards:
        Used: ATAPI for CD-ROMs, SFF-8020i, r2.5
        Supported: CD-ROM ATAPI-2
Configuration:
        DRQ response: 50us.
        Packet size: 12 bytes
Capabilities:
        LBA, IORDY(can be disabled)
        Buffer size: 128.0kB
        DMA: sdma0 sdma1 sdma2 mdma0 mdma1 mdma2 udma0 udma1 *udma2
            Cycle time: min=120ns recommended=120ns
        PIO: pio0 pio1 pio2 pio3 pio4
            Cycle time: no flow control=120ns  IORDY flow control=120ns
[root prompt]#

edit:

the line in my grub.conf:
Code:

kernel /boot/vmlinuz-XXXXXXXXX ro root=/dev/hda11 hdb=ide-scsi hdc=ide-scsi

qwijibow 11-04-2003 09:42 PM

EXCELENT !!!!

i can now mount cd's on my faster drive without fearing a freeze. thanX

ThanKs for the Help :)

megaspaz 11-04-2003 09:46 PM

Quote:

Originally posted by qwijibow
EXCELENT !!!!

i can now mount cd's on my faster drive without fearing a freeze. thanX

ThanKs for the Help :)

no problem. but are you sure dma is enabled? is it always enabled? do you know where it's enabled at? if i remember correctly hdparm settings aren't sticky. at least for me, hdparm dma wasn't on by default for my peripherals. i guess what i'm saying is to make sure you didn't manually set dma for that drive in one of your start up scripts.

qwijibow 11-04-2003 09:55 PM

dma is on on all devices by defualt on mv redhat 9 install.

as far as i now, i cannot find and reference to dma in any of the usual startup scripts.
but i have added the code to turn dma off on hdd in the last script rc.local just incase.


All times are GMT -5. The time now is 09:57 PM.