From: Wes Chow <wes.chow@gmail.com>
To: barebox@lists.infradead.org
Subject: barebox state w/ qemu
Date: Sun, 7 Jul 2024 22:22:17 -0400 [thread overview]
Message-ID: <CAGWymk3LSCYpVDjYXs8NvdmkQeB+Bh22BJ7Sezm+hwuhUoSjFw@mail.gmail.com> (raw)
I am trying to better understand barebox and playing with it via
Buildroot with Qemu. One thing I don't understand is how the state
backend is configured. I see this:
https://github.com/barebox/barebox/blob/d74c84582591ac1f93b203d733831fcf18e6b033/common/boards/qemu-virt/qemu-virt-flash.dtso#L4
..however I don't know how to read dts overlay files. Do I need to set
up a disk with a partition scheme that matches lines 17-30? Or is it
sufficient to just have a partition with the "barebox-state" label?
Also possibly of relevance, I'm starting qemu like so:
qemu-system-aarch64 -m 2048M -cpu cortex-a57 -machine virt -display
none -serial mon:stdio -kernel output/images/barebox-dt-2nd.img
-device virtio-blk-pci,drive=hd0,disable-legacy=on -drive
file=output/images/rootfs.ext2,if=none,format=raw,id=hd0
The rootfs.ext2 disk becomes available to barebox as /dev/virtioblk0.
How does barebox know which disk to search for the backend?
In the target image, I installed dt-utils and so have access to the
barebox-state command. How does the barebox-state executable know
where to look for the state backend? Is this passed down through the
device tree?
Thanks,
Wes
next reply other threads:[~2024-07-08 2:23 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-08 2:22 Wes Chow [this message]
2024-07-08 6:49 ` Ahmad Fatoum
2024-07-09 2:13 ` Wes Chow
2024-07-09 9:16 ` Ahmad Fatoum
2024-07-11 11:47 ` Wes Chow
2024-07-12 22:35 ` Wes Chow
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAGWymk3LSCYpVDjYXs8NvdmkQeB+Bh22BJ7Sezm+hwuhUoSjFw@mail.gmail.com \
--to=wes.chow@gmail.com \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox