Discussion

Easiest way to compile 3.17/3.19 kernel

87 16754
Hello,

I have been busy for the last 2 weeks to get a kernel for the banana pi working with the latest hid-multitouch support(supported in 3.17 and later).
I am having very much trouble with this.
I have used the wiki a bilion times but every time I compile the kernels with 3.17 or 3.19 I get a lib folder that points to the source or with to less drivers in it.
Can anyone point me to a GOOD linux source for 3.17 or 3.19 with instructions?
I only need to rebuild the kernel.
As extra question, the LOADADDR parameter should be 0x40008000 right?

Kind regards,
igorpec  
Edited by igorpec at Mon May 4, 2015 11:59

http://www.youtube.com/watch?v=TE5XDovsCOo

I created a movie of compilation. Real time, some narration and on-screen info. Quickly made, full length (30min).

It might be useful as a reference.

Edited by Mr_Blonde at Tue Feb 17, 2015 03:22

I used one of Igor's 3.19.0_RC5 images. Downloaded the 3.19.0 release kernel and took the old configuration from Igor as a starting point (the config is under /boot). Then I used menuconfig to modify the config.

Afterwards I used:
  1. make uImage LOADADDR=0x46000000
  2. cp arch/arm/boot/zImage /boot/zImage
  3. make modules modules_install
  4. nano /boot/boot-next.cmd (to modify the kernel name vmlinuz-3.19.0-rc5-bananapi to zImage)
  5. mkimage -C none -A arm -T script -d boot-next.cmd boot.scr
  6. reboot
Copy the Code
This worked perfectly for me.

you have good tutorials about kernel build on Gentoo (google "gentoo kernel") but obviously nothing dedicated to the Banana.

I saw 3.19 knows BananaPI but I duno how to build the dts from it (I didn't searched yet anyway )

Edited by Mr_Blonde at Tue Feb 17, 2015 09:12
destroyedlolo replied at Tue Feb 17, 2015 06:50 I saw 3.19 knows BananaPI but I duno how to build the dts from it (I didn't searched yet anyway )
  1. cd kernel_src_folder
  2. make sun7i-a20-bananapi.dts
Copy the Code
That should do the trick...


BTW: Here is the DTS file for the Banana Pro.

The recommended way according to the linux-sunxi wiki is to compile a zImage rather than the uImage. In this case you also won't need to specify the LOADADDR anymore. @Mr_Blonde: You're instructions are odd. You make a uImage but copy the zImage....

Anyway it's quite simple to build the mainline kernel and dtb with the standard configuration:
  1. cd ?PATH_OF_YOUR_KERNEL_SOURCE?
  2. make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- sunxi_defconfig
  3. ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make zImage dtbs
Copy the Code
(Assuming you cross compile on another machine and the compiler directory is in your PATH variable.)

For further details, e.g. enabling module support, how to cofigure the boot.cmd, I'd recommend to look at the linux-suxi wiki:
http://linux-sunxi.org/Mainline_Kernel_Howto

Thanks for helping!
So normally I would use the modules and modules_install commands
I never worked with dbt.
How does that work with installing these?

Mr_Blonde replied at Tue Feb 17, 2015 03:20
I used one of Igor's 3.19.0_RC5 images. Downloaded the 3.19.0 release kernel and took the old config ...

That's a smart idea I think! Thanks for the help!

Mr_Blonde replied at Tue Feb 17, 2015 03:20
I used one of Igor's 3.19.0_RC5 images. Downloaded the 3.19.0 release kernel and took the old config ...

Where did you get the linux-kernel though?

Edited by destroyedlolo at Wed Feb 18, 2015 23:38
Mr_Blonde replied at Tue Feb 17, 2015 16:11
That should do the trick...


Cool, thanks for the tips.

And any blob to load or the bundle from kernel.org is enough ? i.e GMAC and LCD framebuffer ?
As per http://linux-sunxi.org/Mainline_Kernel_Howto, it is not the case, right ?

jorricks replied at Wed Feb 18, 2015 11:31
Where did you get the linux-kernel though?

I got the most recent one from kernel.org and compiled it.

You have to log in before you can reply Login | Sign Up

Points Rules