MCPcopy Create free account
hub / github.com/CloverHackyColor/CloverBootloader / DTGetProperty

Function DTGetProperty

Library/DeviceTreeLib/DeviceTreeLib.c:362–388  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

360}
361
362EFI_STATUS
363DTGetProperty(
364 IN CONST DTEntry Entry,
365 IN CHAR8 *PropertyName,
366 IN VOID **PropertyValue,
367 IN UINT32 *PropertySize
368 )
369{
370 DTProperty *Prop;
371 UINT32 Count;
372
373 if (Entry == NULL || Entry->NumProperties == 0) {
374 return EFI_INVALID_PARAMETER;
375 }
376
377 Prop = (DTProperty *) (Entry + 1);
378 for (Count = 0; Count < Entry->NumProperties; Count++) {
379 if (AsciiStrCmp(Prop->Name, PropertyName) == 0) {
380 *PropertyValue = (VOID *) (((UINT8 *)Prop) + sizeof (DTProperty));
381 *PropertySize = Prop->Length;
382 return EFI_SUCCESS;
383 }
384 Prop = DEVICE_TREE_GET_NEXT_PROPERTY (Prop);
385 }
386
387 return EFI_INVALID_PARAMETER;
388}
389
390EFI_STATUS
391DTCreatePropertyIterator (

Callers 4

FindChildFunction · 0.70
HideSlideFromOsFunction · 0.50

Calls 1

AsciiStrCmpFunction · 0.85

Tested by

no test coverage detected