* [Buildroot] [PATCH] uclibc: patch 0.9.31 for avr32, to add __kernel_long_t and __kernel_ulong_t data types
@ 2013-11-15 8:59 spdawson at gmail.com
2013-11-15 9:03 ` Thomas De Schampheleire
0 siblings, 1 reply; 5+ messages in thread
From: spdawson at gmail.com @ 2013-11-15 8:59 UTC (permalink / raw)
To: buildroot
From: Simon Dawson <spdawson@gmail.com>
As reported by Thomas Petazzoni, the uclibc 0.9.31 build fails for avr32:
In file included from /opt/br-avr32-full-2013.11-rc1/usr/avr32-buildroot-linux-uclibc/sysroot/usr/include/linux/kernel.h:4,
from /opt/br-avr32-full-2013.11-rc1/usr/avr32-buildroot-linux-uclibc/sysroot/usr/include/linux/netlink.h:4,
from /opt/br-avr32-full-2013.11-rc1/usr/avr32-buildroot-linux-uclibc/sysroot/usr/include/linux/rtnetlink.h:5,
from libc/inet/netlinkaccess.h:27,
from libc/inet/if_index.c:36:
/opt/br-avr32-full-2013.11-rc1/usr/avr32-buildroot-linux-uclibc/sysroot/usr/include/linux/sysinfo.h:8: error: expected specifier-qualifier-list before '__kernel_long_t'
make[1]: *** [libc/inet/if_index.os] Error 1
make[1]: Leaving directory `/opt/toolchain-build/build/uclibc-0.9.31.1'
The problem is reported at:
https://lkml.org/lkml/2013/5/18/1
The offending kernel commit is:
http://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/?id=ccdfcc398594
The fix is to patch uclibc 0.9.31 to add the missing kernel data types. The patch
will only be generated for avr32, since uclibc 0.9.31 is not available in Buildroot
for any other architecture.
Signed-off-by: Simon Dawson <spdawson@gmail.com>
---
...add-__kernel_long-and-__kernel_ulong.patch.avr32 | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)
create mode 100644 package/uclibc/0.9.31.1/uclibc-0013-libc-sysdeps-add-__kernel_long-and-__kernel_ulong.patch.avr32
diff --git a/package/uclibc/0.9.31.1/uclibc-0013-libc-sysdeps-add-__kernel_long-and-__kernel_ulong.patch.avr32 b/package/uclibc/0.9.31.1/uclibc-0013-libc-sysdeps-add-__kernel_long-and-__kernel_ulong.patch.avr32
new file mode 100644
index 0000000..55cb0c5
--- /dev/null
+++ b/package/uclibc/0.9.31.1/uclibc-0013-libc-sysdeps-add-__kernel_long-and-__kernel_ulong.patch.avr32
@@ -0,0 +1,21 @@
+libc/sysdeps: add __kernel_long and __kernel_ulong
+
+Linux 3.4 added __kernel_long_t and __kernel_ulong_t and various
+exported header files were updated to use these new types. Add the
+definitions for __kernel_long_t and __kernel_ulong_t to the relevant
+kernel_types.h headers.
+
+Signed-off-by: Simon Dawson <spdawson@gmail.com>
+
+diff -Nurp a/libc/sysdeps/linux/avr32/bits/kernel_types.h b/libc/sysdeps/linux/avr32/bits/kernel_types.h
+--- a/libc/sysdeps/linux/avr32/bits/kernel_types.h 2011-06-08 19:58:40.000000000 +0100
++++ b/libc/sysdeps/linux/avr32/bits/kernel_types.h 2013-11-15 08:01:09.209037851 +0000
+@@ -39,6 +39,8 @@ typedef unsigned int __kernel_gid32_t;
+ typedef unsigned short __kernel_old_uid_t;
+ typedef unsigned short __kernel_old_gid_t;
+ typedef unsigned short __kernel_old_dev_t;
++typedef long __kernel_long_t;
++typedef unsigned long __kernel_ulong_t;
+
+ #ifdef __GNUC__
+ typedef long long __kernel_loff_t;
--
1.8.3.2
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] uclibc: patch 0.9.31 for avr32, to add __kernel_long_t and __kernel_ulong_t data types
2013-11-15 8:59 [Buildroot] [PATCH] uclibc: patch 0.9.31 for avr32, to add __kernel_long_t and __kernel_ulong_t data types spdawson at gmail.com
@ 2013-11-15 9:03 ` Thomas De Schampheleire
2013-11-15 9:23 ` Thomas Petazzoni
0 siblings, 1 reply; 5+ messages in thread
From: Thomas De Schampheleire @ 2013-11-15 9:03 UTC (permalink / raw)
To: buildroot
Hi Simon,
On Fri, Nov 15, 2013 at 9:59 AM, <spdawson@gmail.com> wrote:
> From: Simon Dawson <spdawson@gmail.com>
>
> As reported by Thomas Petazzoni, the uclibc 0.9.31 build fails for avr32:
>
> In file included from /opt/br-avr32-full-2013.11-rc1/usr/avr32-buildroot-linux-uclibc/sysroot/usr/include/linux/kernel.h:4,
> from /opt/br-avr32-full-2013.11-rc1/usr/avr32-buildroot-linux-uclibc/sysroot/usr/include/linux/netlink.h:4,
> from /opt/br-avr32-full-2013.11-rc1/usr/avr32-buildroot-linux-uclibc/sysroot/usr/include/linux/rtnetlink.h:5,
> from libc/inet/netlinkaccess.h:27,
> from libc/inet/if_index.c:36:
> /opt/br-avr32-full-2013.11-rc1/usr/avr32-buildroot-linux-uclibc/sysroot/usr/include/linux/sysinfo.h:8: error: expected specifier-qualifier-list before '__kernel_long_t'
> make[1]: *** [libc/inet/if_index.os] Error 1
> make[1]: Leaving directory `/opt/toolchain-build/build/uclibc-0.9.31.1'
>
> The problem is reported at:
>
> https://lkml.org/lkml/2013/5/18/1
>
> The offending kernel commit is:
>
> http://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/?id=ccdfcc398594
>
> The fix is to patch uclibc 0.9.31 to add the missing kernel data types. The patch
> will only be generated for avr32, since uclibc 0.9.31 is not available in Buildroot
> for any other architecture.
>
> Signed-off-by: Simon Dawson <spdawson@gmail.com>
> ---
> ...add-__kernel_long-and-__kernel_ulong.patch.avr32 | 21 +++++++++++++++++++++
> 1 file changed, 21 insertions(+)
> create mode 100644 package/uclibc/0.9.31.1/uclibc-0013-libc-sysdeps-add-__kernel_long-and-__kernel_ulong.patch.avr32
A few buildroot developer days ago, we said we'd like to get rid of
architecture-specific patching. IIRC avr32 was the only architecture
having such patches. Is it possible to make such patches 'common' in
the sense that they are always named .patch and thus applied for all
architectures?
If the contents should really only be applied to avr32, is it a
possibility to use some #ifdef inside the patch?
Thanks,
Thomas
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] uclibc: patch 0.9.31 for avr32, to add __kernel_long_t and __kernel_ulong_t data types
2013-11-15 9:03 ` Thomas De Schampheleire
@ 2013-11-15 9:23 ` Thomas Petazzoni
2013-11-15 9:34 ` Simon Dawson
0 siblings, 1 reply; 5+ messages in thread
From: Thomas Petazzoni @ 2013-11-15 9:23 UTC (permalink / raw)
To: buildroot
Dear Thomas De Schampheleire,
On Fri, 15 Nov 2013 10:03:44 +0100, Thomas De Schampheleire wrote:
> A few buildroot developer days ago, we said we'd like to get rid of
> architecture-specific patching. IIRC avr32 was the only architecture
> having such patches. Is it possible to make such patches 'common' in
> the sense that they are always named .patch and thus applied for all
> architectures?
> If the contents should really only be applied to avr32, is it a
> possibility to use some #ifdef inside the patch?
In the specific case of this patch, it modifies only avr32-specific
header files, so I don't quite see why it needs to be
named .patch.avr32 instead of just .patch.
Especially since anyway 0.9.31 can only be enabled for the AVR32
architecture.
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] uclibc: patch 0.9.31 for avr32, to add __kernel_long_t and __kernel_ulong_t data types
2013-11-15 9:23 ` Thomas Petazzoni
@ 2013-11-15 9:34 ` Simon Dawson
2013-11-15 9:42 ` Thomas De Schampheleire
0 siblings, 1 reply; 5+ messages in thread
From: Simon Dawson @ 2013-11-15 9:34 UTC (permalink / raw)
To: buildroot
Hi Thomases.
On 15 November 2013 09:23, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> In the specific case of this patch, it modifies only avr32-specific
> header files, so I don't quite see why it needs to be
> named .patch.avr32 instead of just .patch.
>
> Especially since anyway 0.9.31 can only be enabled for the AVR32
> architecture.
I'll rename the patch, and resubmit. As for the other *.patch.avr32
files, I'll have a look at them as soon as I can.
Simon.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] uclibc: patch 0.9.31 for avr32, to add __kernel_long_t and __kernel_ulong_t data types
2013-11-15 9:34 ` Simon Dawson
@ 2013-11-15 9:42 ` Thomas De Schampheleire
0 siblings, 0 replies; 5+ messages in thread
From: Thomas De Schampheleire @ 2013-11-15 9:42 UTC (permalink / raw)
To: buildroot
Hi Simon,
On Fri, Nov 15, 2013 at 10:34 AM, Simon Dawson <spdawson@gmail.com> wrote:
> Hi Thomases.
>
> On 15 November 2013 09:23, Thomas Petazzoni
> <thomas.petazzoni@free-electrons.com> wrote:
>> In the specific case of this patch, it modifies only avr32-specific
>> header files, so I don't quite see why it needs to be
>> named .patch.avr32 instead of just .patch.
>>
>> Especially since anyway 0.9.31 can only be enabled for the AVR32
>> architecture.
>
> I'll rename the patch, and resubmit. As for the other *.patch.avr32
> files, I'll have a look at them as soon as I can.
That would be great, thanks!
Best regards,
Thomas
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2013-11-15 9:42 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-11-15 8:59 [Buildroot] [PATCH] uclibc: patch 0.9.31 for avr32, to add __kernel_long_t and __kernel_ulong_t data types spdawson at gmail.com
2013-11-15 9:03 ` Thomas De Schampheleire
2013-11-15 9:23 ` Thomas Petazzoni
2013-11-15 9:34 ` Simon Dawson
2013-11-15 9:42 ` Thomas De Schampheleire
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox