Re: [PATCH] Re: ATIIXP and libata

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

 



On Thu, 01 Jun 2006 00:00:25 +0200 Velu Erwan wrote:

> Bruno Harbulot a écrit :
> 
> >I had a closer look at the problem, and I've written the patch for
> >ide-iops.c attached to this message. I wasn't sure about using
> >hw_config or ata_id_is_sata to read word 93.
> >Should other checks be performed? I'm not sure whether there should be
> >a test similar to "(ap->cbl == ATA_CBL_SATA)" mentionned in the patch
> >posted on this list in "[PATCH] libata ATA vs SATA detection and
> >workaround." on 30/09/04.
> >  
> >
> Bartlomiej, I've tried the latest 2.6.17-rc5 and the atiixp still 
> doesn't works out of the shelf.
> Bruno's patch sounds to integrate the remarks you made about my crappy 
> initial patch but it is not integrated.
> I've applied it, and uncommenting its ata_id_is_sata() call.
> On my ATIIXP (pundit-R), my performances are good ~55MB/sec. Without 
> this patch I'm sticked at 14MB/sec.

Where's Bart lately ??

> It is possible to apply that patch upstream to fix this issue ?
> This patch applies to 2.6.17-rc5.
> 
> --- linux-2.6.17-rc5.20mdk/drivers/ide/ide-iops.c.old    2006-03-20 
> 06:53:29.000000000 +0100
> +++ linux-2.6.17-rc5.20mdk/drivers/ide/ide-iops.c    2006-05-31 
> 23:51:53.000000000 +0200
> @@ -1,6 +1,10 @@
>  /*
> + * linux/drivers/ide/ide-iops.c    Version 0.38    Nov 05, 2005
>   * linux/drivers/ide/ide-iops.c    Version 0.37    Mar 05, 2003
>   *
> + *  Version 0.38        80pin cable detection for SATA drive
> + *                  (bruno_harbulot@xxxxxxxxxxx)
> + * 
>   *  Copyright (C) 2000-2002    Andre Hedrick <andre@xxxxxxxxxxxxx>
>   *  Copyright (C) 2003        Red Hat <alan@xxxxxxxxxx>
>   *
> @@ -24,6 +28,7 @@
>  #include <linux/hdreg.h>
>  #include <linux/ide.h>
>  #include <linux/bitops.h>
> +#include <linux/ata.h>
>  
>  #include <asm/byteorder.h>
>  #include <asm/irq.h>
> @@ -595,6 +600,12 @@
>   */
>  u8 eighty_ninty_three (ide_drive_t *drive)
>  {
> +    /* On SATA drives, word 93 (i.e. hw_config) should be 0.
> +     * This can be tested with the hw_config or this: */
> +    if (ata_id_is_sata((u16*)(drive->id)))
> +        return 1;
> +    if (drive->id->hw_config == 0)
> +        return 1;

You don't need both of the if-tests above.  In the previous patch
revision (from Bruno), the first one was inside the comment block.

>      if(HWIF(drive)->udma_four == 0)
>          return 0;
>      if (!(drive->id->hw_config & 0x6000))


---
~Randy
-
: 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