Skip to contentSkip to conversation

dma problems with via82cxxx after suspend

DISCUSSION David Meier 2 participants 2 messages Mar 14, 2005 – Mar 18, 2005 libata

lore
Share & tools
lore
#0 lore raw

I get DMA errors after resuming from suspend (S3).

I had switched DMA off before suspending.

Kernel: 2.6.10 (ubuntu, 2.6.10-27), same with 2.6.8.1. Boot Parameters:
ro nobiospnp noapic pci=usepirqmask; same problem without those.

Hardware: Asus K8V SE Deluxe, Via K8T800 Chipset, via82cxxx loaded or compiled in. No errors with a kernel without that module.

This is the last dmesg:

hda: DMA disabled
hdb: DMA disabled
hdc: DMA disabled
hdd: DMA disabled
Stopping tasks: ==============================================| Back to C!
powernow-k8: ph2 null fid transition 0xc
ACPI: PCI interrupt 0000:00:07.0[A] -> GSI 11 (level, low) -> IRQ 11
ACPI: PCI interrupt 0000:00:0a.0[A] -> GSI 10 (level, low) -> IRQ 10
eth1: link down
ACPI: PCI interrupt 0000:00:0f.0[B] -> GSI 10 (level, low) -> IRQ 10
ACPI: PCI interrupt 0000:00:0f.1[A] -> GSI 11 (level, low) -> IRQ 11 Restarting tasks... done
usb 5-4: USB disconnect, address 3
VFS: busy inodes on changed media.
input: AT Translated Set 2 keyboard on isa0060/serio0
usb 5-4: new high speed USB device using ehci_hcd and address 4 scsi3 : SCSI emulation for USB Mass Storage devices
usb-storage: device found at 4
usb-storage: waiting for device to settle before scanning
Vendor: HL-DT-ST Model: DVDRAM GSA-4163B Rev: A101
Type: CD-ROM ANSI SCSI revision: 00
sr0: scsi3-mmc drive: 40x/40x writer dvd-ram cd/rw xa/form2 cdda tray Attached scsi CD-ROM sr0 at scsi3, channel 0, id 0, lun 0 Attached scsi generic sg0 at scsi3, channel 0, id 0, lun 0, type 5
usb-storage: device scan complete
hda: dma_timer_expiry: dma status == 0x61
hda: DMA timeout error
hda: dma timeout error: status=0x58 { DriveReady SeekComplete DataRequest }

ide: failed opcode was: unknown
hda: status timeout: status=0xd0 { Busy }

ide: failed opcode was: unknown
hdb: DMA disabled
hda: drive not ready for command
ide0: reset: success
hda: dma_timer_expiry: dma status == 0x21
hda: DMA timeout error
hda: dma timeout error: status=0x58 { DriveReady SeekComplete DataRequest }

ide: failed opcode was: unknown
hda: status timeout: status=0xd0 { Busy }

ide: failed opcode was: unknown
hda: drive not ready for command
ide0: reset: success
hda: dma_timer_expiry: dma status == 0x21
hda: DMA timeout error
hda: dma timeout error: status=0x58 { DriveReady SeekComplete DataRequest }

ide: failed opcode was: unknown
hda: status timeout: status=0xd0 { Busy }

ide: failed opcode was: unknown
hda: drive not ready for command
ide0: reset: success
hda: dma_timer_expiry: dma status == 0x21
hda: DMA timeout error
hda: dma timeout error: status=0x58 { DriveReady SeekComplete DataRequest }

ide: failed opcode was: unknown
hda: status timeout: status=0xd0 { Busy }

ide: failed opcode was: unknown
hda: drive not ready for command
ide0: reset: success

Thanks
David

#1 lore raw
Quoted 3 lines · David Meier

I get DMA errors after resuming from suspend (S3).

I had switched DMA off before suspending.

...

This should be fixed in ide-dev-2.6 tree and in -mm series. Alternatively you can try attached patch.

Bartlomiej

# This is a BitKeeper generated diff -Nru style patch. #
# ChangeSet
# 2005/02/03 21:47:18+01:00 bzolnier@trik.(none)
# [ide] fix via82cxxx resume failure
#
# With David Woodhouse <[email protected]>.
#
# On resume from sleep, via_set_speed() doesn't reinstate the correct
# mode, because it thinks the drive is already configured correctly.
#
# Also kill redundant printk, ide_config_drive_speed() warns about errors.
#

# drivers/ide/pci/via82cxxx.c
#   2005/02/03 21:47:05+01:00 bzolnier@trik.(none) +2 -5
#   [ide] fix via82cxxx resume failure
# 
diff -Nru a/drivers/ide/pci/via82cxxx.c b/drivers/ide/pci/via82cxxx.c
--- a/drivers/ide/pci/via82cxxx.c	2005-03-18 17:26:38 +01:00
+++ b/drivers/ide/pci/via82cxxx.c	2005-03-18 17:26:38 +01:00
@@ -332,11 +332,8 @@
 	struct ide_timing t, p;
 	unsigned int T, UT;

- if (speed != XFER_PIO_SLOW && speed != drive->current_speed)
- if (ide_config_drive_speed(drive, speed))
- printk(KERN_WARNING "ide%d: Drive %d didn't "
- "accept speed setting. Oh, well.\n",
- drive->dn >> 1, drive->dn & 1);
+ if (speed != XFER_PIO_SLOW)
+ ide_config_drive_speed(drive, speed);

T = 1000000000 / via_clock;