Firefly Open Source Community

Title: How Dual Boot Works on Firefly RK3288 [Print This Page]

Author: sghazagh    Time: 7/25/2015 09:18
Title: How Dual Boot Works on Firefly RK3288
Can any one explain the way Dual Boot works on Firefly RK3288?
I assume the existing 'Linux app' or 'Android app' replaces the boot and kernel images to switch between Android and Linux OSs.
If this is the case, is there any source code for Android or Linux switching app to see how they swap the images to boot to other OS?

I compiled UBoot to be able to get into the U-Boot prompt.
It only works if I load Android and for Linux this option will be disabled as apparently the U-Boot image replaced at the time. So where is the U-Boot source or GIT for Linux?!

Where can I find the source of "bootrk" script used in 'bootcmd' command in UBoot to see what is does?!
Any help will be appreciated!

Thanks
Author: busybee    Time: 7/25/2015 10:46
The Android SDK has the u-boot direcotory which contains the full source code of U-Boot.

Author: busybee    Time: 7/25/2015 10:48
Some dual boot resource:

1. Dual boot on Firefly-RK3288
  http://bbs.t-firefly.com/forum.p ... &highlight=dual
2. Boot from SD card - dual boot either Android or Linux
  http://bbs.t-firefly.com/forum.p ... &highlight=dual
Author: sghazagh    Time: 7/26/2015 15:58
Thanks busybee,
It well explained so I understand the process now.

Just a quick question.
As 'linuxroot' is the Linux RootFS file system , the content of recovery partition is Linux Kernel (with or without initram), is that right?
So where we point to "parameter" partition appears as "/dev/blobk/mmcblk0p1" when we boot to Linux???
Is it hard-coded to device or the kernel does that?
Where we set this, if the kernel does?
Can you please explain?

Many thanks...



Author: busybee    Time: 7/27/2015 09:45
Last edited by busybee In 7/27/2015 09:46 Editor

The content of recovery partition is Linux Kernel with initramfs.

The parameter partition (flashed with parameter image, a wrapper for parameter file) contains the partition info,
which is loaded by U-Boot and passed to kernel as command line parameter.

You can see the kernel command line parameter by:
   $ cat /proc/cmdline

then the partition info within the command line is parsed and hence paritions are created.

Therefore, if you need to change the parition, just modify parameter file and flash it back to the storage.

Author: sghazagh    Time: 7/27/2015 10:29
busybee Posted at 7/27/2015 09:45
The content of recovery partition is Linux Kernel with initramfs.

The parameter partition (flashe ...

Fantastic mate,
You are the Guru and helped me a lot.
Now I am getting to know my Firefly device better and better...

Thanks again.




Welcome Firefly Open Source Community (https://bbs.t-firefly.com/) Powered by Discuz! X3.1