Skip to content

sys_dlist_t layout diverges from upstream (wrapped sentinel vs sentinel-as-node) #27

@swoisz

Description

@swoisz

Boreas wraps the dlist sentinel as struct _dlist { sys_dnode_t head } (sys/dlist.h); upstream Zephyr uses the sentinel-as-node trick (typedef struct _dnode sys_dlist_t). Ported code that pokes list->head or relies on (sys_dnode_t *)&list breaks silently.

Preferred fix: match upstream's layout (the k_work dlist rewrite, #24, benefits directly). Fallback: document the shape divergence in the header with a loud @note.

Related low-priority gaps, add as needed: sys_dlist_is_head, _is_tail, _has_multiple_nodes, _dequeue, _insert_at; sys_slist_append_list, _merge_slist, _insert, _get_not_empty, _find.

Metadata

Metadata

Assignees

No one assigned

    Labels

    zephyr-parityDivergence from upstream Zephyr API/semantics

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions