mpc83xx: rm remaining FLAT_TREE code
authorKim Phillips <kim.phillips@freescale.com>
Thu, 20 Dec 2007 22:28:34 +0000 (16:28 -0600)
committerKim Phillips <kim.phillips@freescale.com>
Tue, 8 Jan 2008 15:56:42 +0000 (09:56 -0600)
..in board pci.c files

Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
board/freescale/mpc832xemds/pci.c
board/freescale/mpc8349emds/pci.c
board/freescale/mpc8349itx/pci.c
board/freescale/mpc8360emds/pci.c
board/sbc8349/pci.c

index 21641d4..f1f654f 100644 (file)
@@ -18,9 +18,7 @@
 #include <common.h>
 #include <pci.h>
 #include <i2c.h>
-#if defined(CONFIG_OF_FLAT_TREE)
-#include <ft_build.h>
-#elif defined(CONFIG_OF_LIBFDT)
+#if defined(CONFIG_OF_LIBFDT)
 #include <libfdt.h>
 #include <fdt_support.h>
 #endif
@@ -284,18 +282,5 @@ void ft_pci_setup(void *blob, bd_t *bd)
                }
        }
 }
-#elif defined(CONFIG_OF_FLAT_TREE)
-void
-ft_pci_setup(void *blob, bd_t *bd)
-{
-       u32 *p;
-       int len;
-
-       p = (u32 *)ft_get_prop(blob, "/" OF_SOC "/pci@8500/bus-range", &len);
-       if (p != NULL) {
-               p[0] = hose[0].first_busno;
-               p[1] = hose[0].last_busno;
-       }
-}
-#endif                         /* CONFIG_OF_FLAT_TREE */
+#endif                         /* CONFIG_OF_LIBFDT */
 #endif                         /* CONFIG_PCI */
index 3eaf77a..564e436 100644 (file)
@@ -25,9 +25,7 @@
 #include <pci.h>
 #include <asm/mpc8349_pci.h>
 #include <i2c.h>
-#if defined(CONFIG_OF_FLAT_TREE)
-#include <ft_build.h>
-#elif defined(CONFIG_OF_LIBFDT)
+#if defined(CONFIG_OF_LIBFDT)
 #include <libfdt.h>
 #include <fdt_support.h>
 #endif
@@ -424,26 +422,5 @@ void ft_pci_setup(void *blob, bd_t *bd)
 #endif
        }
 }
-#elif defined(CONFIG_OF_FLAT_TREE)
-void
-ft_pci_setup(void *blob, bd_t *bd)
-{
-               u32 *p;
-               int len;
-
-               p = (u32 *)ft_get_prop(blob, "/" OF_SOC "/pci@8500/bus-range", &len);
-               if (p != NULL) {
-               p[0] = pci_hose[0].first_busno;
-               p[1] = pci_hose[0].last_busno;
-               }
-
-#ifdef CONFIG_MPC83XX_PCI2
-       p = (u32 *)ft_get_prop(blob, "/" OF_SOC "/pci@8600/bus-range", &len);
-       if (p != NULL) {
-               p[0] = pci_hose[1].first_busno;
-               p[1] = pci_hose[1].last_busno;
-       }
-#endif
-}
-#endif /* CONFIG_OF_FLAT_TREE */
+#endif /* CONFIG_OF_LIBFDT */
 #endif /* CONFIG_PCI */
index a6bb101..d33edf3 100644 (file)
@@ -29,9 +29,7 @@
 #include <pci.h>
 #include <asm/mpc8349_pci.h>
 #include <i2c.h>
-#if defined(CONFIG_OF_FLAT_TREE)
-#include <ft_build.h>
-#elif defined(CONFIG_OF_LIBFDT)
+#if defined(CONFIG_OF_LIBFDT)
 #include <libfdt.h>
 #include <fdt_support.h>
 #endif
@@ -370,26 +368,5 @@ void ft_pci_setup(void *blob, bd_t *bd)
 #endif
        }
 }
-#elif defined(CONFIG_OF_FLAT_TREE)
-void
-ft_pci_setup(void *blob, bd_t *bd)
-{
-               u32 *p;
-               int len;
-
-               p = (u32 *)ft_get_prop(blob, "/" OF_SOC "/pci@8500/bus-range", &len);
-               if (p != NULL) {
-               p[0] = pci_hose[0].first_busno;
-               p[1] = pci_hose[0].last_busno;
-               }
-
-#ifdef CONFIG_MPC83XX_PCI2
-       p = (u32 *)ft_get_prop(blob, "/" OF_SOC "/pci@8600/bus-range", &len);
-       if (p != NULL) {
-               p[0] = pci_hose[1].first_busno;
-               p[1] = pci_hose[1].last_busno;
-       }
-#endif
-}
-#endif /* CONFIG_OF_FLAT_TREE */
+#endif /* CONFIG_OF_LIBFDT */
 #endif /* CONFIG_PCI */
index 64cb8ad..89d2225 100644 (file)
@@ -18,9 +18,7 @@
 #include <common.h>
 #include <pci.h>
 #include <i2c.h>
-#if defined(CONFIG_OF_FLAT_TREE)
-#include <ft_build.h>
-#elif defined(CONFIG_OF_LIBFDT)
+#if defined(CONFIG_OF_LIBFDT)
 #include <libfdt.h>
 #include <fdt_support.h>
 #endif
@@ -284,18 +282,5 @@ void ft_pci_setup(void *blob, bd_t *bd)
                }
        }
 }
-#elif defined(CONFIG_OF_FLAT_TREE)
-void
-ft_pci_setup(void *blob, bd_t *bd)
-{
-       u32 *p;
-       int len;
-
-       p = (u32 *)ft_get_prop(blob, "/" OF_SOC "/pci@8500/bus-range", &len);
-       if (p != NULL) {
-               p[0] = hose[0].first_busno;
-               p[1] = hose[0].last_busno;
-       }
-}
-#endif                         /* CONFIG_OF_FLAT_TREE */
+#endif                         /* CONFIG_OF_LIBFDT */
 #endif                         /* CONFIG_PCI */
index e59f9f9..527f7e4 100644 (file)
@@ -30,9 +30,7 @@
 #include <pci.h>
 #include <asm/mpc8349_pci.h>
 #include <i2c.h>
-#if defined(CONFIG_OF_FLAT_TREE)
-#include <ft_build.h>
-#elif defined(CONFIG_OF_LIBFDT)
+#if defined(CONFIG_OF_LIBFDT)
 #include <libfdt.h>
 #include <fdt_support.h>
 #endif
@@ -364,26 +362,5 @@ void ft_pci_setup(void *blob, bd_t *bd)
 #endif
        }
 }
-#elif defined(CONFIG_OF_FLAT_TREE)
-void
-ft_pci_setup(void *blob, bd_t *bd)
-{
-               u32 *p;
-               int len;
-
-               p = (u32 *)ft_get_prop(blob, "/" OF_SOC "/pci@8500/bus-range", &len);
-               if (p != NULL) {
-                       p[0] = pci_hose[0].first_busno;
-                       p[1] = pci_hose[0].last_busno;
-               }
-
-#ifdef CONFIG_MPC83XX_PCI2
-       p = (u32 *)ft_get_prop(blob, "/" OF_SOC "/pci@8600/bus-range", &len);
-       if (p != NULL) {
-               p[0] = pci_hose[1].first_busno;
-               p[1] = pci_hose[1].last_busno;
-       }
-#endif
-}
-#endif /* CONFIG_OF_FLAT_TREE */
+#endif /* CONFIG_OF_LIBFDT */
 #endif /* CONFIG_PCI */