Hello all,

Often when I analyze linux source code, it takes me some time to figure out
how a list_head member of a struct is being used.
Sometimes it points to a linked list's start member, but sometimes it used
to link the containing struct as a member of linked list.(you know we cat
get the struct in the linked list using container_of operator). Wouldn't it
be nice if we give list_head an alias like 'list_hook_head' (or just
list_hook) so that the alias can be used for the second case? By gradually
changing the type name to list_hook_head in some structs, we could make the
source code more easier to read. I hope someone do this someday..
Thank you.

Chan Kim






_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

Reply via email to