On Mon Oct 21, 2024 at 5:16 PM CEST, Pascal Hambourg wrote:
> On 21/10/2024 at 10:26, Diederik de Haas wrote:
> > On Sun Oct 20, 2024 at 8:49 PM CEST, Pascal Hambourg wrote:
> >> On 20/10/2024 at 16:28, Diederik de Haas wrote:
> >>>
> >>> ```
> >>> root@cs21:~# parted -s /dev/mmcblk1 print
> >>> Model: MMC NCard (sd/mmc)
> >>> Disk /dev/mmcblk1: 61.9GB
> >>> Sector size (logical/physical): 512B/512B
> >>> Partition Table: gpt
> >>> Disk Flags:
> >>>
> >>> Number  Start   End     Size    File system  Name     Flags
> >>>    1      32.8kB  16.8MB  16.7MB               primary
> >>>    2      16.8MB  256MB   239MB   fat16        primary  boot, esp
> >>>    3      256MB   61.9GB  61.6GB  ext4         primary
> >>>
> >>> root@cs21:~# lsblk -o +PARTFLAGS,FSTYPE /dev/mmcblk1
> >>> NAME        MAJ:MIN RM  SIZE RO TYPE MOUNTPOINTS PARTFLAGS FSTYPE
> >>> mmcblk1     179:0    0 57.6G  0 disk
> >>> ├─mmcblk1p1 179:1    0   16M  0 part
> >>> ├─mmcblk1p2 179:2    0  228M  0 part /boot/efi             vfat
> >>> └─mmcblk1p3 179:3    0 57.4G  0 part /                     ext4
> >>> ```
> >>
> >> Partition 2 looks like a regular EFI partition mounted on /boot/efi as
> >> expected by GRUB. With a size of 239MB it should be FAT32 instead of
> >> FAT16, but maybe the UEFI firmware expects only FAT16 or does not care.
> > 
> >>> So it looks like it just needs some indication (flag) of what the boot
> >>> device is, but it doesn't (seem to) matter which one.
> >>
> >> Weird. Does it have to be on the boot/root partition or can it be on any
> >> other partition ?
> > 
> > It appears to not matter if it's 'boot' or 'legacy_boot', but it (ofc?)
> > needs to be set on the partition with the kernel as that needs to be
> > started for the rest of the boot process.
>
> But in cs21's partition table, the boot/esp flag is on the EFI 
> partition, not the root partition. Does it mean that the kernel is 
> installed in the EFI partition instead of the root partition ? Or is the 
> "kernel" a secondary EFI boot loader such as GRUB ?

Good point, my use of 'kernel' was inaccurate.

After u-boot does its thing, it handles control over to 'something'
which continues the boot process.
In most of my cases that is the kernel, but on cs21 I _think_ that it
indeed handles things over to GRUB which then starts the requested
system/kernel.
On cs21 I do have `grub-efi-arm64` installed, but I don't know much
about EFI things, but it works so I had no reason to change it.

Cheers,
  Diederik

Attachment: signature.asc
Description: PGP signature

Reply via email to