ARM: integrator: delete non-devicetree boot path
Subsystems (2)
PATCH 3/6 ARM: integrator: delete non-devicetree boot path
The Device Tree boot path now supports everything the ATAG boot can provide, and the two are equivalent. This deletes the ATAG boot path from the Integrator/AP and Integrator/CP platforms to move them on to the future.
--- arch/arm/Kconfig | 1 + arch/arm/mach-integrator/core.c | 57 ---------- arch/arm/mach-integrator/integrator_ap.c | 135 ------------------------ arch/arm/mach-integrator/integrator_cp.c | 173 ------------------------------- arch/arm/mach-integrator/pci_v3.c | 122 +++++----------------- 5 files changed, 25 insertions(+), 463 deletions(-)
arch/arm/Kconfig +1 -0
@@ -317,6 +317,7 @@ config ARCH_INTEGRATOR select NEED_MACH_MEMORY_H select PLAT_VERSATILE select SPARSE_IRQ + select USE_OF select VERSATILE_FPGA_IRQ help Support for ARM's Integrator platform.
arch/arm/mach-integrator/core.c +0 -57
63 lines not on this page · raw message
arch/arm/mach-integrator/integrator_ap.c +0 -135
144 lines not on this page · raw message
arch/arm/mach-integrator/integrator_cp.c +0 -173
182 lines not on this page · raw message
arch/arm/mach-integrator/pci_v3.c +24 -98
146 lines not on this page · raw message
Signature · 1 line
1.8.3.1
PATCH 3/6 ARM: integrator: delete non-devicetree boot path
[Adding devicetree to Cc]
Quoted 14 lines · Linus Walleij
The Device Tree boot path now supports everything the ATAG boot can provide, and the two are equivalent. This deletes the ATAG boot path from the Integrator/AP and Integrator/CP platforms to move them on to the future.
Signed-off-by Linus Walleij <[email protected]>--- arch/arm/Kconfig | 1 + arch/arm/mach-integrator/core.c | 57 ---------- arch/arm/mach-integrator/integrator_ap.c | 135 ------------------------ arch/arm/mach-integrator/integrator_cp.c | 173 ------------------------------- arch/arm/mach-integrator/pci_v3.c | 122 +++++----------------- 5 files changed, 25 insertions(+), 463 deletions(-)
[...]
arch/arm/mach-integrator/pci_v3.c static int __init pci_v3_map_irq_dt(const struct pci_dev *dev, u8 slot, u8 pin) · line 846
Quoted 10 lines
arch/arm/mach-integrator/pci_v3.c +4
-0+static int __init pci_v3_probe (struct platform_device *pdev) { +struct device_node *np = pdev->dev.of_node;struct of_pci_range_parser parser;struct of_pci_range range;struct resource *res;int irq, ret; +/* Remap the Integrator system controller */ + ap_syscon_base =ioremap (INTEGRATOR_SC_BASE ,0x100 );
It seems a shame that this didn't get described in the DT. This hasn't been fully moved over...
arch/arm/mach-integrator/pci_v3.c static int __init pci_v3_map_irq_dt(const struct pci_dev *dev, u8 slot, u8 pin) · line 856
Quoted 10 lines
arch/arm/mach-integrator/pci_v3.c +10
-0+if (!ap_syscon_base) { +dev_err (&pdev->dev,"unable to remap the AP syscon for PCIv3\n" ); +return -ENODEV ; + } + +/* Device tree probe path */ +if (!np) { +dev_err (&pdev->dev,"no device tree node for PCIv3\n" ); +return -ENODEV ; + }
We didn't unmap the syscon registers, yet we mapped them here. Either we've got a useless mapping, or we're mapping it from the wrong block of code...
Cheers,
Mark.
PATCH 3/6 ARM: integrator: delete non-devicetree boot path
Quoted 5 lines · Mark Rutland
arch/arm/mach-integrator/pci_v3.c static int __init pci_v3_map_irq_dt(const struct pci_dev *dev, u8 slot, u8 pin) · line 846
Quoted 2 lines
arch/arm/mach-integrator/pci_v3.c +2
-0+/* Remap the Integrator system controller */ + ap_syscon_base =ioremap (INTEGRATOR_SC_BASE ,0x100 );It seems a shame that this didn't get described in the DT. This hasn't been fully moved over...
No. There is still stuff to move over, and not only the system controller, also the EBI (external bus interface) on the AP.
But we can still work from this point, or do you mean that we cannot proceed to delete the ATAG boot path before we fix this?
My idea is that deleting this makes the code easier to handle after the shrink.
Quoted 11 lines
arch/arm/mach-integrator/pci_v3.c static int __init pci_v3_map_irq_dt(const struct pci_dev *dev, u8 slot, u8 pin) · line 856
Quoted 10 lines
arch/arm/mach-integrator/pci_v3.c +10
-0+if (!ap_syscon_base) { +dev_err (&pdev->dev,"unable to remap the AP syscon for PCIv3\n" ); +return -ENODEV ; + } + +/* Device tree probe path */ +if (!np) { +dev_err (&pdev->dev,"no device tree node for PCIv3\n" ); +return -ENODEV ; + }
Quoted 3 lines
We didn't unmap the syscon registers, yet we mapped them here. Either we've got a useless mapping, or we're mapping it from the wrong block of code...
Sorry I'm not following this. The only thing the patch does is remove the ATAG boot path, moving the relevant part of the DT boot path over to the DT probe function and renaming it pci_v3_probe() in the process which might make the patch messy but that is all it does.
If you mean that we should unmap the syscon base you're right but that would be a separate patch, right?
I'll write a separate patch for that instead using devm_* so we don't have to unmap it by calling any special function.
Yours,
Linus Walleij