sata_via: magic vt6421 fix for transmission problems w/ WD drives

vt6421 has problems talking to recent WD drives. It causes a lot of
transmission errors while high bandwidth transfer as reported in the
following bugzilla entry.

https://bugzilla.kernel.org/show_bug.cgi?id=15173

Joseph Chan provided the following fix. I don't have any idea what it
does but I can verify the issue is gone with the patch applied.

Signed-off-by: Tejun Heo <tj@kernel.org>
Originally-from: Joseph Chan <JosephChan@via.com.tw>
Reported-by: Jorrit Tijben <sjorrit@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>

authored by Tejun Heo and committed by Jeff Garzik 8b27ff4c 67a3e12b

+13
+13
drivers/ata/sata_via.c
··· 575 tmp8 |= NATIVE_MODE_ALL; 576 pci_write_config_byte(pdev, SATA_NATIVE_MODE, tmp8); 577 } 578 } 579 580 static int svia_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
··· 575 tmp8 |= NATIVE_MODE_ALL; 576 pci_write_config_byte(pdev, SATA_NATIVE_MODE, tmp8); 577 } 578 + 579 + /* 580 + * vt6421 has problems talking to some drives. The following 581 + * is the magic fix from Joseph Chan <JosephChan@via.com.tw>. 582 + * Please add proper documentation if possible. 583 + * 584 + * https://bugzilla.kernel.org/show_bug.cgi?id=15173 585 + */ 586 + if (pdev->device == 0x3249) { 587 + pci_read_config_byte(pdev, 0x52, &tmp8); 588 + tmp8 |= 1 << 2; 589 + pci_write_config_byte(pdev, 0x52, tmp8); 590 + } 591 } 592 593 static int svia_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)