Patchwork [meta-fsl-ppc] qemu_fslgit: backport a patch from oe-core to define fdt_t types

login
register
mail settings
Submitter Ting Liu
Date July 16, 2013, 9:34 a.m.
Message ID <1373967267-21142-1-git-send-email-b28495@freescale.com>
Download mbox | patch
Permalink /patch/53755/
State Accepted
Headers show

Comments

Ting Liu - July 16, 2013, 9:34 a.m.
From: Ting Liu <b28495@freescale.com>

Fix the error:
usr/include/fdt.h:58:2: error: unknown type name 'fdt32_t'

Backport a patch from oe-core. Commit:
http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=
ea6e7975964c75e0c8224205e0c1fd04ba37ed4a

Signed-off-by: Ting Liu <b28495@freescale.com>
---
 recipes-devtools/qemu/files/fdt_header.patch |   39 ++++++++++++++++++++++++++
 recipes-devtools/qemu/qemu_fslgit.bb         |    2 +
 2 files changed, 41 insertions(+), 0 deletions(-)
 create mode 100644 recipes-devtools/qemu/files/fdt_header.patch
Zhenhua Luo - July 17, 2013, 10:47 a.m.
Applied, thanks. 


Best Regards,

Zhenhua


> -----Original Message-----
> From: Liu Ting-B28495
> Sent: Tuesday, July 16, 2013 5:34 PM
> To: meta-freescale@yoctoproject.org
> Cc: Luo Zhenhua-B19537; Liu Ting-B28495
> Subject: [meta-fsl-ppc][PATCH] qemu_fslgit: backport a patch from oe-core
> to define fdt_t types
> 
> From: Ting Liu <b28495@freescale.com>
> 
> Fix the error:
> usr/include/fdt.h:58:2: error: unknown type name 'fdt32_t'
> 
> Backport a patch from oe-core. Commit:
> http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=
> ea6e7975964c75e0c8224205e0c1fd04ba37ed4a
> 
> Signed-off-by: Ting Liu <b28495@freescale.com>
> ---
>  recipes-devtools/qemu/files/fdt_header.patch |   39
> ++++++++++++++++++++++++++
>  recipes-devtools/qemu/qemu_fslgit.bb         |    2 +
>  2 files changed, 41 insertions(+), 0 deletions(-)  create mode 100644
> recipes-devtools/qemu/files/fdt_header.patch
> 
> diff --git a/recipes-devtools/qemu/files/fdt_header.patch b/recipes-
> devtools/qemu/files/fdt_header.patch
> new file mode 100644
> index 0000000..dccfe53
> --- /dev/null
> +++ b/recipes-devtools/qemu/files/fdt_header.patch
> @@ -0,0 +1,39 @@
> +Upstream-Status: Pending
> +
> +qemu: define fdt types in libfdt_env.h from qemu
> +
> +    * fixes
> +    In file included from /home/oe/setup-scripts/build/tmp-
> angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/libfdt.h:55:0,
> +                     from /home/oe/setup-scripts/build/tmp-
> angstrom_next-uclibc/work/x86_64-linux/qemu-native/1.4.0-r0/qemu-
> 1.4.0/hw/arm/../../device_tree.c:28:
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:58:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:59:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:60:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:61:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:62:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:63:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:64:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:67:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:70:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:73:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:77:2: error: unknown type
> name 'fdt64_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:78:2: error: unknown type
> name 'fdt64_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:82:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:87:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:88:2: error: unknown type
> name 'fdt32_t'
> +    /home/oe/setup-scripts/build/tmp-angstrom_next-
> uclibc/sysroots/x86_64-linux/usr/include/fdt.h:89:2: error: unknown type
> name 'fdt32_t'
> +
> +Index: qemu-1.4.0/include/libfdt_env.h
> +===================================================================
> +--- qemu-1.4.0.orig/include/libfdt_env.h	2013-02-15 23:05:35.000000000
> +0000
> ++++ qemu-1.4.0/include/libfdt_env.h	2013-04-13 14:17:27.918885225
> +0000
> +@@ -21,6 +21,10 @@
> +
> + #include "qemu/bswap.h"
> +
> ++typedef uint16_t fdt16_t;
> ++typedef uint32_t fdt32_t;
> ++typedef uint64_t fdt64_t;
> ++
> + #ifdef HOST_WORDS_BIGENDIAN
> + #define fdt32_to_cpu(x)  (x)
> + #define cpu_to_fdt32(x)  (x)
> diff --git a/recipes-devtools/qemu/qemu_fslgit.bb b/recipes-
> devtools/qemu/qemu_fslgit.bb
> index ac40fb5..e3bb276 100644
> --- a/recipes-devtools/qemu/qemu_fslgit.bb
> +++ b/recipes-devtools/qemu/qemu_fslgit.bb
> @@ -9,6 +9,8 @@ PV = "1.4+fsl"
>  SRC_URI = "git://git.freescale.com/ppc/sdk/qemu.git"
>  SRCREV = "8713c58725df407dbbedb48fa315248d0100720c"
> 
> +SRC_URI += "file://fdt_header.patch"
> +
>  S = "${WORKDIR}/git"
> 
>  QEMU_TARGETS = "ppc"
> --
> 1.7.3.4

