New APIs: findfs_partuuid and findfs_partlabel

These search for partitions by UUID or label (name).  They only work
for GPT.
This commit is contained in:
Richard W.M. Jones
2024-07-08 14:37:22 +01:00
parent 4c5c0782af
commit 1816651f3c
4 changed files with 31 additions and 1 deletions

View File

@@ -27,6 +27,10 @@ let rec findfs_uuid uuid =
findfs "UUID" uuid
and findfs_label label =
findfs "LABEL" label
and findfs_partuuid uuid =
findfs "PARTUUID" uuid
and findfs_partlabel label =
findfs "PARTLABEL" label
and findfs tag str =
(* Kill the cache file, forcing blkid to reread values from the