* [PATCH] libfdt: Fix C++ compile-time cast error on gnu 4.2.1
@ 2009-03-03 13:23 Laurent Gregoire
[not found] ` <1236086639.17001.428.camel-AlTa8cHOufjkPJRI6LV1/EZjUo8kaGiB@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Laurent Gregoire @ 2009-03-03 13:23 UTC (permalink / raw)
To: David Gibson; +Cc: devicetree-discuss
Allow the inclusion of libfdt.h in C++ source.
---
Signed-off-by: Laurent Gregoire <laurent.gregoire-Jdzig1fPfSTQT0dZR+AlfA@public.gmane.org>
---
diff -uprN a/libfdt/libfdt.h b/libfdt/libfdt.h
--- a/libfdt/libfdt.h 2008-07-25 23:17:04.000000000 +0200
+++ b/libfdt/libfdt.h 2009-03-03 14:01:38.000000000 +0100
@@ -156,7 +156,7 @@ int fdt_next_node(const void *fdt, int o
#define __fdt_set_hdr(name) \
static inline void fdt_set_##name(void *fdt, uint32_t val) \
{ \
- struct fdt_header *fdth = fdt; \
+ struct fdt_header *fdth = (struct fdt_header*)fdt; \
fdth->name = cpu_to_fdt32(val); \
}
__fdt_set_hdr(magic);
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] libfdt: Fix C++ compile-time cast error on gnu 4.2.1
[not found] ` <1236086639.17001.428.camel-AlTa8cHOufjkPJRI6LV1/EZjUo8kaGiB@public.gmane.org>
@ 2009-03-04 1:05 ` David Gibson
2009-03-04 14:13 ` Jon Loeliger
1 sibling, 0 replies; 3+ messages in thread
From: David Gibson @ 2009-03-04 1:05 UTC (permalink / raw)
To: Laurent Gregoire; +Cc: devicetree-discuss
On Tue, Mar 03, 2009 at 02:23:59PM +0100, Laurent Gregoire wrote:
> Allow the inclusion of libfdt.h in C++ source.
> ---
> Signed-off-by: Laurent Gregoire <laurent.gregoire-Jdzig1fPfSTQT0dZR+AlfA@public.gmane.org>
Acked-by: David Gibson <david-xT8FGy+AXnRB3Ne2BGzF6laj5H9X9Tb+@public.gmane.org>
> ---
> diff -uprN a/libfdt/libfdt.h b/libfdt/libfdt.h
> --- a/libfdt/libfdt.h 2008-07-25 23:17:04.000000000 +0200
> +++ b/libfdt/libfdt.h 2009-03-03 14:01:38.000000000 +0100
> @@ -156,7 +156,7 @@ int fdt_next_node(const void *fdt, int o
> #define __fdt_set_hdr(name) \
> static inline void fdt_set_##name(void *fdt, uint32_t val) \
> { \
> - struct fdt_header *fdth = fdt; \
> + struct fdt_header *fdth = (struct fdt_header*)fdt; \
> fdth->name = cpu_to_fdt32(val); \
> }
> __fdt_set_hdr(magic);
>
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] libfdt: Fix C++ compile-time cast error on gnu 4.2.1
[not found] ` <1236086639.17001.428.camel-AlTa8cHOufjkPJRI6LV1/EZjUo8kaGiB@public.gmane.org>
2009-03-04 1:05 ` David Gibson
@ 2009-03-04 14:13 ` Jon Loeliger
1 sibling, 0 replies; 3+ messages in thread
From: Jon Loeliger @ 2009-03-04 14:13 UTC (permalink / raw)
To: Laurent Gregoire; +Cc: devicetree-discuss
> Allow the inclusion of libfdt.h in C++ source.
> ---
> Signed-off-by: Laurent Gregoire <laurent.gregoire-Jdzig1fPfSTQT0dZR+AlfA@public.gmane.org>
> ---
Applied.
jdl
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2009-03-04 14:13 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-03 13:23 [PATCH] libfdt: Fix C++ compile-time cast error on gnu 4.2.1 Laurent Gregoire
[not found] ` <1236086639.17001.428.camel-AlTa8cHOufjkPJRI6LV1/EZjUo8kaGiB@public.gmane.org>
2009-03-04 1:05 ` David Gibson
2009-03-04 14:13 ` Jon Loeliger
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.