+ Reply to Thread
Results 1 to 20 of 60
[HowTo] build / boot a linux kernel on M8
This is a discussion on [HowTo] build / boot a linux kernel on M8 within the Meizu M8 Android forums, part of the M8 Firmware category; HowTo Booting a Linux Kernel on Meizu M8 First and important notice: It never happend to anyone (till now) but ...
-
10-19-2009 #1Senior Member
- Join Date
- Sep 2009
- Posts
- 380
- Thanks
- 3
Thanked 138 Times in 53 Posts[HowTo] build / boot a linux kernel on M8
HowTo Booting a Linux Kernel on Meizu M8
First and important notice:
It never happend to anyone (till now) but it may be that the procedure of flashing
an unsupported OS to your phone may brick it. This means: Send to china to get it fixed or buy a new one.
Even if you follow this instructions i will take no responsibility for whatever you do. I wil take no responsibility
if this instructions are complete or right. There could be errors in this text or i could have fergotten something.
If anything unexpected happens, i would incourage you to ask in the forums.
1) Basic
I use windows and Linux in a VMWare. This guide assumes that you have this too.
This is my way. It may differ from the way banxian uses.
Lines with '>' mean you need to input something
To boot a Linux Kernel on the M8 with the existing eboot bootloader the following things are needed:
This is what u need to get
-M8 (bet you knew this one)
-Basic programming skills would be nice
-C/C++ compiler for the LinuxStarter (at this time i think only Visual Studio works)
-basic knowledge on Linux / Kernel compiling
-Working Serial Debug cable
[How-To] Serial debug connection
This is what you can download
-TerraTerm (you can use any terminal) (Tera Term Home Page)
-WinHex (WinHex: Computerforensik & Datenrettung, Hex-Editor & Disk-Editor)
-M8 Pack (Lite XIP Builder) (Browse ReJacker Files on SourceForge.net)
-Linux/Windows ARM Crosscompiler (ftp://jhkim.kr/mirror/aesop/4.3.2-eabi-arm.tar.gz)
-Kernelsources (http://rapidshare.de/files/48548408/...ource.rar.html)(these are mine. They are already patched to support the lcd display)
-Linuxstarter Sources (RapidShare Webhosting + Webspace)
-Kernel config (http://members.lycos.nl/phunbringer/.config)
-SMDK6410 (http://just4you.springnote.com/pages...hments/1176828)
Install enviroment
Windows Stuff
Download and extract Winhex (the testversion will do)
Install Visual Studio
_WITH SUPPORT FOR INTELLIGENT DEVICES_ this is to be selected in setup in the
custom installation dialog
Install SMDK6410
(be sure to deselect documentation because there is no doc)
Extract the sources of LinuxStarter to somewhere on your PC open it and try to compile (F7)
Linux Stuff
Things you should have installed on you linux system:
ncurses
gcc
--Cross compiler
The crosscompiler compiles arm binaries under an x86 enviroment.
Download the package and extract it to you linux machine.
>cd /opt
>gunzip 4.3.2-eabi-arm.tar.gz
>tar xf 4.3.2-eabi-arm.tar
Now add the bin path to you PATH
>PATH=$PATH:/opt/4.3.2-eabi-arm/bin
--kernel sources
From this sources the kernel is build
>cd /opt
>unrar aesop-kernel-source
>tar xf aesop-kernel-source
>cp .config aesop-kernel-source/
Roughly these are the steps you go:
-Configure a Linux Kernel
-Compile it
-Copy Image to LinuxStarter
-Compile it
-Create a XIP file from it
-Flash it
I will now try to explain each step.
Configure a Linux kernel
Configuring a linux kernel means to select drivers and setup values before a kernel is compiled
It then gets compiled the way you selected it. With or without the drivers you selected.
>cd /opt
>cd aesop-kernel-source
>make menuconfig
.. configure your kernel ..
(you should disable the rootfs i left it accidently)
Compile a linux kernel
after menuconfig you going to compile that beast
>cd /opt
>cd aesop-kernel-source
>make ARCH=arm CROSS_COMPILE=arm-generic-linux-gnueabi- zImage
.. this could take a while ..
If finished withour serious errors your kernel will be in
>opt/aesop-kernel-source/arch/arm/boot and is called zImage
Copy Image to LinuxStarter and Compile it
>Open LinuxStarter Project in Visual Studio
Your kernel is here
>opt/KernelSource/arch/arm/boot and is called zImage
Get it out of your VM the way you like. (USB Stick Network Shares folder etc)
Open it in winHex
>Select Edit/Copy All/C Source
The kernel will be copied as C Array into your clipboard
>Open the file TheKernel.c in Visual Studio
>Clear it (crtl+a then del)
>Copy the new kernel into the file (ctrl+v)
>Go to the top of the file and rename the array from data to KernelData
>Save it
>Compile it (F7)
You should get a LinuxStarter.exe roughly from the size of the zImage
==EDIT
to dump the kernel in the right header file format right unter linux u can use this script
rm ./dump
touch ./dump
echo "unsigned char data[] = {" > ./dump
hexdump -v -e '1/1 "0x%02x, "' -e '"\n"' arch/arm/boot/zImage >> ./dump
echo "};" >> ./dump
==EDIT
rename dump to TheKernel.h
Build a minimal XIP File from it
Now we need to pack this exe ito a XIP file for booting the phone with it
>Start M8Pack
>Select Toold/Lite XIP Builder
_IMPORTANT_ in this dialog you can configure how the XIP file is programmed to your flash.
It is recommended to NOT experiment with this settings unsell you know what you do.
Flashing a XIP file with overriden and wrong Load oder Base Adress will most likely kill the phone
>Browse for the LinuxStarter.exe
>Set the baseAdress in the baseAdress fiel to 0x80100000
>Press the Build Now Button
>A XIP.bin file will be created which can be flashed to the phone
Flash it to the phone
>Do a backup of you data on the phone
>Power off the phone
>Press Power On + Music Button until the Phone starts to upgrade mode
>Copy the generated XIP.bin to the device anf flash it
>Connect your serial cable
>start a terminal and select your SerialPort with 112500,8n1 settings.
>Power on the phone
>Little blue and green 'I' will report the progress of the LinuxLoader
>A bright green 'I' in the first display line indicates that the control has gone to the kernel
>You should see the Kernel booting on you serial Console.Last edited by r3wDy; 02-02-2010 at 09:27 PM.
-
2 members have thanked r3wDy:
-
10-19-2009 #2Senior Member
- Join Date
- Sep 2009
- Posts
- 380
- Thanks
- 3
Thanked 138 Times in 53 PostsAdress to kernel sources will come later im still uploading....
-- added link to the kernel source
Any questions/remarks about this topic please in here.
Thx
Last edited by r3wDy; 10-19-2009 at 06:50 PM.
-
10-19-2009 #3Valued Member
- Join Date
- Aug 2008
- Location
- Belgium
- Posts
- 2,434
- Thanks
- 127
Thanked 189 Times in 130 PostsThanks!
I would use this BSP for windows CE 6.
Cause the one from springnotes does not always seems to work/install correctly ;-)Last edited by evow04; 10-19-2009 at 07:04 PM. Reason: laptop battery died while posting :s
-
10-19-2009 #4Member
- Join Date
- Nov 2006
- Posts
- 101
- Thanks
- 0
Thanked 8 Times in 7 PostsThis is insane. ;-)
-
10-19-2009 #5Member
- Join Date
- Apr 2009
- Location
- Italy
- Posts
- 255
- Thanks
- 12
Thanked 10 Times in 7 PostsWow, I actually will not "play" with the m8, but, guys you really are doing a great work!!
-
11-09-2009 #6Freshman
- Join Date
- Oct 2009
- Posts
- 32
- Thanks
- 0
Thanked 12 Times in 6 Posts@r3wDy
in your topic:[HowTo] build / boot a linux kernel on M8
I want to download -Linuxstarter Sources (RapidShare Webhosting + Webspace), but it has been deleted now.
Where I can download it now?
-
11-09-2009 #7Senior Member
- Join Date
- Sep 2009
- Posts
- 380
- Thanks
- 3
Thanked 138 Times in 53 Postsi will upload it again.
but you could use banxians tinyloader which should do the same (but better)
-
11-09-2009 #8Valued Member
- Join Date
- Aug 2008
- Location
- Belgium
- Posts
- 2,434
- Thanks
- 127
Thanked 189 Times in 130 Postsr3wdy,
maybe you could edit your first post with information how to do it with banxian´s tinyloader and Mpack tool?
-
11-11-2009 #9Senior Member
- Join Date
- Sep 2009
- Posts
- 380
- Thanks
- 3
Thanked 138 Times in 53 Postsi would but i never did it and so i dont know how to do it :P just used my linuxloader everytime ^^
-
11-11-2009 #10Valued Member
- Join Date
- Aug 2008
- Location
- Belgium
- Posts
- 2,434
- Thanks
- 127
Thanked 189 Times in 130 Postslol , maybe you could try to add it to the wiki as singlebootloader? :D
some people might be interested i think :D
-
11-23-2009 #11Passing By
- Join Date
- Nov 2009
- Posts
- 2
- Thanks
- 0
Thanked 1 Time in 1 Posthttp://opensource.samsungmobile.com/...OpenSource.zipro.product.model=GT-I5700
ro.product.brand=sec
ro.product.name=GT-I5700
ro.product.device=spica
ro.product.board=
ro.product.manufacturer=Samsung
ro.product.locale.language=en
ro.product.locale.region=GB
ro.board.platform=s3c6410
-
Member who thanked hobbit19 for the post:
-
11-23-2009 #12Valued Member
- Join Date
- Aug 2008
- Location
- Belgium
- Posts
- 2,434
- Thanks
- 127
Thanked 189 Times in 130 Postscool!
i did not know that the samsung Galaxi lite/Spica had the same soc?!
S3C6410 Supported Now !
Supported CPU
• S3C6410
JTAG Operation Features :
• Read Boot
• Write Boot
• Erase Boot
• Above Features Helps you to repair phones as well as read and write options
S3C6410 Devices :
• Acer DX650
• Acer M900 / Tempo M900
• Acer Tempo F900
• Acer Tempo X960
• Samsung GT-B7300 OmniaLITE (Samsung Buckingham)
• Samsung GT-B7610 OmniaPRO (Samsung Louvre)
• Samsung GT-B7620 Giorgio Armani
• Samsung GT-i8000 Omnia II 16GB
• Samsung GT-i8000 Omnia II 2GB
• Samsung GT-i8000 Omnia II 8GB
• Samsung GT-i8000L Omnia II
• Samsung Moment
• Samsung SCH-i920 Omnia II 8GB
Usage :
• Connect to JTAG Connection
• Power on phone ( even though it does not power on )
• Start Software
• Select the Flash type of Phone
• Select good dump
( if it does not exist in support area – you should read from a good phone )
• Write to Damaged Phone
After all the procedures completed S3C6410 part should be repaired
And just make sure to flash with original firmware after all to complete repair procedures.
Announcement:
As soon as we get JTAG Pinouts will be uploaded to support section (Support)
Support Update:
OMAP 2430 Section
• G810 JTAG Pinouts corrected
• I450 JTAG Pinouts added
• G810 Dump is added
Note :
• if you have difficulties of using or problem please contact to support through webpage or via e-mail !
THAT’S not Enough ? Do not worry !
WE HAVE MORE AND MORE NEWS !
Best Regards
www.omnia-repair.com
New Model is supported
NEW Model with S3C6410 CPU
• Samsung GT-i5700 Galaxy Lite / Spica
Best Regards
Omnia Repair ? Tool for ProfessionalsLast edited by evow04; 11-23-2009 at 10:18 AM.
-
01-01-2010 #13Passing By
- Join Date
- Nov 2009
- Posts
- 2
- Thanks
- 0
Thanked 1 Time in 1 Posthttp://www.mt-system.ru/documents/li..._28.part01.rar
http://www.mt-system.ru/documents/li..._28.part02.rar
http://www.mt-system.ru/documents/li..._28.part03.rar
http://www.mt-system.ru/documents/li..._28.part04.rar
http://www.mt-system.ru/documents/li..._28.part05.rar
http://www.mt-system.ru/documents/li..._28.part06.rar
http://www.mt-system.ru/documents/li..._28.part07.rar
http://www.mt-system.ru/documents/li..._28.part08.rar
Linux_S3C6410_v2.6.28+eabi+OpenGLES+u-boot
-
01-01-2010 #14Valued Member
- Join Date
- Aug 2008
- Location
- Belgium
- Posts
- 2,434
- Thanks
- 127
Thanked 189 Times in 130 Postshi hobbit19,
thanks for sharing, but could you explain what the links do contain?
is this an original or modified 2.6.28 kernel or..?
btw here is a git 2.6.32 from 14/12/09 with s3c6410 support
-
02-02-2010 #15Member
- Join Date
- Nov 2006
- Posts
- 101
- Thanks
- 0
Thanked 8 Times in 7 PostsLooks like the information in the 1st post is out-dated. I'd like to be try compiling my own kernel and see if it works. So what's the latest kernel source that's working? Also where can I find a working toolchain?
Last edited by lang2; 02-02-2010 at 08:58 PM.
-
02-02-2010 #16
this runs linux on the m8? so you can run apps? er wht?
-
02-02-2010 #17Senior Member
- Join Date
- Sep 2009
- Posts
- 380
- Thanks
- 3
Thanked 138 Times in 53 PostsYes the post is a little outdated.
The sourcen for the working kernel can now be found in the android wiki (there should be links)
my linuxloader is sure deleted on rapidshare but i still work nearly everyday with it (even if the m8 dosnt work with me grml) so i can upload them somehwhere.
be sure to use the kernel from bill (2.6.27) as its the only one which works right now
PS
Yes, it does a complete linux kernel and android. Just the hardware is not completly supported with drivers. See android threadthis runs linux on the m8? so you can run apps? er wht?
-
02-02-2010 #18Member
- Join Date
- Nov 2006
- Posts
- 101
- Thanks
- 0
Thanked 8 Times in 7 Posts
OK on your wiki there are two links for source code (M8 Software - MDROID WIKI). One is from Aesop which is 29. banxian's git does have linux-27-bill-m8 but I wasn't able to compile it with the following error:linux-27-bill-m8/scripts/gen_initramfs_list.sh: Cannot open '/opt/work/initramfs.cpio'I'm using arm-non-linux-gnueabi but I don't think that's the problem.
-
02-03-2010 #19Senior Member
- Join Date
- Sep 2009
- Posts
- 380
- Thanks
- 3
Thanked 138 Times in 53 Postsyou must disable the use of initial ramdisk. or provide one.
For me, i use Ubuntu as a host and have my rootfs mounted via nfs so i can easyly modify it.
Thats somewhere in menuconfig unter booting or kernel options or sth.
-
02-03-2010 #20Member
- Join Date
- Nov 2006
- Posts
- 101
- Thanks
- 0
Thanked 8 Times in 7 PostsOK. Managed to compile the kernel after turning off initramfs. However, some changes were still needed: the number of samsung serial port wasn't configured. Either I'm dumb or something wrong with the tree.
Similar Threads
-
M6 SP won't boot after dissemble.
By MeiVincible in forum TechnicalReplies: 8Last Post: 07-26-2009, 09:28 PM -
Internet Explorer (Build 2000)
By sten in forum M8 ApplicationsReplies: 5Last Post: 06-21-2009, 08:04 AM -
Meizu wont boot
By Lazlo2k5 in forum General Meizu M6Replies: 8Last Post: 12-09-2008, 06:44 AM -
how i build skin?
By A2x in forum Modifications and SkinsReplies: 1Last Post: 07-31-2007, 11:00 PM -
Boot images
By Kiruat in forum General Meizu M6Replies: 8Last Post: 12-30-2006, 02:01 PM



Reply With Quote
