/[linux-patches]/genpatches-2.6/tags/2.6.12-12/4330_svw-broadcom.patch
Gentoo

Contents of /genpatches-2.6/tags/2.6.12-12/4330_svw-broadcom.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 137 - (show annotations) (download)
Tue Aug 9 21:23:12 2005 UTC (12 years, 11 months ago) by dsd
File size: 2793 byte(s)
2.6.12-12 release
1 Author: Narendra Sankar <nsankar@broadcom.com>
2 Date: Wed, 25 May 2005 23:51:00 +0000 (-0700)
3 Source: http://www.kernel.org/git/gitweb.cgi?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=60bf09a366c873aab36e3b3110ee9f5bd89a1a6d
4
5 [PATCH] sata_svw: Add support for new device IDs
6
7 BCM5785 (HT1000) is a new southbridge from Serverworks/Broadcom that
8 incorporates 4 SATA ports in a single PCIX function. Functionally these
9 ports are similar to that in older devices like the Apple K2 and the
10 Frodo4/8. This patch adds support for the new PCI device ID along with a
11 blurb on what the various device IDs mean. Additionally in all devices
12 based on this SATA controller, the SATA ports appear as a single PCI
13 function. This is true for older Frodo8 devices as well. Hence the init
14 function should init all the ports present in the detected controller
15 (which could be 4 or 8).
16
17 Signed-off-by: Narendra Sankar <nsankar@broadcom.com>
18
19 --- a/drivers/scsi/sata_svw.c
20 +++ b/drivers/scsi/sata_svw.c
21 @@ -343,6 +343,7 @@ static int k2_sata_init_one (struct pci_
22 void *mmio_base;
23 int pci_dev_busy = 0;
24 int rc;
25 + int i;
26
27 if (!printed_version++)
28 printk(KERN_DEBUG DRV_NAME " version " DRV_VERSION "\n");
29 @@ -420,11 +421,11 @@ static int k2_sata_init_one (struct pci_
30 probe_ent->mwdma_mask = 0x7;
31 probe_ent->udma_mask = 0x7f;
32
33 - /* We have 4 ports per PCI function */
34 - k2_sata_setup_port(&probe_ent->port[0], base + 0 * K2_SATA_PORT_OFFSET);
35 - k2_sata_setup_port(&probe_ent->port[1], base + 1 * K2_SATA_PORT_OFFSET);
36 - k2_sata_setup_port(&probe_ent->port[2], base + 2 * K2_SATA_PORT_OFFSET);
37 - k2_sata_setup_port(&probe_ent->port[3], base + 3 * K2_SATA_PORT_OFFSET);
38 + /* different controllers have different number of ports - currently 4 or 8 */
39 + /* All ports are on the same function. Multi-function device is no
40 + * longer available. This should not be seen in any system. */
41 + for (i = 0; i < ent->driver_data; i++)
42 + k2_sata_setup_port(&probe_ent->port[i], base + i * K2_SATA_PORT_OFFSET);
43
44 pci_set_master(pdev);
45
46 @@ -444,11 +445,17 @@ err_out:
47 return rc;
48 }
49
50 -
51 +/* 0x240 is device ID for Apple K2 device
52 + * 0x241 is device ID for Serverworks Frodo4
53 + * 0x242 is device ID for Serverworks Frodo8
54 + * 0x24a is device ID for BCM5785 (aka HT1000) HT southbridge integrated SATA
55 + * controller
56 + * */
57 static struct pci_device_id k2_sata_pci_tbl[] = {
58 - { 0x1166, 0x0240, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 },
59 - { 0x1166, 0x0241, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 },
60 - { 0x1166, 0x0242, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 },
61 + { 0x1166, 0x0240, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 4 },
62 + { 0x1166, 0x0241, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 4 },
63 + { 0x1166, 0x0242, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 8 },
64 + { 0x1166, 0x024a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 4 },
65 { }
66 };
67

  ViewVC Help
Powered by ViewVC 1.1.20