[PATCH v2 07/21] kallsyms: reimplement mksysmap in C

Markus Elfring Markus.Elfring at web.de
Mon Sep 14 09:33:42 PDT 2026


…
> +++ b/scripts/kallsyms-sysmap.c
> @@ -0,0 +1,269 @@
…
> +void sysmap_write(const struct sysmap *map, FILE *out)
> +{
> +	size_t i;
> +
> +	for (i = 0; i < map->nr_syms; i++) {
> +		const struct sysmap_symbol *s = &map->syms[i];
> +
> +		fprintf(out, "%0*llx %c %s\n", map->addr_width, s->addr, s->type,
> +			s->name);
> +	}
> +}
…

How do you think about to achieve more complete error detection?
https://cmu-sei.github.io/secure-coding-standards/sei-cert-c-coding-standard/rules/error-handling-err/err33-c/
https://cwe.mitre.org/data/definitions/252.html

Regards,
Markus



More information about the linux-riscv mailing list