All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [Patch v2 1/5] fdt_support: Move of_read_number to fdt_support.h
@ 2014-08-19 20:27 York Sun
  2014-08-19 20:27 ` [U-Boot] [Patch v2 2/5] fdt_support: Make of_bus_default_count_cells non static York Sun
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: York Sun @ 2014-08-19 20:27 UTC (permalink / raw)
  To: u-boot

From: Arnab Basu <arnab.basu@freescale.com>

This is being done so that it can be used outside 'fdt_support.c'. Making
life more convenient when reading device node properties that can be 32
or 64 bits long.

Signed-off-by: Arnab Basu <arnab.basu@freescale.com>
Cc: Scott Wood <scottwood@freescale.com>
---
Change log
 v2: new patch

 common/fdt_support.c  |    9 ---------
 include/fdt_support.h |    9 +++++++++
 2 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/common/fdt_support.c b/common/fdt_support.c
index 784a570..7ec7d4f 100644
--- a/common/fdt_support.c
+++ b/common/fdt_support.c
@@ -930,15 +930,6 @@ void fdt_del_node_and_alias(void *blob, const char *alias)
 	fdt_delprop(blob, off, alias);
 }
 
-/* Helper to read a big number; size is in cells (not bytes) */
-static inline u64 of_read_number(const fdt32_t *cell, int size)
-{
-	u64 r = 0;
-	while (size--)
-		r = (r << 32) | fdt32_to_cpu(*(cell++));
-	return r;
-}
-
 #define PRu64	"%llx"
 
 /* Max address size we deal with */
diff --git a/include/fdt_support.h b/include/fdt_support.h
index 1bda686..649fbd6 100644
--- a/include/fdt_support.h
+++ b/include/fdt_support.h
@@ -133,6 +133,15 @@ static inline int fdt_status_fail_by_alias(void *fdt, const char *alias)
 	return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_FAIL, 0);
 }
 
+/* Helper to read a big number; size is in cells (not bytes) */
+static inline u64 of_read_number(const fdt32_t *cell, int size)
+{
+	u64 r = 0;
+	while (size--)
+		r = (r << 32) | fdt32_to_cpu(*(cell++));
+	return r;
+}
+
 #endif /* ifdef CONFIG_OF_LIBFDT */
 
 #ifdef USE_HOSTCC
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2014-08-22 11:41 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-19 20:27 [U-Boot] [Patch v2 1/5] fdt_support: Move of_read_number to fdt_support.h York Sun
2014-08-19 20:27 ` [U-Boot] [Patch v2 2/5] fdt_support: Make of_bus_default_count_cells non static York Sun
2014-08-19 20:28 ` [U-Boot] [Patch v2 3/5] armv8/fsl-lsch3: Release secondary cores from boot hold off with Boot Page York Sun
2014-08-21 13:47   ` Mark Rutland
2014-08-21 18:32     ` York Sun
2014-08-21 18:50       ` bhupesh.sharma at freescale.com
2014-08-22  7:02         ` Arnab Basu
2014-08-22 11:24           ` Mark Rutland
2014-08-22 11:38         ` Mark Rutland
2014-08-22 11:41       ` Mark Rutland
2014-08-19 20:28 ` [U-Boot] [Patch v2 4/5] ARMv8/ls2085a: Enable secondary cores York Sun
2014-08-19 20:28 ` [U-Boot] [Patch v2 5/5] ARMv8/ls2085a: Move u-boot location to make room for RCW York Sun

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.