ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-2.6.6.tar.bz2
[linux-2.6.git] / drivers / ide / pci / serverworks.h
1
2 #ifndef SERVERWORKS_H
3 #define SERVERWORKS_H
4
5 #include <linux/config.h>
6 #include <linux/pci.h>
7 #include <linux/ide.h>
8
9 #undef SVWKS_DEBUG_DRIVE_INFO
10
11 #define SVWKS_CSB5_REVISION_NEW 0x92 /* min PCI_REVISION_ID for UDMA5 (A2.0) */
12 #define SVWKS_CSB6_REVISION     0xa0 /* min PCI_REVISION_ID for UDMA4 (A1.0) */
13
14 /* Seagate Barracuda ATA IV Family drives in UDMA mode 5
15  * can overrun their FIFOs when used with the CSB5 */
16 const char *svwks_bad_ata100[] = {
17         "ST320011A",
18         "ST340016A",
19         "ST360021A",
20         "ST380021A",
21         NULL
22 };
23
24 #define DISPLAY_SVWKS_TIMINGS   1
25
26 static void init_setup_svwks(struct pci_dev *, ide_pci_device_t *);
27 static void init_setup_csb6(struct pci_dev *, ide_pci_device_t *);
28 static unsigned int init_chipset_svwks(struct pci_dev *, const char *);
29 static void init_hwif_svwks(ide_hwif_t *);
30 static void init_dma_svwks(ide_hwif_t *, unsigned long);
31
32 static ide_pci_device_t serverworks_chipsets[] __devinitdata = {
33         {       /* 0 */
34                 .vendor         = PCI_VENDOR_ID_SERVERWORKS,
35                 .device         = PCI_DEVICE_ID_SERVERWORKS_OSB4IDE,
36                 .name           = "SvrWks OSB4",
37                 .init_setup     = init_setup_svwks,
38                 .init_chipset   = init_chipset_svwks,
39                 .init_iops      = NULL,
40                 .init_hwif      = init_hwif_svwks,
41                 .init_dma       = NULL,
42                 .channels       = 2,
43                 .autodma        = AUTODMA,
44                 .enablebits     = {{0x00,0x00,0x00}, {0x00,0x00,0x00}},
45                 .bootable       = ON_BOARD,
46                 .extra          = 0,
47         },{     /* 1 */
48                 .vendor         = PCI_VENDOR_ID_SERVERWORKS,
49                 .device         = PCI_DEVICE_ID_SERVERWORKS_CSB5IDE,
50                 .name           = "SvrWks CSB5",
51                 .init_setup     = init_setup_svwks,
52                 .init_chipset   = init_chipset_svwks,
53                 .init_iops      = NULL,
54                 .init_hwif      = init_hwif_svwks,
55                 .init_dma       = init_dma_svwks,
56                 .channels       = 2,
57                 .autodma        = AUTODMA,
58                 .enablebits     = {{0x00,0x00,0x00}, {0x00,0x00,0x00}},
59                 .bootable       = ON_BOARD,
60                 .extra          = 0,
61         },{     /* 2 */
62                 .vendor         = PCI_VENDOR_ID_SERVERWORKS,
63                 .device         = PCI_DEVICE_ID_SERVERWORKS_CSB6IDE,
64                 .name           = "SvrWks CSB6",
65                 .init_setup     = init_setup_csb6,
66                 .init_chipset   = init_chipset_svwks,
67                 .init_iops      = NULL,
68                 .init_hwif      = init_hwif_svwks,
69                 .init_dma       = init_dma_svwks,
70                 .channels       = 2,
71                 .autodma        = AUTODMA,
72                 .enablebits     = {{0x00,0x00,0x00}, {0x00,0x00,0x00}},
73                 .bootable       = ON_BOARD,
74                 .extra          = 0,
75         },{     /* 3 */
76                 .vendor         = PCI_VENDOR_ID_SERVERWORKS,
77                 .device         = PCI_DEVICE_ID_SERVERWORKS_CSB6IDE2,
78                 .name           = "SvrWks CSB6",
79                 .init_setup     = init_setup_csb6,
80                 .init_chipset   = init_chipset_svwks,
81                 .init_iops      = NULL,
82                 .init_hwif      = init_hwif_svwks,
83                 .init_dma       = init_dma_svwks,
84                 .channels       = 1,    /* 2 */
85                 .autodma        = AUTODMA,
86                 .enablebits     = {{0x00,0x00,0x00}, {0x00,0x00,0x00}},
87                 .bootable       = ON_BOARD,
88                 .extra          = 0,
89         },{
90                 .vendor         = 0,
91                 .device         = 0,
92                 .channels       = 0,
93                 .bootable       = EOL,
94         }
95 };
96
97 #endif /* SERVERWORKS_H */