[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Minios-devel] [UNIKRAFT PATCH RFC 07/23] plat/ofw: Export fdt_find_irq_parent_offset
This changes fdt_find_irq_parent_offset from static to extern for pci ecam to use. Signed-off-by: Jia He <justin.he@xxxxxxx> --- lib/fdt/exportsyms.uk | 1 + plat/drivers/include/ofw/fdt.h | 21 +++++++++++++++++++++ plat/drivers/ofw/fdt.c | 2 +- 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a/lib/fdt/exportsyms.uk b/lib/fdt/exportsyms.uk index d64d9dc1..a2e9ea80 100644 --- a/lib/fdt/exportsyms.uk +++ b/lib/fdt/exportsyms.uk @@ -61,3 +61,4 @@ fdt_stringlist_contains fdt_resize fdt_overlay_apply fdt_getprop_u32_by_offset +fdt_find_irq_parent_offset \ No newline at end of file diff --git a/plat/drivers/include/ofw/fdt.h b/plat/drivers/include/ofw/fdt.h index 6f80a27d..8826845a 100644 --- a/plat/drivers/include/ofw/fdt.h +++ b/plat/drivers/include/ofw/fdt.h @@ -37,6 +37,27 @@ #define FDT_BAD_ADDR (uint64_t)(-1) +/** + * fdt_find_irq_parent_offset - find the irq parent offset + * @fdt: pointer to the device tree blob + * @phandle: phandle value + * + * fdt_node_offset_by_phandle() returns the offset of the node + * which has the given phandle value. If there is more than one node + * in the tree with the given phandle (an invalid tree), results are + * undefined. + * + * returns: + * structure block offset of the located node (>= 0), on success + * -FDT_ERR_NOTFOUND, no node with that phandle exists + * -FDT_ERR_BADPHANDLE, given phandle value was invalid (0 or -1) + * -FDT_ERR_BADMAGIC, + * -FDT_ERR_BADVERSION, + * -FDT_ERR_BADSTATE, + * -FDT_ERR_BADSTRUCTURE, standard meanings + */ +int fdt_find_irq_parent_offset(const void *fdt, int offset); + /** * fdt_interrupt_cells - retrieve the number of cells needed to encode an * interrupt source diff --git a/plat/drivers/ofw/fdt.c b/plat/drivers/ofw/fdt.c index 76f8ff3a..c0973311 100644 --- a/plat/drivers/ofw/fdt.c +++ b/plat/drivers/ofw/fdt.c @@ -44,7 +44,7 @@ #define FDT_CHECK_COUNTS(na, ns) ((na) > 0 && (na) <= FDT_MAX_ADDR_CELLS && \ (ns) > 0) -static int fdt_find_irq_parent_offset(const void *fdt, int offset) +int fdt_find_irq_parent_offset(const void *fdt, int offset) { uint32_t irq_parent; -- 2.17.1 _______________________________________________ Minios-devel mailing list Minios-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/minios-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |