mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2026-06-13 15:03:58 +03:00
dm: core: Provide ofnode_name_eq_unit() to accept a unit address
When a unit-address is provided, use it to match against the node name. Since this increases code size, put it into a separate function. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -394,6 +394,20 @@ void oftree_dispose(oftree tree);
|
||||
*/
|
||||
bool ofnode_name_eq(ofnode node, const char *name);
|
||||
|
||||
/**
|
||||
* ofnode_name_eq_unit() - Check a node name ignoring its unit address
|
||||
*
|
||||
* This is separate from ofnode_name_eq() to avoid code-size increase for
|
||||
* boards which don't need this function
|
||||
*
|
||||
* @node: valid node to compared, which may have a unit address
|
||||
* @name: name to compare with the node name. If this contains a unit
|
||||
* address, it is matched, otherwise the unit address is ignored
|
||||
* when searching for matches
|
||||
* Return: true if matches, false if it doesn't match
|
||||
*/
|
||||
bool ofnode_name_eq_unit(ofnode node, const char *name);
|
||||
|
||||
/**
|
||||
* ofnode_read_u8() - Read a 8-bit integer from a property
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user