diff options
Diffstat (limited to 'drivers/atm/fore200e.c')
-rw-r--r-- | drivers/atm/fore200e.c | 70 |
1 files changed, 27 insertions, 43 deletions
diff --git a/drivers/atm/fore200e.c b/drivers/atm/fore200e.c index 361f5aee3be1..204814e88e46 100644 --- a/drivers/atm/fore200e.c +++ b/drivers/atm/fore200e.c | |||
@@ -527,8 +527,7 @@ fore200e_pca_reset(struct fore200e* fore200e) | |||
527 | } | 527 | } |
528 | 528 | ||
529 | 529 | ||
530 | static int __devinit | 530 | static int fore200e_pca_map(struct fore200e* fore200e) |
531 | fore200e_pca_map(struct fore200e* fore200e) | ||
532 | { | 531 | { |
533 | DPRINTK(2, "device %s being mapped in memory\n", fore200e->name); | 532 | DPRINTK(2, "device %s being mapped in memory\n", fore200e->name); |
534 | 533 | ||
@@ -561,8 +560,7 @@ fore200e_pca_unmap(struct fore200e* fore200e) | |||
561 | } | 560 | } |
562 | 561 | ||
563 | 562 | ||
564 | static int __devinit | 563 | static int fore200e_pca_configure(struct fore200e *fore200e) |
565 | fore200e_pca_configure(struct fore200e* fore200e) | ||
566 | { | 564 | { |
567 | struct pci_dev* pci_dev = (struct pci_dev*)fore200e->bus_dev; | 565 | struct pci_dev* pci_dev = (struct pci_dev*)fore200e->bus_dev; |
568 | u8 master_ctrl, latency; | 566 | u8 master_ctrl, latency; |
@@ -2028,8 +2026,7 @@ fore200e_change_qos(struct atm_vcc* vcc,struct atm_qos* qos, int flags) | |||
2028 | } | 2026 | } |
2029 | 2027 | ||
2030 | 2028 | ||
2031 | static int __devinit | 2029 | static int fore200e_irq_request(struct fore200e *fore200e) |
2032 | fore200e_irq_request(struct fore200e* fore200e) | ||
2033 | { | 2030 | { |
2034 | if (request_irq(fore200e->irq, fore200e_interrupt, IRQF_SHARED, fore200e->name, fore200e->atm_dev) < 0) { | 2031 | if (request_irq(fore200e->irq, fore200e_interrupt, IRQF_SHARED, fore200e->name, fore200e->atm_dev) < 0) { |
2035 | 2032 | ||
@@ -2051,8 +2048,7 @@ fore200e_irq_request(struct fore200e* fore200e) | |||
2051 | } | 2048 | } |
2052 | 2049 | ||
2053 | 2050 | ||
2054 | static int __devinit | 2051 | static int fore200e_get_esi(struct fore200e *fore200e) |
2055 | fore200e_get_esi(struct fore200e* fore200e) | ||
2056 | { | 2052 | { |
2057 | struct prom_data* prom = kzalloc(sizeof(struct prom_data), GFP_KERNEL | GFP_DMA); | 2053 | struct prom_data* prom = kzalloc(sizeof(struct prom_data), GFP_KERNEL | GFP_DMA); |
2058 | int ok, i; | 2054 | int ok, i; |
@@ -2081,8 +2077,7 @@ fore200e_get_esi(struct fore200e* fore200e) | |||
2081 | } | 2077 | } |
2082 | 2078 | ||
2083 | 2079 | ||
2084 | static int __devinit | 2080 | static int fore200e_alloc_rx_buf(struct fore200e *fore200e) |
2085 | fore200e_alloc_rx_buf(struct fore200e* fore200e) | ||
2086 | { | 2081 | { |
2087 | int scheme, magn, nbr, size, i; | 2082 | int scheme, magn, nbr, size, i; |
2088 | 2083 | ||
@@ -2146,8 +2141,7 @@ fore200e_alloc_rx_buf(struct fore200e* fore200e) | |||
2146 | } | 2141 | } |
2147 | 2142 | ||
2148 | 2143 | ||
2149 | static int __devinit | 2144 | static int fore200e_init_bs_queue(struct fore200e *fore200e) |
2150 | fore200e_init_bs_queue(struct fore200e* fore200e) | ||
2151 | { | 2145 | { |
2152 | int scheme, magn, i; | 2146 | int scheme, magn, i; |
2153 | 2147 | ||
@@ -2209,8 +2203,7 @@ fore200e_init_bs_queue(struct fore200e* fore200e) | |||
2209 | } | 2203 | } |
2210 | 2204 | ||
2211 | 2205 | ||
2212 | static int __devinit | 2206 | static int fore200e_init_rx_queue(struct fore200e *fore200e) |
2213 | fore200e_init_rx_queue(struct fore200e* fore200e) | ||
2214 | { | 2207 | { |
2215 | struct host_rxq* rxq = &fore200e->host_rxq; | 2208 | struct host_rxq* rxq = &fore200e->host_rxq; |
2216 | struct cp_rxq_entry __iomem * cp_entry; | 2209 | struct cp_rxq_entry __iomem * cp_entry; |
@@ -2269,8 +2262,7 @@ fore200e_init_rx_queue(struct fore200e* fore200e) | |||
2269 | } | 2262 | } |
2270 | 2263 | ||
2271 | 2264 | ||
2272 | static int __devinit | 2265 | static int fore200e_init_tx_queue(struct fore200e *fore200e) |
2273 | fore200e_init_tx_queue(struct fore200e* fore200e) | ||
2274 | { | 2266 | { |
2275 | struct host_txq* txq = &fore200e->host_txq; | 2267 | struct host_txq* txq = &fore200e->host_txq; |
2276 | struct cp_txq_entry __iomem * cp_entry; | 2268 | struct cp_txq_entry __iomem * cp_entry; |
@@ -2332,8 +2324,7 @@ fore200e_init_tx_queue(struct fore200e* fore200e) | |||
2332 | } | 2324 | } |
2333 | 2325 | ||
2334 | 2326 | ||
2335 | static int __devinit | 2327 | static int fore200e_init_cmd_queue(struct fore200e *fore200e) |
2336 | fore200e_init_cmd_queue(struct fore200e* fore200e) | ||
2337 | { | 2328 | { |
2338 | struct host_cmdq* cmdq = &fore200e->host_cmdq; | 2329 | struct host_cmdq* cmdq = &fore200e->host_cmdq; |
2339 | struct cp_cmdq_entry __iomem * cp_entry; | 2330 | struct cp_cmdq_entry __iomem * cp_entry; |
@@ -2374,10 +2365,10 @@ fore200e_init_cmd_queue(struct fore200e* fore200e) | |||
2374 | } | 2365 | } |
2375 | 2366 | ||
2376 | 2367 | ||
2377 | static void __devinit | 2368 | static void fore200e_param_bs_queue(struct fore200e *fore200e, |
2378 | fore200e_param_bs_queue(struct fore200e* fore200e, | 2369 | enum buffer_scheme scheme, |
2379 | enum buffer_scheme scheme, enum buffer_magn magn, | 2370 | enum buffer_magn magn, int queue_length, |
2380 | int queue_length, int pool_size, int supply_blksize) | 2371 | int pool_size, int supply_blksize) |
2381 | { | 2372 | { |
2382 | struct bs_spec __iomem * bs_spec = &fore200e->cp_queues->init.bs_spec[ scheme ][ magn ]; | 2373 | struct bs_spec __iomem * bs_spec = &fore200e->cp_queues->init.bs_spec[ scheme ][ magn ]; |
2383 | 2374 | ||
@@ -2388,8 +2379,7 @@ fore200e_param_bs_queue(struct fore200e* fore200e, | |||
2388 | } | 2379 | } |
2389 | 2380 | ||
2390 | 2381 | ||
2391 | static int __devinit | 2382 | static int fore200e_initialize(struct fore200e *fore200e) |
2392 | fore200e_initialize(struct fore200e* fore200e) | ||
2393 | { | 2383 | { |
2394 | struct cp_queues __iomem * cpq; | 2384 | struct cp_queues __iomem * cpq; |
2395 | int ok, scheme, magn; | 2385 | int ok, scheme, magn; |
@@ -2440,8 +2430,7 @@ fore200e_initialize(struct fore200e* fore200e) | |||
2440 | } | 2430 | } |
2441 | 2431 | ||
2442 | 2432 | ||
2443 | static void __devinit | 2433 | static void fore200e_monitor_putc(struct fore200e *fore200e, char c) |
2444 | fore200e_monitor_putc(struct fore200e* fore200e, char c) | ||
2445 | { | 2434 | { |
2446 | struct cp_monitor __iomem * monitor = fore200e->cp_monitor; | 2435 | struct cp_monitor __iomem * monitor = fore200e->cp_monitor; |
2447 | 2436 | ||
@@ -2452,8 +2441,7 @@ fore200e_monitor_putc(struct fore200e* fore200e, char c) | |||
2452 | } | 2441 | } |
2453 | 2442 | ||
2454 | 2443 | ||
2455 | static int __devinit | 2444 | static int fore200e_monitor_getc(struct fore200e *fore200e) |
2456 | fore200e_monitor_getc(struct fore200e* fore200e) | ||
2457 | { | 2445 | { |
2458 | struct cp_monitor __iomem * monitor = fore200e->cp_monitor; | 2446 | struct cp_monitor __iomem * monitor = fore200e->cp_monitor; |
2459 | unsigned long timeout = jiffies + msecs_to_jiffies(50); | 2447 | unsigned long timeout = jiffies + msecs_to_jiffies(50); |
@@ -2477,8 +2465,7 @@ fore200e_monitor_getc(struct fore200e* fore200e) | |||
2477 | } | 2465 | } |
2478 | 2466 | ||
2479 | 2467 | ||
2480 | static void __devinit | 2468 | static void fore200e_monitor_puts(struct fore200e *fore200e, char *str) |
2481 | fore200e_monitor_puts(struct fore200e* fore200e, char* str) | ||
2482 | { | 2469 | { |
2483 | while (*str) { | 2470 | while (*str) { |
2484 | 2471 | ||
@@ -2497,8 +2484,7 @@ fore200e_monitor_puts(struct fore200e* fore200e, char* str) | |||
2497 | #define FW_EXT "_ecd.bin2" | 2484 | #define FW_EXT "_ecd.bin2" |
2498 | #endif | 2485 | #endif |
2499 | 2486 | ||
2500 | static int __devinit | 2487 | static int fore200e_load_and_start_fw(struct fore200e *fore200e) |
2501 | fore200e_load_and_start_fw(struct fore200e* fore200e) | ||
2502 | { | 2488 | { |
2503 | const struct firmware *firmware; | 2489 | const struct firmware *firmware; |
2504 | struct device *device; | 2490 | struct device *device; |
@@ -2566,8 +2552,7 @@ release: | |||
2566 | } | 2552 | } |
2567 | 2553 | ||
2568 | 2554 | ||
2569 | static int __devinit | 2555 | static int fore200e_register(struct fore200e *fore200e, struct device *parent) |
2570 | fore200e_register(struct fore200e* fore200e, struct device *parent) | ||
2571 | { | 2556 | { |
2572 | struct atm_dev* atm_dev; | 2557 | struct atm_dev* atm_dev; |
2573 | 2558 | ||
@@ -2593,8 +2578,7 @@ fore200e_register(struct fore200e* fore200e, struct device *parent) | |||
2593 | } | 2578 | } |
2594 | 2579 | ||
2595 | 2580 | ||
2596 | static int __devinit | 2581 | static int fore200e_init(struct fore200e *fore200e, struct device *parent) |
2597 | fore200e_init(struct fore200e* fore200e, struct device *parent) | ||
2598 | { | 2582 | { |
2599 | if (fore200e_register(fore200e, parent) < 0) | 2583 | if (fore200e_register(fore200e, parent) < 0) |
2600 | return -ENODEV; | 2584 | return -ENODEV; |
@@ -2644,7 +2628,7 @@ fore200e_init(struct fore200e* fore200e, struct device *parent) | |||
2644 | 2628 | ||
2645 | #ifdef CONFIG_SBUS | 2629 | #ifdef CONFIG_SBUS |
2646 | static const struct of_device_id fore200e_sba_match[]; | 2630 | static const struct of_device_id fore200e_sba_match[]; |
2647 | static int __devinit fore200e_sba_probe(struct platform_device *op) | 2631 | static int fore200e_sba_probe(struct platform_device *op) |
2648 | { | 2632 | { |
2649 | const struct of_device_id *match; | 2633 | const struct of_device_id *match; |
2650 | const struct fore200e_bus *bus; | 2634 | const struct fore200e_bus *bus; |
@@ -2681,7 +2665,7 @@ static int __devinit fore200e_sba_probe(struct platform_device *op) | |||
2681 | return 0; | 2665 | return 0; |
2682 | } | 2666 | } |
2683 | 2667 | ||
2684 | static int __devexit fore200e_sba_remove(struct platform_device *op) | 2668 | static int fore200e_sba_remove(struct platform_device *op) |
2685 | { | 2669 | { |
2686 | struct fore200e *fore200e = dev_get_drvdata(&op->dev); | 2670 | struct fore200e *fore200e = dev_get_drvdata(&op->dev); |
2687 | 2671 | ||
@@ -2707,13 +2691,13 @@ static struct platform_driver fore200e_sba_driver = { | |||
2707 | .of_match_table = fore200e_sba_match, | 2691 | .of_match_table = fore200e_sba_match, |
2708 | }, | 2692 | }, |
2709 | .probe = fore200e_sba_probe, | 2693 | .probe = fore200e_sba_probe, |
2710 | .remove = __devexit_p(fore200e_sba_remove), | 2694 | .remove = fore200e_sba_remove, |
2711 | }; | 2695 | }; |
2712 | #endif | 2696 | #endif |
2713 | 2697 | ||
2714 | #ifdef CONFIG_PCI | 2698 | #ifdef CONFIG_PCI |
2715 | static int __devinit | 2699 | static int fore200e_pca_detect(struct pci_dev *pci_dev, |
2716 | fore200e_pca_detect(struct pci_dev *pci_dev, const struct pci_device_id *pci_ent) | 2700 | const struct pci_device_id *pci_ent) |
2717 | { | 2701 | { |
2718 | const struct fore200e_bus* bus = (struct fore200e_bus*) pci_ent->driver_data; | 2702 | const struct fore200e_bus* bus = (struct fore200e_bus*) pci_ent->driver_data; |
2719 | struct fore200e* fore200e; | 2703 | struct fore200e* fore200e; |
@@ -2766,7 +2750,7 @@ out_disable: | |||
2766 | } | 2750 | } |
2767 | 2751 | ||
2768 | 2752 | ||
2769 | static void __devexit fore200e_pca_remove_one(struct pci_dev *pci_dev) | 2753 | static void fore200e_pca_remove_one(struct pci_dev *pci_dev) |
2770 | { | 2754 | { |
2771 | struct fore200e *fore200e; | 2755 | struct fore200e *fore200e; |
2772 | 2756 | ||
@@ -2789,7 +2773,7 @@ MODULE_DEVICE_TABLE(pci, fore200e_pca_tbl); | |||
2789 | static struct pci_driver fore200e_pca_driver = { | 2773 | static struct pci_driver fore200e_pca_driver = { |
2790 | .name = "fore_200e", | 2774 | .name = "fore_200e", |
2791 | .probe = fore200e_pca_detect, | 2775 | .probe = fore200e_pca_detect, |
2792 | .remove = __devexit_p(fore200e_pca_remove_one), | 2776 | .remove = fore200e_pca_remove_one, |
2793 | .id_table = fore200e_pca_tbl, | 2777 | .id_table = fore200e_pca_tbl, |
2794 | }; | 2778 | }; |
2795 | #endif | 2779 | #endif |