]> git.sur5r.net Git - u-boot/commitdiff
fdt_support: Make of_bus_default_count_cells non static
authorArnab Basu <arnab.basu@freescale.com>
Mon, 8 Sep 2014 19:19:59 +0000 (12:19 -0700)
committerYork Sun <yorksun@freescale.com>
Thu, 25 Sep 2014 15:36:19 +0000 (08:36 -0700)
of_bus_default_count_cells can be used to get the #address-cells
and #size-cells defined by the current node's parent node. This
is required when using of_read_number to read from FDT nodes that
can be 32 or 64 bytes depending on values defined by the parent.

Signed-off-by: Arnab Basu <arnab.basu@freescale.com>
CC: Scott Wood <scottwood@freescale.com>
common/fdt_support.c
include/fdt_support.h

index 7ec7d4fc59396ed64212d38a82d6df2866be0411..3f641566b977aff76275656c86093051d2b1217c 100644 (file)
@@ -963,7 +963,7 @@ struct of_bus {
 };
 
 /* Default translator (generic bus) */
-static void of_bus_default_count_cells(void *blob, int parentoffset,
+void of_bus_default_count_cells(void *blob, int parentoffset,
                                        int *addrc, int *sizec)
 {
        const fdt32_t *prop;
index 649fbd6cc57b3fff95268719c038dbe06d74c15d..c3d1fbcf3566451419bff1a325a870a945743475 100644 (file)
@@ -142,6 +142,9 @@ static inline u64 of_read_number(const fdt32_t *cell, int size)
        return r;
 }
 
+void of_bus_default_count_cells(void *blob, int parentoffset,
+                                       int *addrc, int *sizec);
+
 #endif /* ifdef CONFIG_OF_LIBFDT */
 
 #ifdef USE_HOSTCC