Quoting Leonard Crestez (2019-04-22 01:26:56)
> This allows easily examining kernel hlists in python.
> 
> Signed-off-by: Leonard Crestez <[email protected]>

Reviewed-by: Stephen Boyd <[email protected]>

> +
> +
> +def hlist_for_each_entry(head, gdbtype, member):
> +    for node in hlist_for_each(head):
> +        if node.type != hlist_node.get_type().pointer():
> +            raise TypeError("Type {} found. Expected struct hlist_head *."

Maybe drop the full-stop? It looks weird to see struct list_head *.

> +                            .format(node.type))
> +        yield utils.container_of(node, gdbtype, member)
> +
> +

Reply via email to