diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2008-04-28 07:41:36 -0400 |
---|---|---|
committer | Jeff Garzik <jgarzik@redhat.com> | 2008-04-29 02:16:25 -0400 |
commit | 3dd654bfdf8905d0acb6f6231b5e736d2b0d4bc6 (patch) | |
tree | 5d5cf68ed77f2dd57b04d0dd672ff633750ba43f /drivers | |
parent | a01e035ebb552223c03f2d9138ffc73f2d4d3965 (diff) |
[MIPS] ATA: Rename routerboard 500 to 532
The platform is actually named routerboard 532 so let's call it this. This
patch only rename files, Kconfig and C symbols; no functional changes.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/ata/Kconfig | 8 | ||||
-rw-r--r-- | drivers/ata/Makefile | 2 | ||||
-rw-r--r-- | drivers/ata/pata_rb532_cf.c (renamed from drivers/ata/pata_rb500_cf.c) | 78 |
3 files changed, 44 insertions, 44 deletions
diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig index 292aa9a0f02f..1c11df9a5f32 100644 --- a/drivers/ata/Kconfig +++ b/drivers/ata/Kconfig | |||
@@ -566,11 +566,11 @@ config PATA_RADISYS | |||
566 | 566 | ||
567 | If unsure, say N. | 567 | If unsure, say N. |
568 | 568 | ||
569 | config PATA_RB500 | 569 | config PATA_RB532 |
570 | tristate "RouterBoard 500 PATA CompactFlash support" | 570 | tristate "RouterBoard 532 PATA CompactFlash support" |
571 | depends on MIKROTIK_RB500 | 571 | depends on MIKROTIK_RB532 |
572 | help | 572 | help |
573 | This option enables support for the RouterBoard 500 | 573 | This option enables support for the RouterBoard 532 |
574 | PATA CompactFlash controller. | 574 | PATA CompactFlash controller. |
575 | 575 | ||
576 | If unsure, say N. | 576 | If unsure, say N. |
diff --git a/drivers/ata/Makefile b/drivers/ata/Makefile index 1fbc2aa648b7..b693d829383a 100644 --- a/drivers/ata/Makefile +++ b/drivers/ata/Makefile | |||
@@ -55,7 +55,7 @@ obj-$(CONFIG_PATA_PDC2027X) += pata_pdc2027x.o | |||
55 | obj-$(CONFIG_PATA_PDC_OLD) += pata_pdc202xx_old.o | 55 | obj-$(CONFIG_PATA_PDC_OLD) += pata_pdc202xx_old.o |
56 | obj-$(CONFIG_PATA_QDI) += pata_qdi.o | 56 | obj-$(CONFIG_PATA_QDI) += pata_qdi.o |
57 | obj-$(CONFIG_PATA_RADISYS) += pata_radisys.o | 57 | obj-$(CONFIG_PATA_RADISYS) += pata_radisys.o |
58 | obj-$(CONFIG_PATA_RB500) += pata_rb500_cf.o | 58 | obj-$(CONFIG_PATA_RB532) += pata_rb532_cf.o |
59 | obj-$(CONFIG_PATA_RZ1000) += pata_rz1000.o | 59 | obj-$(CONFIG_PATA_RZ1000) += pata_rz1000.o |
60 | obj-$(CONFIG_PATA_SC1200) += pata_sc1200.o | 60 | obj-$(CONFIG_PATA_SC1200) += pata_sc1200.o |
61 | obj-$(CONFIG_PATA_SERVERWORKS) += pata_serverworks.o | 61 | obj-$(CONFIG_PATA_SERVERWORKS) += pata_serverworks.o |
diff --git a/drivers/ata/pata_rb500_cf.c b/drivers/ata/pata_rb532_cf.c index 4345174aaeec..a108d259f19d 100644 --- a/drivers/ata/pata_rb500_cf.c +++ b/drivers/ata/pata_rb532_cf.c | |||
@@ -32,7 +32,7 @@ | |||
32 | 32 | ||
33 | #include <asm/gpio.h> | 33 | #include <asm/gpio.h> |
34 | 34 | ||
35 | #define DRV_NAME "pata-rb500-cf" | 35 | #define DRV_NAME "pata-rb532-cf" |
36 | #define DRV_VERSION "0.1.0" | 36 | #define DRV_VERSION "0.1.0" |
37 | #define DRV_DESC "PATA driver for RouterBOARD 532 Compact Flash" | 37 | #define DRV_DESC "PATA driver for RouterBOARD 532 Compact Flash" |
38 | 38 | ||
@@ -43,7 +43,7 @@ | |||
43 | #define RB500_CF_REG_CTRL 0x080E | 43 | #define RB500_CF_REG_CTRL 0x080E |
44 | #define RB500_CF_REG_DATA 0x0C00 | 44 | #define RB500_CF_REG_DATA 0x0C00 |
45 | 45 | ||
46 | struct rb500_cf_info { | 46 | struct rb532_cf_info { |
47 | void __iomem *iobase; | 47 | void __iomem *iobase; |
48 | unsigned int gpio_line; | 48 | unsigned int gpio_line; |
49 | int frozen; | 49 | int frozen; |
@@ -52,10 +52,10 @@ struct rb500_cf_info { | |||
52 | 52 | ||
53 | /* ------------------------------------------------------------------------ */ | 53 | /* ------------------------------------------------------------------------ */ |
54 | 54 | ||
55 | static inline void rb500_pata_finish_io(struct ata_port *ap) | 55 | static inline void rb532_pata_finish_io(struct ata_port *ap) |
56 | { | 56 | { |
57 | struct ata_host *ah = ap->host; | 57 | struct ata_host *ah = ap->host; |
58 | struct rb500_cf_info *info = ah->private_data; | 58 | struct rb532_cf_info *info = ah->private_data; |
59 | 59 | ||
60 | ata_sff_altstatus(ap); | 60 | ata_sff_altstatus(ap); |
61 | ndelay(RB500_CF_IO_DELAY); | 61 | ndelay(RB500_CF_IO_DELAY); |
@@ -63,14 +63,14 @@ static inline void rb500_pata_finish_io(struct ata_port *ap) | |||
63 | set_irq_type(info->irq, IRQ_TYPE_LEVEL_HIGH); | 63 | set_irq_type(info->irq, IRQ_TYPE_LEVEL_HIGH); |
64 | } | 64 | } |
65 | 65 | ||
66 | static void rb500_pata_exec_command(struct ata_port *ap, | 66 | static void rb532_pata_exec_command(struct ata_port *ap, |
67 | const struct ata_taskfile *tf) | 67 | const struct ata_taskfile *tf) |
68 | { | 68 | { |
69 | writeb(tf->command, ap->ioaddr.command_addr); | 69 | writeb(tf->command, ap->ioaddr.command_addr); |
70 | rb500_pata_finish_io(ap); | 70 | rb532_pata_finish_io(ap); |
71 | } | 71 | } |
72 | 72 | ||
73 | static void rb500_pata_data_xfer(struct ata_device *adev, unsigned char *buf, | 73 | static void rb532_pata_data_xfer(struct ata_device *adev, unsigned char *buf, |
74 | unsigned int buflen, int write_data) | 74 | unsigned int buflen, int write_data) |
75 | { | 75 | { |
76 | struct ata_port *ap = adev->link->ap; | 76 | struct ata_port *ap = adev->link->ap; |
@@ -84,27 +84,27 @@ static void rb500_pata_data_xfer(struct ata_device *adev, unsigned char *buf, | |||
84 | *buf = readb(ioaddr); | 84 | *buf = readb(ioaddr); |
85 | } | 85 | } |
86 | 86 | ||
87 | rb500_pata_finish_io(adev->link->ap); | 87 | rb532_pata_finish_io(adev->link->ap); |
88 | } | 88 | } |
89 | 89 | ||
90 | static void rb500_pata_freeze(struct ata_port *ap) | 90 | static void rb532_pata_freeze(struct ata_port *ap) |
91 | { | 91 | { |
92 | struct rb500_cf_info *info = ap->host->private_data; | 92 | struct rb532_cf_info *info = ap->host->private_data; |
93 | 93 | ||
94 | info->frozen = 1; | 94 | info->frozen = 1; |
95 | } | 95 | } |
96 | 96 | ||
97 | static void rb500_pata_thaw(struct ata_port *ap) | 97 | static void rb532_pata_thaw(struct ata_port *ap) |
98 | { | 98 | { |
99 | struct rb500_cf_info *info = ap->host->private_data; | 99 | struct rb532_cf_info *info = ap->host->private_data; |
100 | 100 | ||
101 | info->frozen = 0; | 101 | info->frozen = 0; |
102 | } | 102 | } |
103 | 103 | ||
104 | static irqreturn_t rb500_pata_irq_handler(int irq, void *dev_instance) | 104 | static irqreturn_t rb532_pata_irq_handler(int irq, void *dev_instance) |
105 | { | 105 | { |
106 | struct ata_host *ah = dev_instance; | 106 | struct ata_host *ah = dev_instance; |
107 | struct rb500_cf_info *info = ah->private_data; | 107 | struct rb532_cf_info *info = ah->private_data; |
108 | 108 | ||
109 | if (gpio_get_value(info->gpio_line)) { | 109 | if (gpio_get_value(info->gpio_line)) { |
110 | set_irq_type(info->irq, IRQ_TYPE_LEVEL_LOW); | 110 | set_irq_type(info->irq, IRQ_TYPE_LEVEL_LOW); |
@@ -117,30 +117,30 @@ static irqreturn_t rb500_pata_irq_handler(int irq, void *dev_instance) | |||
117 | return IRQ_HANDLED; | 117 | return IRQ_HANDLED; |
118 | } | 118 | } |
119 | 119 | ||
120 | static struct ata_port_operations rb500_pata_port_ops = { | 120 | static struct ata_port_operations rb532_pata_port_ops = { |
121 | .inherits = &ata_sff_port_ops, | 121 | .inherits = &ata_sff_port_ops, |
122 | .sff_exec_command = rb500_pata_exec_command, | 122 | .sff_exec_command = rb532_pata_exec_command, |
123 | .sff_data_xfer = rb500_pata_data_xfer, | 123 | .sff_data_xfer = rb532_pata_data_xfer, |
124 | .freeze = rb500_pata_freeze, | 124 | .freeze = rb532_pata_freeze, |
125 | .thaw = rb500_pata_thaw, | 125 | .thaw = rb532_pata_thaw, |
126 | }; | 126 | }; |
127 | 127 | ||
128 | /* ------------------------------------------------------------------------ */ | 128 | /* ------------------------------------------------------------------------ */ |
129 | 129 | ||
130 | static struct scsi_host_template rb500_pata_sht = { | 130 | static struct scsi_host_template rb532_pata_sht = { |
131 | ATA_PIO_SHT(DRV_NAME), | 131 | ATA_PIO_SHT(DRV_NAME), |
132 | }; | 132 | }; |
133 | 133 | ||
134 | /* ------------------------------------------------------------------------ */ | 134 | /* ------------------------------------------------------------------------ */ |
135 | 135 | ||
136 | static void rb500_pata_setup_ports(struct ata_host *ah) | 136 | static void rb532_pata_setup_ports(struct ata_host *ah) |
137 | { | 137 | { |
138 | struct rb500_cf_info *info = ah->private_data; | 138 | struct rb532_cf_info *info = ah->private_data; |
139 | struct ata_port *ap; | 139 | struct ata_port *ap; |
140 | 140 | ||
141 | ap = ah->ports[0]; | 141 | ap = ah->ports[0]; |
142 | 142 | ||
143 | ap->ops = &rb500_pata_port_ops; | 143 | ap->ops = &rb532_pata_port_ops; |
144 | ap->pio_mask = 0x1f; /* PIO4 */ | 144 | ap->pio_mask = 0x1f; /* PIO4 */ |
145 | ap->flags = ATA_FLAG_NO_LEGACY | ATA_FLAG_MMIO; | 145 | ap->flags = ATA_FLAG_NO_LEGACY | ATA_FLAG_MMIO; |
146 | 146 | ||
@@ -153,13 +153,13 @@ static void rb500_pata_setup_ports(struct ata_host *ah) | |||
153 | ap->ioaddr.data_addr = info->iobase + RB500_CF_REG_DATA; | 153 | ap->ioaddr.data_addr = info->iobase + RB500_CF_REG_DATA; |
154 | } | 154 | } |
155 | 155 | ||
156 | static __devinit int rb500_pata_driver_probe(struct platform_device *pdev) | 156 | static __devinit int rb532_pata_driver_probe(struct platform_device *pdev) |
157 | { | 157 | { |
158 | unsigned int irq; | 158 | unsigned int irq; |
159 | int gpio; | 159 | int gpio; |
160 | struct resource *res; | 160 | struct resource *res; |
161 | struct ata_host *ah; | 161 | struct ata_host *ah; |
162 | struct rb500_cf_info *info; | 162 | struct rb532_cf_info *info; |
163 | int ret; | 163 | int ret; |
164 | 164 | ||
165 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 165 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
@@ -213,10 +213,10 @@ static __devinit int rb500_pata_driver_probe(struct platform_device *pdev) | |||
213 | goto err_free_gpio; | 213 | goto err_free_gpio; |
214 | } | 214 | } |
215 | 215 | ||
216 | rb500_pata_setup_ports(ah); | 216 | rb532_pata_setup_ports(ah); |
217 | 217 | ||
218 | ret = ata_host_activate(ah, irq, rb500_pata_irq_handler, | 218 | ret = ata_host_activate(ah, irq, rb532_pata_irq_handler, |
219 | IRQF_TRIGGER_LOW, &rb500_pata_sht); | 219 | IRQF_TRIGGER_LOW, &rb532_pata_sht); |
220 | if (ret) | 220 | if (ret) |
221 | goto err_free_gpio; | 221 | goto err_free_gpio; |
222 | 222 | ||
@@ -228,10 +228,10 @@ err_free_gpio: | |||
228 | return ret; | 228 | return ret; |
229 | } | 229 | } |
230 | 230 | ||
231 | static __devexit int rb500_pata_driver_remove(struct platform_device *pdev) | 231 | static __devexit int rb532_pata_driver_remove(struct platform_device *pdev) |
232 | { | 232 | { |
233 | struct ata_host *ah = platform_get_drvdata(pdev); | 233 | struct ata_host *ah = platform_get_drvdata(pdev); |
234 | struct rb500_cf_info *info = ah->private_data; | 234 | struct rb532_cf_info *info = ah->private_data; |
235 | 235 | ||
236 | ata_host_detach(ah); | 236 | ata_host_detach(ah); |
237 | gpio_free(info->gpio_line); | 237 | gpio_free(info->gpio_line); |
@@ -242,9 +242,9 @@ static __devexit int rb500_pata_driver_remove(struct platform_device *pdev) | |||
242 | /* work with hotplug and coldplug */ | 242 | /* work with hotplug and coldplug */ |
243 | MODULE_ALIAS("platform:" DRV_NAME); | 243 | MODULE_ALIAS("platform:" DRV_NAME); |
244 | 244 | ||
245 | static struct platform_driver rb500_pata_platform_driver = { | 245 | static struct platform_driver rb532_pata_platform_driver = { |
246 | .probe = rb500_pata_driver_probe, | 246 | .probe = rb532_pata_driver_probe, |
247 | .remove = __devexit_p(rb500_pata_driver_remove), | 247 | .remove = __devexit_p(rb532_pata_driver_remove), |
248 | .driver = { | 248 | .driver = { |
249 | .name = DRV_NAME, | 249 | .name = DRV_NAME, |
250 | .owner = THIS_MODULE, | 250 | .owner = THIS_MODULE, |
@@ -255,16 +255,16 @@ static struct platform_driver rb500_pata_platform_driver = { | |||
255 | 255 | ||
256 | #define DRV_INFO DRV_DESC " version " DRV_VERSION | 256 | #define DRV_INFO DRV_DESC " version " DRV_VERSION |
257 | 257 | ||
258 | static int __init rb500_pata_module_init(void) | 258 | static int __init rb532_pata_module_init(void) |
259 | { | 259 | { |
260 | printk(KERN_INFO DRV_INFO "\n"); | 260 | printk(KERN_INFO DRV_INFO "\n"); |
261 | 261 | ||
262 | return platform_driver_register(&rb500_pata_platform_driver); | 262 | return platform_driver_register(&rb532_pata_platform_driver); |
263 | } | 263 | } |
264 | 264 | ||
265 | static void __exit rb500_pata_module_exit(void) | 265 | static void __exit rb532_pata_module_exit(void) |
266 | { | 266 | { |
267 | platform_driver_unregister(&rb500_pata_platform_driver); | 267 | platform_driver_unregister(&rb532_pata_platform_driver); |
268 | } | 268 | } |
269 | 269 | ||
270 | MODULE_AUTHOR("Gabor Juhos <juhosg at openwrt.org>"); | 270 | MODULE_AUTHOR("Gabor Juhos <juhosg at openwrt.org>"); |
@@ -273,5 +273,5 @@ MODULE_DESCRIPTION(DRV_DESC); | |||
273 | MODULE_VERSION(DRV_VERSION); | 273 | MODULE_VERSION(DRV_VERSION); |
274 | MODULE_LICENSE("GPL"); | 274 | MODULE_LICENSE("GPL"); |
275 | 275 | ||
276 | module_init(rb500_pata_module_init); | 276 | module_init(rb532_pata_module_init); |
277 | module_exit(rb500_pata_module_exit); | 277 | module_exit(rb532_pata_module_exit); |