On Fri, Sep 05, 2025 at 10:32:24PM +0200, Daniel Kiper wrote:
> On Tue, Sep 02, 2025 at 02:45:56PM +0800, Michael Chang via Grub-devel wrote:
> > This patch series adds support for storing the GRUB environment block in
> > a reserved area of the Btrfs header. On copy on write filesystems such
> > as Btrfs, the normal file based envblk cannot be updated safely at
> > runtime because block addresses are not stable. The reserved area
> > provides a fixed location that GRUB can write directly, allowing
> > commands such as grub-reboot and savedefault to work on Btrfs volumes.
> >
> > The series proceeds in small chunks to keep each change buildable and
> > easier to review. The first patches add new data structures and helpers
> > for creating, opening, and writing an environment block in the reserved
> > area. Later patches update set_variables, unset_variables, and
> > list_variables so they can use the external block when it is present. An
> > entry is added to the Btrfs header to reserve space at 256 KiB for the
> > environment block. Finally, grub.cfg is modified so that load_env and
> > save_env use the external block automatically when env_block is defined.
> >
> > Michael Chang (8):
> >   util/grub-editenv: add basic structures and probe call for external
> >     envblk
> >   util/grub-editenv: add fs_envblk open helper
> >   util/grub-editenv: add fs_envblk write helper
> >   util/grub-editenv: wire set_variables to optional fs_envblk
> >   util/grub-editenv: wire unset_variables to optional fs_envblk
> >   util/grub-editenv: wire list_variables to optional fs_envblk
> >   btrfs: add environment block to reserved header area
> >   00_header.in: wire grub.cfg to use env_block when present
> 
> I have stopped reviewing the series at the patch #4. Some code requires
> clarification. Additionally, please add a description of the new feature
> to the GRUB documentation.

Thanks a lot for your time and effort in reviewing the patches. I will
add a section in the documentation to better describe the feature in the
next version.

Thanks,
Michael

> 
> Daniel

_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to