3 Commits
Author SHA1 Message Date
Silke Hofstra 74dd4636e4 Add support for non-ext filesystems
Calling stat() on some filesystems, like Btrfs,
results in a dev_t with no relation to the backing device(s),
and subsequent failure to detect the root fs.

Add support such filesystems by retrieving the block device from
`/proc/self/mounts` and working on from there.

Resolves #61, #182 and #193.
2020-07-04 17:08:01 +02:00
Leandro Dorileo 486486e19a bootman: improve filesystem detection
Improve the internal filesystem detection, with these changes we
can reuse this code elsewhere and be more efficient - other areas
needing the filesystem knowledge can use this mapping strategies
adding a more precise and centralized code to that.

This patch also makes sure to keep tests and filesystem checks more
consistent.

When mounting we were assuming the /boot filesystem to always be
vfat, with this code now we can have /boot partitions with whatever
filesystem we support (for now: vfat, ext[2-4]).

Signed-off-by: Leandro Dorileo <leandro.maciel.dorileo@intel.com>
2019-09-17 15:08:18 -07:00
Auke Kok c730d3e509 Statically add mbr.bin and gptmbr.bin.
We should not rely on these being present on the filesystem and
the space we use is minimal. On top of that, we need at a later stage
dynamically choose gpt or non-gpt MBR blocks depending on the device,
so we need both available no matter what.

Punch a hole so the bootloader can easily get the wanted_boot_mask
and decide whether the GPT or non-GPT mbr.bin is needed.
2019-09-05 16:33:56 -07:00