From: wuchi Date: Sat, 27 Aug 2022 07:11:16 +0000 (+0800) Subject: initramfs: mark my_inptr as __initdata X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=199cda13534f4c676d7e4601665e971f4f0582c4;p=linux.git initramfs: mark my_inptr as __initdata As my_inptr is only used in __init function unpack_to_rootfs(), mark it as __initdata to allow it be freed after boot. Link: https://lkml.kernel.org/r/20220827071116.83078-1-wuchi.zero@gmail.com Signed-off-by: wuchi Reviewed-by: David Disseldorp Cc: Alexander Viro Cc: Martin Wilck Cc: Matthew Wilcox Signed-off-by: Andrew Morton --- diff --git a/init/initramfs.c b/init/initramfs.c index 18229cfe8906b..2f5bfb7d76521 100644 --- a/init/initramfs.c +++ b/init/initramfs.c @@ -482,7 +482,7 @@ static long __init flush_buffer(void *bufv, unsigned long len) return origLen; } -static unsigned long my_inptr; /* index of next byte to be processed in inbuf */ +static unsigned long my_inptr __initdata; /* index of next byte to be processed in inbuf */ #include