Files burnt to DVDs corrupt when DMA enabled, tested with Kernel 2.4 and 2.6 series.

Files burnt to DVDs corrupt when DMA enabled, tested with Kernel 2.4 and 2.6 series.

Post by Thilo Schu » Mon, 27 Oct 2003 20:50:14

Hash: SHA1


I have recently used the dvd+rwtools released by Andy Polyakov to burn DVDs on
my Pioneer DVR-A06 burner.
After burning, I ran a diff on the resulting files and found the burnt file to
be different from the original. A closer examination revealed, that a few
chunks of each having a length of exactly 28 bytes had been written
incorrectly to the DVD.
The count of incorrectly written chunks depends strongly on additional
activity to the burning process itself. The more I work on the gui (browse
the web etc.), the more errors are written.

At first I thought it was caused due to the scsi-emulation that I used in the
kernels 2.4.20, 2.4.21 and 2.4.22 in order to be able to have decent burning
(burning with these kernels without ide-scsi emulation works very badly,
burning stops every 4 seconds because not enough data seems to be available).
When having ide-scsi disabled and DMA enabled, the resulting files were not
corrupt, even though burning was painfully slow, so I guessed it was a
problem specific to DMA and the ide-scsi driver. ide-scsi with DMA disabled
also produced files that were not corrupt - so I originally sent an email to
the ide-scsi maintainer a few weeks ago, I have not got a response until

Testing the latest kernel 2.6.0-test9 though I did not have problems burning
without scsi emulation, and I now ran the same tests again. The result was,
that with DMA enabled, there _are_ corruptions, namely those 28 byte chunks
described above, without DMA there were no corruptions again.

I took following steps to exclude possibilities that could have caused the

- - i managed to stop the burning process with CTRL+Z and with few background
activity, the burning proceeded correctly without any differences in the
resulting files, therefore it is unlikely to be caused by buffer underruns.

- - Burning under windows on the same hardware went eventlessly and correctly in
all cases on the
very same computer, even with other activity running parallely, thus I deem
it unlikely to be caused by a hardware bug.

- - I checked the image that was created by mkisofs, and the files in this image
did not contain any errors.

- - The dvd burning software was reported to work well and error-free on other
hardware setups.

- - I switched DMA off - system performance drops much as expected, but the
resulting file is not corrupt.

- - burning with and without umaskirq enabled does not make any difference

When repeatedly burning the same file, these erroneous chunks never appear at
the same byte count, probably always then when I did something else at the
time of the burning.
This is a part of the response of the developer of the dvd+rwtools:

Last but not least a bit of output from the interesting parts in the /proc
file system:

thilo@Thilo / $ cat /proc/ide/via
- ----------VIA BusMastering IDE Configuration----------------
Driver Version: 3.38
South Bridge: VIA vt82c686b
Revision: ISA 0x40 IDE 0x6
Highest DMA rate: UDMA100
BM-DMA base: 0xd800
PCI clock: 33.3MHz
Master Read Cycle IRDY: 0ws
Master Write Cycle IRDY: 0ws
BM IDE Status Register Read Retry: yes
Max DRDY Pulse Width: No limit
- ------

Files burnt to DVDs corrupt when DMA enabled, tested with Kernel 2.4 and 2.6 series.

Post by erik » Tue, 28 Oct 2003 01:00:15

I think I can confirm this problem but give not so much informations. I
had a 1200 Mhz Athlon running on a board with a onboard-controller and a
promise udma 100 controller. I connected my dvd-write to one of these
controllers, I don't know which anymore and I had corrupted data too,
the system had nearly no load and I would guess that I had perpahs 5
places on a dvd which where corrupted. I used dma. The writer and the
cable worked fine in a system with a dual-p3 with intel bx chipset. I
think I was running a 2.4 kernel, newer than 2.4.20 I think. I currently
got this system offline because I am moving. If you need more
informations I will perhaps be able to gain them in a week or so.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to XXXX@XXXXX.COM
More majordomo info at
Please read the FAQ at