mirror of
https://github.com/morgan9e/systemd
synced 2026-04-14 00:14:32 +09:00
boot: Add firmware_devicetree_exists()
This commit is contained in:
@@ -174,6 +174,10 @@ static const char* devicetree_get_compatible(const void *dtb) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
bool firmware_devicetree_exists(void) {
|
||||
return !!find_configuration_table(MAKE_GUID_PTR(EFI_DTB_TABLE));
|
||||
}
|
||||
|
||||
/* This function checks if the firmware provided Devicetree
|
||||
* and a UKI provided Devicetree contain the same first entry
|
||||
* on their respective "compatible" fields (which usually defines
|
||||
|
||||
@@ -30,6 +30,7 @@ typedef struct FdtHeader {
|
||||
uint32_t size_dt_struct;
|
||||
} FdtHeader;
|
||||
|
||||
bool firmware_devicetree_exists(void);
|
||||
EFI_STATUS devicetree_match(const void *uki_dtb, size_t uki_dtb_length);
|
||||
EFI_STATUS devicetree_match_by_compatible(const void *uki_dtb, size_t uki_dtb_length, const char *compat);
|
||||
EFI_STATUS devicetree_install(struct devicetree_state *state, EFI_FILE *root_dir, char16_t *name);
|
||||
|
||||
Reference in New Issue
Block a user