patch-2.1.77 linux/drivers/block/trm290.c

Next file: linux/drivers/cdrom/Config.in
Previous file: linux/drivers/block/paride/setup.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.76/linux/drivers/block/trm290.c linux/drivers/block/trm290.c
@@ -220,10 +220,10 @@
 	 && !pcibios_read_config_dword(hwif->pci_bus, hwif->pci_fn, 0x20, &cfgbase) && cfgbase)
 	{
 		hwif->config_data = cfgbase & ~1;
-		printk("TRM290: chip config base at 0x%04x\n", hwif->config_data);
+		printk("TRM290: chip config base at 0x%04lx\n", hwif->config_data);
 	} else {
-		hwif->config_data = 0x3df4;
-		printk("TRM290: using default config base at 0x%04x\n", hwif->config_data);
+		hwif->config_data = 0x3df0;
+		printk("TRM290: using default config base at 0x%04lx\n", hwif->config_data);
 	}
 
 	save_flags(flags);
@@ -241,7 +241,7 @@
 		hwif->irq = hwif->channel ? 15 : 14;	/* legacy mode */
 	else if (!hwif->irq && hwif->mate && hwif->mate->irq)
 		hwif->irq = hwif->mate->irq;		/* sharing IRQ with mate */
-	ide_setup_dma(hwif, (hwif->channel ? hwif->config_data ^ 0x0080 : hwif->config_data) + 4, 2);
+	ide_setup_dma(hwif, (hwif->config_data + 4) ^ (hwif->channel ? 0x0080 : 0x0000), 2);
 	hwif->dmaproc = &trm290_dmaproc;
 	hwif->selectproc = &trm290_selectproc;
 	hwif->no_autodma = 1;				/* play it safe for now */

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov