# DVD RW can't use DMA [NOT SOLVED]

## NeoRiddle

Hi

When I want to burn a DVD o CD with K3B it suggest me to active DMA support.

It suggest me to run hdparm to activate it temporaly, but it does not active:

```
neobalam linux # hdparm -d /dev/hdc

/dev/hdc:

 using_dma     =  0 (off)

neobalam linux #

```

then i read hdparm man, and a test with -d1 flag:

```
neobalam linux # hdparm -d1 /dev/hdc

/dev/hdc:

 setting using_dma to 1 (on)

 HDIO_SET_DMA failed: Operation not permitted

 using_dma     =  0 (off)

neobalam linux #

```

then i have complied my kernel with these options:

```
neobalam linux # cat .config | grep -i "dma"

CONFIG_ZONE_DMA=y

CONFIG_GENERIC_ISA_DMA=y

CONFIG_ZONE_DMA_FLAG=1

CONFIG_ISA_DMA_API=y

CONFIG_BLK_DEV_IDEDMA_PCI=y

# CONFIG_BLK_DEV_IDEDMA_FORCED is not set

# CONFIG_IDEDMA_ONLYDISK is not set

CONFIG_BLK_DEV_IDEDMA=y

# CONFIG_IDEDMA_IVB is not set

# CONFIG_PDC_ADMA is not set

# CONFIG_PATA_OPTIDMA is not set

# CONFIG_CARDMAN_4000 is not set

# CONFIG_CARDMAN_4040 is not set

# DMA Engine support

CONFIG_DMA_ENGINE=y

# DMA Clients

CONFIG_NET_DMA=y

# DMA Devices

CONFIG_INTEL_IOATDMA=y

neobalam linux #

```

What can I do to run on DMA support?

----------

## Keruskerfuerst

```
hdparm -i /dev/hdc
```

?

----------

## NeoRiddle

```
neobalam linux # hdparm -i /dev/hdc

/dev/hdc:

 Model=PHILIPS DVD+/-RW SDVD8820, FwRev=AD15, 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:383,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

 AdvancedPM=no

 Drive conforms to: unknown:  ATA/ATAPI-3,4,5,6,7

 * signifies the current active mode

neobalam linux #  

```

----------

## Keruskerfuerst

```
UDMA modes: udma0 udma1 *udma2 
```

indicates: UDMA2 enabled.

----------

## NeoRiddle

ok, but why does it shows me this:

```
neobalam linux # hdparm -d /dev/hdc

/dev/hdc:

 using_dma     =  0 (off)

neobalam linux # 

```

and why k3b shows me this:

```
DMA deshabilitado para el dispositivo PHILIPS - DVD+-RW SDVD8820

Con la mayoría de dispositivos CD/DVD modernos activar DMA incrementa en gran medida las prestaciones de lectura/escritura. Si experimenta velocidades de escritura muy bajas esa es probablemente la causa.

Solución: Activar DMA temporalmente como root con 'hdparm -d /dev/hdc'.

```

----------

## Keruskerfuerst

Land of confusion.

----------

## Satori80

Weird. What happens if you try: 

```
hdparm -d1 -X udma2 /dev/hdc
```

----------

## cyrillic

 *NeoRiddle wrote:*   

> neobalam linux # hdparm -d1 /dev/hdc
> 
> /dev/hdc:
> 
>  setting using_dma to 1 (on)
> ...

 

This means your kernel does not have the correct chipset driver for the IDE controller that your DVD drive is plugged into.

Could you post the output of "lspci" ?

----------

## NeoRiddle

yes, here you have:

```
neobalam linux # lspci

00:00.0 Host bridge: Intel Corporation Mobile 945GM/PM/GMS, 943/940GML and 945GT Express Memory Controller Hub (rev 03)

00:02.0 VGA compatible controller: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller (rev 03)

00:02.1 Display controller: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller (rev 03)

00:1b.0 Audio device: Intel Corporation 82801G (ICH7 Family) High Definition Audio Controller (rev 01)

00:1c.0 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 1 (rev 01)

00:1c.1 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 2 (rev 01)

00:1c.3 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 4 (rev 01)

00:1d.0 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #1 (rev 01)

00:1d.1 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #2 (rev 01)

00:1d.2 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #3 (rev 01)

00:1d.3 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #4 (rev 01)

00:1d.7 USB Controller: Intel Corporation 82801G (ICH7 Family) USB2 EHCI Controller (rev 01)

00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev e1)

00:1f.0 ISA bridge: Intel Corporation 82801GBM (ICH7-M) LPC Interface Bridge (rev 01)

00:1f.2 IDE interface: Intel Corporation 82801GBM/GHM (ICH7 Family) SATA IDE Controller (rev 01)

00:1f.3 SMBus: Intel Corporation 82801G (ICH7 Family) SMBus Controller (rev 01)

03:00.0 Ethernet controller: Broadcom Corporation BCM4401-B0 100Base-TX (rev 02)

03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller

03:01.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 19)

03:01.2 System peripheral: Ricoh Co Ltd Unknown device 0843 (rev 01)

03:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 0a)

03:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 05)

0c:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG Network Connection (rev 02)

neobalam linux #    

```

and here you have hdparm too:

```
neobalam linux # hdparm -d1 -X udma2 /dev/hdc

/dev/hdc:

 setting using_dma to 1 (on)

 HDIO_SET_DMA failed: Operation not permitted

 setting xfermode to 66 (UltraDMA mode2)

 using_dma     =  0 (off)

neobalam linux #  

```

----------

## andreas_st

 *NeoRiddle wrote:*   

> 
> 
> ```
> 00:1f.2 IDE interface: Intel Corporation 82801GBM/GHM (ICH7 Family) SATA IDE Controller (rev 01)
> ```
> ...

 

I think you need either CONFIG_BLK_DEV_PIIX or CONFIG_ATA_PIIX in your kernel which adds support for Intel PIIX and ICH chipsets.

----------

## NeoRiddle

yes, they are active:

```
neobalam linux # cat .config | grep -i "CONFIG_BLK_DEV_PIIX"

CONFIG_BLK_DEV_PIIX=y

neobalam linux # cat .config | grep -i "CONFIG_ATA_PIIX"

CONFIG_ATA_PIIX=y

neobalam linux # 

```

----------

## NeddySeagoon

NeoRiddle,

ICH7 ... make your kernel like this to get best all round disk performace

----------

