B Horn 16f196874f kern/file: Implement filesystem reference counting
The grub_file_open() and grub_file_close() should be the only places
that allow a reference to a filesystem to stay open. So, add grub_dl_t
to grub_fs_t and set this in the GRUB_MOD_INIT() for each filesystem to
avoid issues when filesystems forget to do it themselves or do not track
their own references, e.g. squash4.

The fs_label(), fs_uuid(), fs_mtime() and fs_read() should all ref and
unref in the same function but it is essentially redundant in GRUB
single threaded model.

Signed-off-by: B Horn <b@horn.uk>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
2025-01-23 16:22:47 +01:00
..
2024-10-11 14:35:54 +02:00
2022-03-14 15:46:55 +01:00
2022-03-14 15:46:55 +01:00
2020-07-29 16:55:47 +02:00
2023-05-25 16:48:00 +02:00
2022-03-14 15:46:55 +01:00
2024-10-31 16:07:03 +01:00
2012-02-26 22:49:24 +01:00
2023-11-08 05:04:24 +01:00
2022-03-14 15:46:55 +01:00
2010-05-06 11:34:04 +05:30