Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] lego ev3 defconfig
@ 2016-10-15 12:15 Peter Korsgaard
  2016-10-15 13:16 ` Arnout Vandecappelle
  0 siblings, 1 reply; 6+ messages in thread
From: Peter Korsgaard @ 2016-10-15 12:15 UTC (permalink / raw)
  To: buildroot

Hi Vincent,

You added the lego_ev3_defconfig 2 years ago. Do you still have an ev3?

The defconfig is using gcc 4.7 with a note that the kernel doesn't boot
with 4.8 - But gcc 4.7 is deprecated and we are about to remove it, so
that isn't really good.

I see that there's a number of newer kernel version available on

https://github.com/ev3dev/ev3-kernel/releases

Could you perhaps test if one of these work with our default gcc (5.x)?
Thanks.

-- 
Bye, Peter Korsgaard

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

* [Buildroot] lego ev3 defconfig
  2016-10-15 12:15 [Buildroot] lego ev3 defconfig Peter Korsgaard
@ 2016-10-15 13:16 ` Arnout Vandecappelle
  2016-10-15 16:51   ` [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series Vincent Stehle
  0 siblings, 1 reply; 6+ messages in thread
From: Arnout Vandecappelle @ 2016-10-15 13:16 UTC (permalink / raw)
  To: buildroot



On 15-10-16 14:15, Peter Korsgaard wrote:
> Hi Vincent,
> 
> You added the lego_ev3_defconfig 2 years ago. Do you still have an ev3?
> 
> The defconfig is using gcc 4.7 with a note that the kernel doesn't boot
> with 4.8 - But gcc 4.7 is deprecated and we are about to remove it, so
> that isn't really good.
> 
> I see that there's a number of newer kernel version available on
> 
> https://github.com/ev3dev/ev3-kernel/releases
> 
> Could you perhaps test if one of these work with our default gcc (5.x)?
> Thanks.

 I've started on a defconfig but I didn't get around to finish it, and of course
I can't test it. Here it is:

# architecture
BR2_arm=y
BR2_arm926t=y

# system
BR2_TARGET_GENERIC_GETTY=y
BR2_TARGET_GENERIC_GETTY_PORT="ttyS1"

# Linux headers same as kernel, a 4.4 series
BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_4=y

# Kernel
BR2_LINUX_KERNEL=y
BR2_LINUX_KERNEL_CUSTOM_TARBALL=y
# v4.4.19-15-ev3dev-ev3_1
BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION="https://github.com/ev3dev/ev3-kernel/archive/5bae80fb82b77919712e16970dd4d04725e69eaa.tar.gz"
BR2_LINUX_KERNEL_DEFCONFIG="ev3dev"

# filesystem
BR2_TARGET_ROOTFS_EXT2=y
BR2_TARGET_ROOTFS_EXT2_3=y
# BR2_TARGET_ROOTFS_TAR is not set



 Regards,
 Arnout


-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

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

* [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series
  2016-10-15 13:16 ` Arnout Vandecappelle
@ 2016-10-15 16:51   ` Vincent Stehle
  2016-10-15 19:25     ` Arnout Vandecappelle
                       ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Vincent Stehle @ 2016-10-15 16:51 UTC (permalink / raw)
  To: buildroot

From: Vincent Stehl? <vincent.stehle@laposte.net>

Bump kernel revision used by lego_ev3_defconfig to the latest tag from
ev3dev, as suggested by Peter. This is a 4.4 series kernel, which has the
added benefit of not necessitating a specific gcc to boot.

We need a patch to create an empty drivers/lego/Kconfig file for the build
to succeed though, as the ev3dev kernel normally expects a drivers tree to
be checked out there.

Signed-off-by: Vincent Stehl? <vincent.stehle@laposte.net>
Suggested-by: Peter Korsgaard <peter@korsgaard.com>
---


Hi Peter,                                                                                                                                                                 
                                                                                                                                                                          
Thanks for the suggestion. Here is a patch to update lego_ev3_defconfig.                                                                                                  
This boots fine for me, with gcc 5.4.                                                                                                                                     
                                                                                                                                                                          
One remark though: the ev3dev project has a separate drivers tree managed                                                                                                 
as a git submodule of the kernel (!) I do not really know how to cope with                                                                                                
that properly, so I just added a patch to repair the build for the moment.                                                                                                
                                                                                                                                                                          
Do you know if it is possible for the `linux' recipe to have extra                                                                                                        
downloads like other packages do? But how would one extract the extra                                                                                                     
archives to the proper place then?                                                                                                                                        
  Maybe this calls for an additional `ev3 drivers' package after all, what                                                                                                
do you think?                                                                                                                                                             
                                                                                                                                                                          
Arnout I just saw your e-mail. Thanks for the config file, I double-checked                                                                                               
the one in this patch. If you don't mind I'd rather stay with a git tree                                                                                                  
(shallow cloned) rather than a tarball. Is that ok for you?                                                                                                               
                                                                                                                                                                          
Best regards,                                                                                                                                                             
                                                                                                                                                                          
