History

Merge tag 'bootconfig-fixes-v6.9-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace

Pull bootconfig fixes from Masami Hiramatsu: - Fix potential static_command_line buffer overrun. Currently we allocate the memory for static_command_line based on "boot_command_line", but it will copy "command_line" into it. So we use the length of "command_line" instead of "boot_command_line" (as we previously did) - Use memblock_free_late() in xbc_exit() instead of memblock_free() after the buddy system is initialized - Fix a kerneldoc warning * tag 'bootconfig-fixes-v6.9-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace: bootconfig: Fix the kerneldoc of _xbc_exit() bootconfig: use memblock_free_late to free xbc memory to buddy init/main.c: Fix potential static_command_line memory overflow

Linus Torvalds committed 2 years ago

Commit 9c6e84e2 parents dbe0a7b 298b8713 files · +21 −10Browse files

Showing the changes to include/linux (1 of 3 files). Show all

Unified · Split

include/linux/bootconfig.h+6−1
@@ -288,7 +288,12 @@ int __init xbc_init(const char *buf, size_t size, const char **emsg, int *epos); · 287 unmodified lines
288int __init xbc_get_info(int *node_size, size_t *data_size);288int __init xbc_get_info(int *node_size, size_t *data_size);
289 289
290/* XBC cleanup data structures */290/* XBC cleanup data structures */
291void __init xbc_exit(void);291void __init _xbc_exit(bool early);
292
293static inline void xbc_exit(void)
294{
295 _xbc_exit(false);
296}
292 297
293/* XBC embedded bootconfig data in kernel */298/* XBC embedded bootconfig data in kernel */
294#ifdef CONFIG_BOOT_CONFIG_EMBED299#ifdef CONFIG_BOOT_CONFIG_EMBED