summaryrefslogtreecommitdiff
path: root/scripts/gendwarfksyms/cache.c
AgeCommit message (Collapse)Author
2025-07-26gendwarfksyms: use preferred form of sizeof for allocationGiuliano Procida
The preferred form is to use the variable being allocated to, rather than explicitly supplying a type name which might become stale. Also do this for memset. Suggested-by: Masahiro Yamada <masahiroy@kernel.org> Signed-off-by: Giuliano Procida <gprocida@google.com> Reviewed-by: Sami Tolvanen <samitolvanen@google.com> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2025-01-11gendwarfksyms: Limit structure expansionSami Tolvanen
Expand each structure type only once per exported symbol. This is necessary to support self-referential structures, which would otherwise result in infinite recursion, and it's sufficient for catching ABI changes. Types defined in .c files are opaque to external users and thus cannot affect the ABI. Consider type definitions in .c files to be declarations to prevent opaque types from changing symbol versions. Signed-off-by: Sami Tolvanen <samitolvanen@google.com> Reviewed-by: Petr Pavlu <petr.pavlu@suse.com> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>