Vincent.                                                                                                                                                                  


 .../0001-Create-empty-drivers-lego-Kconfig.patch   | 24 ++++++++++++++++++++++
 board/lego/ev3/readme.txt                          | 10 +++------
 configs/lego_ev3_defconfig                         | 14 ++++++-------
 3 files changed, 34 insertions(+), 14 deletions(-)
 create mode 100644 board/lego/ev3/patches/linux/0001-Create-empty-drivers-lego-Kconfig.patch

diff --git a/board/lego/ev3/patches/linux/0001-Create-empty-drivers-lego-Kconfig.patch b/board/lego/ev3/patches/linux/0001-Create-empty-drivers-lego-Kconfig.patch
new file mode 100644
index 0000000..614d53d
--- /dev/null
+++ b/board/lego/ev3/patches/linux/0001-Create-empty-drivers-lego-Kconfig.patch
@@ -0,0 +1,24 @@
+From 72c5727488f10160abfadcc77dd9763c4408b5e9 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Vincent=20Stehl=C3=A9?= <vincent.stehle@laposte.net>
+Date: Sat, 15 Oct 2016 16:23:31 +0200
+Subject: [PATCH] Create empty drivers/lego/Kconfig
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Signed-off-by: Vincent Stehl? <vincent.stehle@laposte.net>
+---
+ drivers/lego/Kconfig | 1 +
+ 1 file changed, 1 insertion(+)
+ create mode 100644 drivers/lego/Kconfig
+
+diff --git a/drivers/lego/Kconfig b/drivers/lego/Kconfig
+new file mode 100644
+index 0000000..d7cbf4f
+--- /dev/null
++++ b/drivers/lego/Kconfig
+@@ -0,0 +1 @@
++# Empty Kconfig just to make source from drivers/Kconfig succeed.
+-- 
+2.9.3
+
diff --git a/board/lego/ev3/readme.txt b/board/lego/ev3/readme.txt
index 3c0bd2e..7d9ec4f 100644
--- a/board/lego/ev3/readme.txt
+++ b/board/lego/ev3/readme.txt
@@ -16,11 +16,8 @@ See:
 
 The buildroot configuration uses the Linux kernel of the ev3dev project.
 See:
-- http://botbench.com/blog/2013/07/31/lego-mindstorms-ev3-source-code-available/
-- https://github.com/mindboards/ev3sources
-
-Note that the EV3 configuration uses gcc 4.7, as the boot is broken with gcc
-4.8.
+- https://github.com/ev3dev/ev3-kernel/
+- http://www.ev3dev.org/
 
 How it works
 ============
@@ -61,13 +58,12 @@ After building, you should obtain this tree:
     ??? rootfs.ext3 -> rootfs.ext2
     ??? uImage
 
-
 Prepare your SDcard
 ===================
 
 The following ?SD card layout is recommended:
 
-- First partition formated with a FAT filesystem, containing the uImage.
+- First partition formatted with a FAT filesystem, containing the uImage.
 - Second partition formatted as ext2 or ext3, containing the root filesystem.
 
 Create the SDcard partition table
diff --git a/configs/lego_ev3_defconfig b/configs/lego_ev3_defconfig
index d49fa06..1ddc4f9 100644
--- a/configs/lego_ev3_defconfig
+++ b/configs/lego_ev3_defconfig
@@ -2,23 +2,23 @@
 BR2_arm=y
 BR2_arm926t=y
 
-# toolchain
-# Use gcc 4.7, as gcc 4.8 breaks the boot.
-BR2_GCC_VERSION_4_7_X=y
+# patches
+BR2_GLOBAL_PATCH_DIR="board/lego/ev3/patches"
 
 # system
 BR2_TARGET_GENERIC_GETTY=y
 BR2_TARGET_GENERIC_GETTY_PORT="ttyS1"
 
-# Linux headers same as kernel, a 3.3 series
-BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_3_3=y
+# Linux headers same as kernel, a 4.4 series
+BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_4=y
 
 # Kernel
 BR2_LINUX_KERNEL=y
 BR2_LINUX_KERNEL_CUSTOM_GIT=y
-BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://github.com/mindboards/ev3dev-kernel.git"
-BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="v3.3.0-2-ev3dev_0"
+BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://github.com/ev3dev/ev3dev-kernel.git"
+BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="v4.4.19-15-ev3dev-ev3_1"
 BR2_LINUX_KERNEL_DEFCONFIG="ev3dev"
+BR2_LINUX_KERNEL_UIMAGE=y
 
 # filesystem
 BR2_TARGET_ROOTFS_EXT2=y
-- 
2.9.3

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

