Lines Matching +full:qemu +full:- +full:system +full:-

4 QEMU for PPC supports a special ``ppce500`` machine designed for emulation and
8 -----------------
19 * Power-off functionality via one GPIO pin
26 ----------------------------------
29 which it passes to the guest, if there is no ``-dtb`` option. This provides
31 the various devices in the system.
33 If users want to provide their own DTB, they can use the ``-dtb`` option.
36 * The number of subnodes under /cpus node should match QEMU's ``-smp`` option
37 * The /memory reg size should match QEMU’s selected ram_size via ``-m``
39 Both ``qemu-system-ppc`` and ``qemu-system-ppc64`` provide emulation for the
40 following 32-bit PowerPC CPUs:
45 Additionally ``qemu-system-ppc64`` provides support for the following 64-bit
51 The CPU type can be specified via the ``-cpu`` command line. If not specified,
55 .. code-block:: bash
57 $ qemu-system-ppc64 -nographic -M ppce500 -cpu e6500
60 ------------
62 The ``ppce500`` machine can start using the standard -kernel functionality
63 for loading a payload like an OS kernel (e.g.: Linux), or U-Boot firmware.
65 When -bios is omitted, the default pc-bios/u-boot.e500 firmware image is used
66 as the BIOS. QEMU follows below truth table to select which payload to execute:
69 -bios -kernel payload
71 N N u-boot
73 Y don't care u-boot
76 When both -bios and -kernel are present, QEMU loads U-Boot and U-Boot in turns
77 automatically loads the kernel image specified by the -kernel parameter via
78 U-Boot's built-in "bootm" command, hence a legacy uImage format is required in
82 --------------------
86 64-bit mode, simply configure the kernel using the defconfig configuration:
88 .. code-block:: bash
91 $ export CROSS_COMPILE=powerpc-linux-
97 Platform support > Freescale Book-E Machine Type > QEMU generic e500 platform
99 To boot the newly built Linux kernel in QEMU with the ``ppce500`` machine:
101 .. code-block:: bash
103 $ qemu-system-ppc64 -M ppce500 -cpu e5500 -smp 4 -m 2G \
104 -display none -serial stdio \
105 -kernel vmlinux \
106 -initrd /path/to/rootfs.cpio \
107 -append "root=/dev/ram"
110 in 32-bit mode, use the same 64-bit configuration steps except the defconfig
113 To boot the 32-bit Linux kernel:
115 .. code-block:: bash
117 $ qemu-system-ppc64 -M ppce500 -cpu e500mc -smp 4 -m 2G \
118 -display none -serial stdio \
119 -kernel vmlinux \
120 -initrd /path/to/rootfs.cpio \
121 -append "root=/dev/ram"
123 Running U-Boot
124 --------------
126 U-Boot mainline v2021.07 release is tested at the time of writing. To build a
127 U-Boot mainline bootloader that can be booted by the ``ppce500`` machine, use
128 the qemu-ppce500_defconfig with similar commands as described above for Linux:
130 .. code-block:: bash
132 $ export CROSS_COMPILE=powerpc-linux-
133 $ make qemu-ppce500_defconfig
135 You will get u-boot file in the build tree.
137 When U-Boot boots, you will notice the following if using with ``-cpu e6500``:
139 .. code-block:: none
144 This is because we only specified a core name to QEMU and it does not have a
146 You can specify a real world SoC device that QEMU has built-in support but all
151 ----------
156 .. code-block:: bash
158 $ qemu-system-ppc64 -M ppce500 -smp 4 -m 2G \
159 -display none -serial stdio \
160 -bios u-boot \
161 -nic tap,ifname=tap0,script=no,downscript=no,model=e1000
163 The QEMU ``ppce500`` machine can also dynamically instantiate an eTSEC device
164 if “-device eTSEC” is given to QEMU:
166 .. code-block:: bash
168 -netdev tap,ifname=tap0,script=no,downscript=no,id=net0 -device eTSEC,netdev=net0
170 Root file system on flash drive
171 -------------------------------
173 Rather than using a root file system on ram disk, it is possible to have it on
177 .. code-block:: bash
179 $ qemu-system-ppc64 -M ppce500 -cpu e500mc -smp 4 -m 2G \
180 -display none -serial stdio \
181 -kernel vmlinux \
182 -drive if=pflash,file=/path/to/rootfs.ext2,format=raw \
183 -append "rootwait root=/dev/mtdblock0"
185 Alternatively, the root file system can also reside on an emulated SD card
188 .. code-block:: bash
190 $ qemu-system-ppc64 -M ppce500 -cpu e500mc -smp 4 -m 2G \
191 -display none -serial stdio \
192 -kernel vmlinux \
193 -device sd-card,drive=mydrive \
194 -drive id=mydrive,if=none,file=/path/to/rootfs.ext2,format=raw \
195 -append "rootwait root=/dev/mmcblk0"