diff options
Diffstat (limited to 'drivers/ide/pci/cs5535.c')
-rw-r--r-- | drivers/ide/pci/cs5535.c | 13 |
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 | ||
171 | static const struct ide_port_info cs5535_chipset __devinitdata = { | 173 | static 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 = { | |||
180 | static int __devinit cs5535_init_one(struct pci_dev *dev, | 182 | static 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 | ||
186 | static const struct pci_device_id cs5535_pci_tbl[] = { | 188 | static 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 | ||
199 | static int __init cs5535_ide_init(void) | 202 | static 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 | ||
207 | static void __exit cs5535_ide_exit(void) | ||
208 | { | ||
209 | pci_unregister_driver(&driver); | ||
210 | } | ||
211 | |||
204 | module_init(cs5535_ide_init); | 212 | module_init(cs5535_ide_init); |
213 | module_exit(cs5535_ide_exit); | ||
205 | 214 | ||
206 | MODULE_AUTHOR("AMD"); | 215 | MODULE_AUTHOR("AMD"); |
207 | MODULE_DESCRIPTION("PCI driver module for AMD/NS CS5535 IDE"); | 216 | MODULE_DESCRIPTION("PCI driver module for AMD/NS CS5535 IDE"); |