aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/pci/cs5535.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/pci/cs5535.c')
-rw-r--r--drivers/ide/pci/cs5535.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/drivers/ide/pci/cs5535.c b/drivers/ide/pci/cs5535.c
index 5404fe4f701d..f7b50cdeefa6 100644
--- a/drivers/ide/pci/cs5535.c
+++ b/drivers/ide/pci/cs5535.c
@@ -26,6 +26,8 @@
26#include <linux/pci.h> 26#include <linux/pci.h>
27#include <linux/ide.h> 27#include <linux/ide.h>
28 28
29#define DRV_NAME "cs5535"
30
29#define MSR_ATAC_BASE 0x51300000 31#define MSR_ATAC_BASE 0x51300000
30#define ATAC_GLD_MSR_CAP (MSR_ATAC_BASE+0) 32#define ATAC_GLD_MSR_CAP (MSR_ATAC_BASE+0)
31#define ATAC_GLD_MSR_CONFIG (MSR_ATAC_BASE+0x01) 33#define ATAC_GLD_MSR_CONFIG (MSR_ATAC_BASE+0x01)
@@ -169,7 +171,7 @@ static const struct ide_port_ops cs5535_port_ops = {
169}; 171};
170 172
171static const struct ide_port_info cs5535_chipset __devinitdata = { 173static const struct ide_port_info cs5535_chipset __devinitdata = {
172 .name = "CS5535", 174 .name = DRV_NAME,
173 .port_ops = &cs5535_port_ops, 175 .port_ops = &cs5535_port_ops,
174 .host_flags = IDE_HFLAG_SINGLE | IDE_HFLAG_POST_SET_MODE, 176 .host_flags = IDE_HFLAG_SINGLE | IDE_HFLAG_POST_SET_MODE,
175 .pio_mask = ATA_PIO4, 177 .pio_mask = ATA_PIO4,
@@ -180,7 +182,7 @@ static const struct ide_port_info cs5535_chipset __devinitdata = {
180static int __devinit cs5535_init_one(struct pci_dev *dev, 182static int __devinit cs5535_init_one(struct pci_dev *dev,
181 const struct pci_device_id *id) 183 const struct pci_device_id *id)
182{ 184{
183 return ide_setup_pci_device(dev, &cs5535_chipset); 185 return ide_pci_init_one(dev, &cs5535_chipset, NULL);
184} 186}
185 187
186static const struct pci_device_id cs5535_pci_tbl[] = { 188static const struct pci_device_id cs5535_pci_tbl[] = {
@@ -194,6 +196,7 @@ static struct pci_driver driver = {
194 .name = "CS5535_IDE", 196 .name = "CS5535_IDE",
195 .id_table = cs5535_pci_tbl, 197 .id_table = cs5535_pci_tbl,
196 .probe = cs5535_init_one, 198 .probe = cs5535_init_one,
199 .remove = ide_pci_remove,
197}; 200};
198 201
199static int __init cs5535_ide_init(void) 202static int __init cs5535_ide_init(void)
@@ -201,7 +204,13 @@ static int __init cs5535_ide_init(void)
201 return ide_pci_register_driver(&driver); 204 return ide_pci_register_driver(&driver);
202} 205}
203 206
207static void __exit cs5535_ide_exit(void)
208{
209 pci_unregister_driver(&driver);
210}
211
204module_init(cs5535_ide_init); 212module_init(cs5535_ide_init);
213module_exit(cs5535_ide_exit);
205 214
206MODULE_AUTHOR("AMD"); 215MODULE_AUTHOR("AMD");
207MODULE_DESCRIPTION("PCI driver module for AMD/NS CS5535 IDE"); 216MODULE_DESCRIPTION("PCI driver module for AMD/NS CS5535 IDE");