Root/target/linux/brcm47xx/patches-3.6/235-bcma-dont-expose-mips-irq.patch

1--- a/include/linux/bcma/bcma_driver_mips.h
2+++ b/include/linux/bcma/bcma_driver_mips.h
3@@ -49,6 +49,6 @@ static inline void bcma_core_mips_early_
4 
5 extern u32 bcma_cpu_clock(struct bcma_drv_mips *mcore);
6 
7-extern unsigned int bcma_core_mips_irq(struct bcma_device *dev);
8+extern unsigned int bcma_core_irq(struct bcma_device *core);
9 
10 #endif /* LINUX_BCMA_DRIVER_MIPS_H_ */
11--- a/drivers/bcma/driver_chipcommon.c
12+++ b/drivers/bcma/driver_chipcommon.c
13@@ -258,7 +258,7 @@ void bcma_chipco_serial_init(struct bcma
14         return;
15     }
16 
17- irq = bcma_core_mips_irq(cc->core);
18+ irq = bcma_core_irq(cc->core);
19 
20     /* Determine the registers of the UARTs */
21     cc->nr_serial_ports = (cc->capabilities & BCMA_CC_CAP_NRUART);
22--- a/drivers/bcma/driver_mips.c
23+++ b/drivers/bcma/driver_mips.c
24@@ -81,7 +81,7 @@ static u32 bcma_core_mips_irqflag(struct
25 /* Get the MIPS IRQ assignment for a specified device.
26  * If unassigned, 0 is returned.
27  */
28-unsigned int bcma_core_mips_irq(struct bcma_device *dev)
29+static unsigned int bcma_core_mips_irq(struct bcma_device *dev)
30 {
31     struct bcma_device *mdev = dev->bus->drv_mips.core;
32     u32 irqflag;
33@@ -96,7 +96,12 @@ unsigned int bcma_core_mips_irq(struct b
34 
35     return 0;
36 }
37-EXPORT_SYMBOL(bcma_core_mips_irq);
38+
39+unsigned int bcma_core_irq(struct bcma_device *dev)
40+{
41+ return bcma_core_mips_irq(dev) + 2;
42+}
43+EXPORT_SYMBOL(bcma_core_irq);
44 
45 static void bcma_core_mips_set_irq(struct bcma_device *dev, unsigned int irq)
46 {
47--- a/drivers/bcma/driver_pci_host.c
48+++ b/drivers/bcma/driver_pci_host.c
49@@ -577,7 +577,7 @@ int bcma_core_pci_plat_dev_init(struct p
50     pr_info("PCI: Fixing up device %s\n", pci_name(dev));
51 
52     /* Fix up interrupt lines */
53- dev->irq = bcma_core_mips_irq(pc_host->pdev->core) + 2;
54+ dev->irq = bcma_core_irq(pc_host->pdev->core);
55     pci_write_config_byte(dev, PCI_INTERRUPT_LINE, dev->irq);
56 
57     return 0;
58@@ -596,6 +596,6 @@ int bcma_core_pci_pcibios_map_irq(const
59 
60     pc_host = container_of(dev->bus->ops, struct bcma_drv_pci_host,
61                    pci_ops);
62- return bcma_core_mips_irq(pc_host->pdev->core) + 2;
63+ return bcma_core_irq(pc_host->pdev->core);
64 }
65 EXPORT_SYMBOL(bcma_core_pci_pcibios_map_irq);
66--- a/arch/mips/bcm47xx/gpio.c
67+++ b/arch/mips/bcm47xx/gpio.c
68@@ -94,7 +94,7 @@ int gpio_to_irq(unsigned gpio)
69 #endif
70 #ifdef CONFIG_BCM47XX_BCMA
71     case BCM47XX_BUS_TYPE_BCMA:
72- return bcma_core_mips_irq(bcm47xx_bus.bcma.bus.drv_cc.core) + 2;
73+ return bcma_core_irq(bcm47xx_bus.bcma.bus.drv_cc.core);
74 #endif
75     }
76     return -EINVAL;
77--- a/arch/mips/bcm47xx/serial.c
78+++ b/arch/mips/bcm47xx/serial.c
79@@ -62,7 +62,7 @@ static int __init uart8250_init_bcma(voi
80 
81         p->mapbase = (unsigned int) bcma_port->regs;
82         p->membase = (void *) bcma_port->regs;
83- p->irq = bcma_port->irq + 2;
84+ p->irq = bcma_port->irq;
85         p->uartclk = bcma_port->baud_base;
86         p->regshift = bcma_port->reg_shift;
87         p->iotype = UPIO_MEM;
88

Archive Download this file



interactive