You've already forked documentation
mirror of
https://github.com/Dasharo/documentation.git
synced 2026-03-06 15:26:51 -08:00
This page is to provide basic GDB usage on QEMU target for better understanding SBL flow. - Prepare SBL QEMU image - Prepare GDB helper scripts - Launch QEMU target - Launch GDB - Transit Stage1A to Stage1B - Transit Stage1B to Stage2 - Transit Stage2 to OsLoader Signed-off-by: Aiden Park <aiden.park@intel.com>
51 lines
1.2 KiB
ReStructuredText
51 lines
1.2 KiB
ReStructuredText
.. _ExerciseBootToLinux:
|
|
|
|
Exercise \\- \ Boot to Linux
|
|
------------------------------
|
|
|
|
.. note::
|
|
**In this exercise, we'll learn how to boot to Linux.**
|
|
|
|
|
|
You can execute |SPN| with the following steps:
|
|
|
|
1. Working on Command Prompt Shell window
|
|
|
|
|
|
2. Rebuild |SPN| by using the following command::
|
|
|
|
python BuildLoader.py build qemu
|
|
|
|
3. Completion: you will see ``Done [qemu]`` on the screen after compile completed
|
|
|
|
4. Execute |SPN| on QEMU by using the following command:
|
|
|
|
- Windows::
|
|
|
|
"C:\Program Files\qemu\qemu-system-x86_64.exe" -m 256M -machine q35 -serial stdio -pflash Outputs\qemu\SlimBootloader.bin -drive id=mydisk,if=none,file=..\Misc\QemuImg\QemuSata.img,format=raw -device ide-hd,drive=mydisk -boot order=d
|
|
|
|
- Linux::
|
|
|
|
qemu-system-x86_64 -m 256M -machine q35 -serial mon:stdio -nographic -pflash Outputs/qemu/SlimBootloader.bin -drive id=mydisk,if=none,file=../Misc/QemuImg/QemuSata.img,format=raw -device ide-hd,drive=mydisk -boot order=d
|
|
|
|
|
|
|
|
|
|
.. image:: /images/ex4.jpg
|
|
:alt: Compile completed
|
|
:align: center
|
|
|
|
|
|
.. tip::
|
|
If run QEMU in Windows, Ctrl+Break to exit.
|
|
|
|
* The login to Linux, type::
|
|
|
|
root
|
|
|
|
* To shutdown Linux, type::
|
|
|
|
halt
|
|
|
|
|