mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 09:13:55 -06:00
hw/arm/fsl-imx8mp: Add USDHC storage controllers
The USDHC emulation allows for running real-world images such as those generated by Buildroot. Convert the board documentation accordingly instead of running a Linux kernel with ephemeral storage. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Bernhard Beschow <shentey@gmail.com> Message-id: 20250223114708.1780-8-shentey@gmail.com [PMM: drop 'static const' from usdhc_table[] for GCC 7.5] Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
487967bed6
commit
a81193c3e9
5 changed files with 66 additions and 6 deletions
|
@ -12,6 +12,7 @@ The ``imx8mp-evk`` machine implements the following devices:
|
|||
* Up to 4 Cortex-A53 cores
|
||||
* Generic Interrupt Controller (GICv3)
|
||||
* 4 UARTs
|
||||
* 3 USDHC Storage Controllers
|
||||
* Secure Non-Volatile Storage (SNVS) including an RTC
|
||||
* Clock Tree
|
||||
|
||||
|
@ -26,18 +27,23 @@ Direct Linux Kernel Boot
|
|||
|
||||
Probably the easiest way to get started with a whole Linux system on the machine
|
||||
is to generate an image with Buildroot. Version 2024.11.1 is tested at the time
|
||||
of writing and involves two steps. First run the following commands in the
|
||||
of writing and involves three steps. First run the following commands in the
|
||||
toplevel directory of the Buildroot source tree:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ echo "BR2_TARGET_ROOTFS_CPIO=y" >> configs/freescale_imx8mpevk_defconfig
|
||||
$ make freescale_imx8mpevk_defconfig
|
||||
$ make
|
||||
|
||||
Once finished successfully there is an ``output/image`` subfolder. Navigate into
|
||||
it and patch the device tree with the following commands which will remove the
|
||||
``cpu-idle-states`` properties from CPU nodes:
|
||||
it and resize the SD card image to a power of two:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ qemu-img resize sdcard.img 256M
|
||||
|
||||
Finally, the device tree needs to be patched with the following commands which
|
||||
will remove the ``cpu-idle-states`` properties from CPU nodes:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
|
@ -52,5 +58,5 @@ Now that everything is prepared the machine can be started as follows:
|
|||
-display none -serial null -serial stdio \
|
||||
-kernel Image \
|
||||
-dtb imx8mp-evk-patched.dtb \
|
||||
-initrd rootfs.cpio \
|
||||
-append "root=/dev/ram"
|
||||
-append "root=/dev/mmcblk2p2" \
|
||||
-drive file=sdcard.img,if=sd,bus=2,format=raw,id=mmcblk2
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue