of: Provide default of_node_to_nid() implementation.
of_node_to_nid() is only relevant in a few architectures. Don't force everyone to implement it anyway. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
This commit is contained in:
@ -146,6 +146,11 @@ static inline unsigned long of_read_ulong(const __be32 *cell, int size)
|
||||
|
||||
#define OF_BAD_ADDR ((u64)-1)
|
||||
|
||||
#ifndef of_node_to_nid
|
||||
static inline int of_node_to_nid(struct device_node *np) { return -1; }
|
||||
#define of_node_to_nid of_node_to_nid
|
||||
#endif
|
||||
|
||||
extern struct device_node *of_find_node_by_name(struct device_node *from,
|
||||
const char *name);
|
||||
#define for_each_node_by_name(dn, name) \
|
||||
|
Reference in New Issue
Block a user