lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 07 Feb 2007 15:11:57 +0800
From:	Conke Hu <conke.hu@....com>
To:	Jeff Garzik <jeff@...zik.org>
Cc:	Andrew Morton <akpm@...l.org>, Linus Torvalds <torvalds@...l.org>,
	linux-ide@...r.kernel.org, LKML <linux-kernel@...r.kernel.org>
Subject: Re: [git patches] libata fixes

On Fri, 2007-02-02 at 11:58 -0500, Jeff Garzik wrote:
> Brian and Tejun's patches fix really ugly bugs, Alan's are of less
> importance
> 
> Please pull from 'upstream-linus' branch of
> master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev.git upstream-linus
> 
> to receive the following updates:
> 
>  drivers/ata/libata-core.c  |    1 +
>  drivers/ata/pata_atiixp.c  |   11 +++++++++--
>  drivers/ata/pata_jmicron.c |   18 +++++-------------
>  drivers/ata/pata_via.c     |    3 ++-
>  drivers/pci/quirks.c       |    4 ++--
>  include/linux/libata.h     |    2 ++
>  6 files changed, 21 insertions(+), 18 deletions(-)
> 
> Alan (3):
>       pata_atiixp: propogate cable detection hack from drivers/ide to the new driver
>       pata_via: Correct missing comments
>       libata: Fix ata_busy_wait() kernel docs
> 
> Brian King (1):
>       libata: Initialize nbytes for internal sg commands
> 
> Tejun Heo (1):
>       ahci/pata_jmicron: fix JMicron quirk
> 
> diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
> index cf70702..667acd2 100644
> --- a/drivers/ata/libata-core.c
> +++ b/drivers/ata/libata-core.c
> @@ -1250,6 +1250,7 @@ unsigned ata_exec_internal_sg(struct ata_device *dev,
>  
>  		ata_sg_init(qc, sg, n_elem);
>  		qc->nsect = buflen / ATA_SECT_SIZE;
> +		qc->nbytes = buflen;
>  	}
>  
>  	qc->private_data = &wait;
> diff --git a/drivers/ata/pata_atiixp.c b/drivers/ata/pata_atiixp.c
> index 6f6672c..504e1db 100644
> --- a/drivers/ata/pata_atiixp.c
> +++ b/drivers/ata/pata_atiixp.c
> @@ -36,15 +36,22 @@ enum {
>  static int atiixp_pre_reset(struct ata_port *ap)
>  {
>  	struct pci_dev *pdev = to_pci_dev(ap->host->dev);
> -	static struct pci_bits atiixp_enable_bits[] = {
> +	static const struct pci_bits atiixp_enable_bits[] = {
>  		{ 0x48, 1, 0x01, 0x00 },
>  		{ 0x48, 1, 0x08, 0x00 }
>  	};
> +	u8 udma;
>  
>  	if (!pci_test_config_bits(pdev, &atiixp_enable_bits[ap->port_no]))
>  		return -ENOENT;
>  
> -	ap->cbl = ATA_CBL_PATA80;
> +	/* Hack from drivers/ide/pci. Really we want to know how to do the
> +	   raw detection not play follow the bios mode guess */
> +	pci_read_config_byte(pdev, ATIIXP_IDE_UDMA_MODE + ap->port_no, &udma);
> +	if ((udma & 0x07) >= 0x04 || (udma & 0x70) >= 0x40)
> +		ap->cbl = ATA_CBL_PATA80;
> +	else
> +		ap->cbl = ATA_CBL_PATA40;
>  	return ata_std_prereset(ap);
>  }
> (snip)
>  

Alan's patch is also important. Thank you :)

Without the patch, OS on 40-pin cable maybe get IDE DMA error (CRC
error, system hang, or even data crash).

Conke


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