* [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series
  2016-10-15 16:51   ` [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series Vincent Stehle
@ 2016-10-15 19:25     ` Arnout Vandecappelle
  2016-10-15 20:59     ` Thomas Petazzoni
  2016-10-15 21:14     ` Peter Korsgaard
  2 siblings, 0 replies; 6+ messages in thread
From: Arnout Vandecappelle @ 2016-10-15 19:25 UTC (permalink / raw)
  To: buildroot



On 15-10-16 18:51, Vincent Stehle wrote:
> From: Vincent Stehl? <vincent.stehle@laposte.net>
> 
> Bump kernel revision used by lego_ev3_defconfig to the latest tag from
> ev3dev, as suggested by Peter. This is a 4.4 series kernel, which has the
> added benefit of not necessitating a specific gcc to boot.
> 
> We need a patch to create an empty drivers/lego/Kconfig file for the build
> to succeed though, as the ev3dev kernel normally expects a drivers tree to
> be checked out there.
> 
> Signed-off-by: Vincent Stehl? <vincent.stehle@laposte.net>
> Suggested-by: Peter Korsgaard <peter@korsgaard.com>

Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>

> ---
> 
> 
> Hi Peter,                                                                                                                                                                 
>                                                                                                                                                                           
> Thanks for the suggestion. Here is a patch to update lego_ev3_defconfig.                                                                                                  
> This boots fine for me, with gcc 5.4.                                                                                                                                     
>                                                                                                                                                                           
> One remark though: the ev3dev project has a separate drivers tree managed                                                                                                 
> as a git submodule of the kernel (!) I do not really know how to cope with                                                                                                
> that properly, so I just added a patch to repair the build for the moment.                                                                                                
>                                                                                                                                                                           
> Do you know if it is possible for the `linux' recipe to have extra                                                                                                        
> downloads like other packages do? But how would one extract the extra                                                                                                     
> archives to the proper place then?                                                                                                                                        
>   Maybe this calls for an additional `ev3 drivers' package after all, what                                                                                                
> do you think?                                                                                                                                                             
>                                                                                                                                                                           
> Arnout I just saw your e-mail. Thanks for the config file, I double-checked                                                                                               
> the one in this patch. If you don't mind I'd rather stay with a git tree                                                                                                  
> (shallow cloned) rather than a tarball. Is that ok for you?           

 Any reason why you prefer a git tree?

 Regards,
 Arnout


[snip]

-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

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

* [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series
  2016-10-15 16:51   ` [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series Vincent Stehle
  2016-10-15 19:25     ` Arnout Vandecappelle
@ 2016-10-15 20:59     ` Thomas Petazzoni
  2016-10-15 21:14     ` Peter Korsgaard
  2 siblings, 0 replies; 6+ messages in thread
From: Thomas Petazzoni @ 2016-10-15 20:59 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 15 Oct 2016 18:51:55 +0200, Vincent Stehle wrote:
> From: Vincent Stehl? <vincent.stehle@laposte.net>
> 
> Bump kernel revision used by lego_ev3_defconfig to the latest tag from
> ev3dev, as suggested by Peter. This is a 4.4 series kernel, which has the
> added benefit of not necessitating a specific gcc to boot.
> 
> We need a patch to create an empty drivers/lego/Kconfig file for the build
> to succeed though, as the ev3dev kernel normally expects a drivers tree to
> be checked out there.
> 
> Signed-off-by: Vincent Stehl? <vincent.stehle@laposte.net>
> Suggested-by: Peter Korsgaard <peter@korsgaard.com>

I've applied your patch to master, thanks!

One comment below, though.

>  Prepare your SDcard
>  ===================
>  
>  The following ?SD card layout is recommended:
>  
> -- First partition formated with a FAT filesystem, containing the uImage.
> +- First partition formatted with a FAT filesystem, containing the uImage.
>  - Second partition formatted as ext2 or ext3, containing the root filesystem.
>  
>  Create the SDcard partition table

It would be nice to use genimage here to automatically create a
complete SD card image.

Thanks,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

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

* [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series
  2016-10-15 16:51   ` [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series Vincent Stehle
  2016-10-15 19:25     ` Arnout Vandecappelle
  2016-10-15 20:59     ` Thomas Petazzoni
@ 2016-10-15 21:14     ` Peter Korsgaard
  2 siblings, 0 replies; 6+ messages in thread
From: Peter Korsgaard @ 2016-10-15 21:14 UTC (permalink / raw)
  To: buildroot

>>>>> "Vincent" == Vincent Stehle <vincent.stehle@laposte.net> writes:

Hi,

 > One remark though: the ev3dev project has a separate drivers tree
 > managed as a git submodule of the kernel (!) I do not really know how
 > to cope with that properly, so I just added a patch to repair the
 > build for the moment.

How important are those drivers?

We do actually support git submodules nowadays, but it has to be
explicitly enabled per package. I'm not sure we really want to
unconditionally enable it for the linux package so we would need to add
a Config.in option to enable it.

A nicer method might be to handle these drivers through our
linux-extensions support. Take a look at linux/linux-ext-fbtft.mk and
package/fbtft for an example of this.

--
Bye, Peter Korsgaard

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

end of thread, other threads:[~2016-10-15 21:14 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-15 12:15 [Buildroot] lego ev3 defconfig Peter Korsgaard
2016-10-15 13:16 ` Arnout Vandecappelle
2016-10-15 16:51   ` [Buildroot] [PATCH] configs/lego_ev3: bump kernel to 4.4 series Vincent Stehle
2016-10-15 19:25     ` Arnout Vandecappelle
2016-10-15 20:59     ` Thomas Petazzoni
2016-10-15 21:14     ` Peter Korsgaard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox