[PATCH 0/2] fs: fat: Implement FAT file rename

Tom Rini trini at konsulko.com
Thu Dec 12 23:14:27 CET 2024


On Thu, Dec 12, 2024 at 11:06:27PM +0100, Burak Gerz wrote:

> Hello
> This patch series is a first implementation for file renaming on a FAT
> filesystems. This implementation does a file rename only (no moving
> between directories) as needed by bootloaders like systemd-boot [1].
> 
> The renaming process is tried to be made as fail-safe as possible, by
>   1. Writing the new, empty file
>   2. Copying the address of the start cluster into new directory entry
>   3. Deleting old file
> This can decay in the worst case to a hard link
> 
> Additionally, make use of the FAT file rename in /lib/efi_loader
> 
> [1] https://www.freedesktop.org/software/systemd/man/latest/systemd-boot.html#Boot%20Counting

This is useful, thanks! Can you please extend the existing tests in 
test/py/tests/test_fs/ to cover this as well?

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20241212/9c7924d3/attachment.sig>


More information about the U-Boot mailing list