Patch

diff --git a/recipes-devtools/qemu/files/fdt_header.patch b/recipes-devtools/qemu/files/fdt_header.patch
new file mode 100644
index 0000000..dccfe53
--- /dev/null
+++ b/recipes-devtools/qemu/files/fdt_header.patch
@@ -0,0 +1,39 @@ 
+Upstream-Status: Pending 
+
+qemu: define fdt types in libfdt_env.h from qemu
+    
+    * fixes
+    In file included from /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/libfdt.h:55:0,
+                     from /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/work/x86_64-linux/qemu-native/1.4.0-r0/qemu-1.4.0/hw/arm/../../device_tree.c:28:
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:58:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:59:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:60:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:61:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:62:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:63:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:64:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:67:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:70:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:73:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:77:2: error: unknown type name 'fdt64_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:78:2: error: unknown type name 'fdt64_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:82:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:87:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:88:2: error: unknown type name 'fdt32_t'
+    /home/oe/setup-scripts/build/tmp-angstrom_next-uclibc/sysroots/x86_64-linux/usr/include/fdt.h:89:2: error: unknown type name 'fdt32_t'
+
+Index: qemu-1.4.0/include/libfdt_env.h
+===================================================================
+--- qemu-1.4.0.orig/include/libfdt_env.h	2013-02-15 23:05:35.000000000 +0000
++++ qemu-1.4.0/include/libfdt_env.h	2013-04-13 14:17:27.918885225 +0000
+@@ -21,6 +21,10 @@
+ 
+ #include "qemu/bswap.h"
+ 
++typedef uint16_t fdt16_t;
++typedef uint32_t fdt32_t;
++typedef uint64_t fdt64_t;
++
+ #ifdef HOST_WORDS_BIGENDIAN
+ #define fdt32_to_cpu(x)  (x)
+ #define cpu_to_fdt32(x)  (x)
diff --git a/recipes-devtools/qemu/qemu_fslgit.bb b/recipes-devtools/qemu/qemu_fslgit.bb
index ac40fb5..e3bb276 100644
--- a/recipes-devtools/qemu/qemu_fslgit.bb
+++ b/recipes-devtools/qemu/qemu_fslgit.bb
@@ -9,6 +9,8 @@  PV = "1.4+fsl"
 SRC_URI = "git://git.freescale.com/ppc/sdk/qemu.git"
 SRCREV = "8713c58725df407dbbedb48fa315248d0100720c"
 
+SRC_URI += "file://fdt_header.patch"
+
 S = "${WORKDIR}/git"
 
 QEMU_TARGETS = "ppc"