Re: [PATCH 2/6] pata_sis: Implement MWDMA for the UDMA 133 capable chips

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Monday 07 December 2009 04:36:31 pm Bartlomiej Zolnierkiewicz wrote:
> On Monday 07 December 2009 04:05:28 pm Bartlomiej Zolnierkiewicz wrote:
> > On Monday 07 December 2009 02:26:00 pm Sergei Shtylyov wrote:
> > > Hello.
> > > 
> > > Alan Cox wrote:
> > > 
> > > > Bartlomiej pointed out that while this got fixed in the old driver whoever
> > > > did it didn't port it across.
> > > 
> > > > Signed-off-by: Alan Cox <alan@xxxxxxxxxxxxxxx>
> > > 
> > > [...]

One more thing:

@@ -479,13 +527,12 @@ static void sis_133_set_dmamode (struct ata_port *ap, struct ata_device *adev)
 	if (reg54 & 0x40000000)
 		port = 0x70;
 	port += (8 * ap->port_no) +  (4 * adev->devno);
-
 	pci_read_config_dword(pdev, port, &t1);
 
 	if (adev->dma_mode < XFER_UDMA_0) {
-		t1 &= ~0x00000004;
-		/* FIXME: need data sheet to add MWDMA here. Also lacking on
-		   ide/pci driver */
+		speed = mwdma_clip_to_pio(adev);
+		sis_133_do_piomode(ap, adev, speed);
+		t1 &= ~4;	/* UDMA off */
 	} else {
 		speed = adev->dma_mode - XFER_UDMA_0;
 		/* if & 8 no UDMA133 - need info for ... */

This way of doing things results in under-clocked timings for MWDMA0 mode,
(they're not the same as ones for PIO0 mode), old driver gets it correctly.

--
Bartlomiej Zolnierkiewicz
--
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux