All of lore.kernel.org
 help / color / mirror / Atom feed
* How can I create a truly minimal distribution that runs entirely from RAM?
@ 2021-03-10 23:32 p32
  2021-03-11  5:03 ` [yocto] " Zoran
  0 siblings, 1 reply; 11+ messages in thread
From: p32 @ 2021-03-10 23:32 UTC (permalink / raw)
  To: yocto

[-- Attachment #1: Type: text/plain, Size: 1904 bytes --]

Hello everyone,

I am currently using this ( https://source.codeaurora.org/external/imx/imx-manifest/tree/imx-5.4.3-2.0.0.xml?h=imx-linux-zeus ) Yocto-based build setup provided by NXP to create a custom Linux distribution for one of the i.MX boards. My custom image is based on the core-image-minimal recipe and works fine, i.e., runs on the platform as expected. However, I have to following two issues:

Although core-image-minimal is documented as "A small image just capable of allowing a device to boot", I can tell from the running system that it contains a huge number of components that I think are not be strictly necessary to boot the device. For instance, the boot log contains entries about an FPGA manager framework, Bluetooth, Ethernet, KVM, USB, and a lot of i.MX-specific modules such as for DMA or power management. For evaluation purposes, I want to get rid of all of these and end up with a *truly* minimal Linux system that is able to boot, schedule its tasks, and to communicate via UART. How can I achieve this without losing the i.MX support, i.e., the generation of a bootloader and suitable device tree files?

Furthermore, I would like the minimal system to run entirely from RAM. More specifically: After being started from the SD card, U-Boot should start the Linux distribution via initramfs. I am able to generate some kind of initramfs binary using the following changes:
# local.conf
INITRAMFS_IMAGE = "recipe-name"
INITRAMFS_IMAGE_BUNDLE = "1"
# recipe-name.bb
IMAGE_FSTYPES = "${INITRAMFS_FSTYPES}"
PACKAGE_INSTALL = "${IMAGE_INSTALL}"

However, this does not affect the generated U-Boot, which means that U-Boot still tries to boot from an SD card partition. What is the "right way" to make use of the Image-initramfs-board.bin or the image-board.cpio.gz files that Yocto creates in this case?

Any help yould be greatly appreciated.

Kind regards!

[-- Attachment #2: Type: text/html, Size: 2238 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2021-03-15 19:59 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-10 23:32 How can I create a truly minimal distribution that runs entirely from RAM? p32
2021-03-11  5:03 ` [yocto] " Zoran
2021-03-12 21:49   ` p32
2021-03-13  7:28     ` [yocto] " Zoran
2021-03-14 23:16       ` p32
2021-03-15 16:01         ` [yocto] " Zoran
2021-03-15 17:21           ` Nicolas Dechesne
2021-03-15 18:10             ` Zoran
     [not found]           ` <CAAnfSTv6a9qUZi6-o2r-t1ucNAnn52HcAsNKbpfMz9vUez01sQ@mail.gmail.com>
2021-03-15 18:00             ` Zoran
2021-03-15 19:58           ` Richard Purdie
2021-03-15 19:59         ` Joshua Watt

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.