Skip to main content
Lead
August 18, 2024
Solved

How do I create bootfs, vendorfs, userfs and rootfs files?

  • August 18, 2024
  • 1 reply
  • 1895 views

I have compiled.

  • Optee
  • TF-A
  • U-boot
  • Linux

And it seems to work well. I have also tried to implement a pre-made OpenSTLinux from the Source files. And it seems to work well too. I haven't got any terminal up and running. I can only see the display output of messages when I start it up.

Notice that the kernel comes from STM32MP157 and before the kernel startup, it's from STM32MP151. That's why you see that the MAC address is not set, but once linux kernel is started, you can see inside the log that the MAC address is set to "56:bf:8f:58:f8:31".

https://pastebin.com/QTV4qbHr

I need to create bootfs, vendorfs, userfs and rootfs.ext4, so what should I do next? Should I create empty .ext4 files and then mount the .ext4 files and later fill them with...?

 

 

Best answer by Erwan SZYMANSKI

Hello @DMårt ,
You can use different strategy to setup you File System partitions. 

1) The cleanest one
As it is done for OpenSTLinux, you can choose to use Yocto to generate your entire image, including BSP with your own software component (your own version of the Kernel, U-boot, OP-TEE ...) and designing yourself the content of your bootfs, rootfs .. The 4 partitions are created by ST files/rules provided in Yocto directly.

2) The simplest one
As you said you already have all your components built, you can take an example Starter Package from ST, replacing all the components by your own ones, keeping only the bootfs, rootfs, vendorfs and userfs intact. Then, once mounted, you can tune them for your purposes. 

Kind regards,
Erwan.

1 reply

Erwan SZYMANSKI
Erwan SZYMANSKIBest answer
Technical Moderator
August 19, 2024

Hello @DMårt ,
You can use different strategy to setup you File System partitions. 

1) The cleanest one
As it is done for OpenSTLinux, you can choose to use Yocto to generate your entire image, including BSP with your own software component (your own version of the Kernel, U-boot, OP-TEE ...) and designing yourself the content of your bootfs, rootfs .. The 4 partitions are created by ST files/rules provided in Yocto directly.

2) The simplest one
As you said you already have all your components built, you can take an example Starter Package from ST, replacing all the components by your own ones, keeping only the bootfs, rootfs, vendorfs and userfs intact. Then, once mounted, you can tune them for your purposes. 

Kind regards,
Erwan.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
DMårtAuthor
Lead
August 19, 2024

@Erwan SZYMANSKI 

Then I know that I need to use a third party software to build the Linux distro, Meanwhile STM32CubeIDE is only used for (in MP case) compile tf-a, u-boot, Linux kernel and OP-tee.

 

Thank you. That clarifies much.

STM32MP151AAC3 custom board with STM32-OS as operating system: https://github.com/DanielMartensson/STM32-ComputerSTM32MP257FAK3 custom board with STM64-OS as operating system: https://github.com/DanielMartensson/STM64-Computer