lkml.org 
[lkml]   [2017]   [May]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: initramfs: Always do fput() and load modules after rootfs populate
On Sat, May 06, 2017 at 12:02:32AM -0700, Andrei Vagin wrote:
> Hi,
>
> I see the following error with this patch:
>
> init/initramfs.c: In function 'populate_rootfs':
> init/initramfs.c:644:2: error: label at end of compound statement
> done:
> ^
> scripts/Makefile.build:294: recipe for target 'init/initramfs.o' failed
> make[1]: *** [init/initramfs.o] Error 1

Ahh, I didnt notice this and none of the build robots reported to us.
Sorry about it, the above patch is already merged, so this is not good, Ill
get this fixed.

Could you give me some info on your compiler?

> probably we need something like this:
> diff --git a/init/initramfs.c b/init/initramfs.c
> index 3a68715..9966c0f 100644
> --- a/init/initramfs.c
> +++ b/init/initramfs.c
> @@ -641,7 +641,6 @@ static int __init populate_rootfs(void)
> sys_close(fd);
> free_initrd();
> }
> - done:
> #else
> printk(KERN_INFO "Unpacking initramfs...\n");
> err = unpack_to_rootfs((char *)initrd_start,
> @@ -651,6 +650,7 @@ static int __init populate_rootfs(void)
> free_initrd();
> #endif
> }
> +done:
> flush_delayed_fput();
> /*
> * Try loading default modules from initramfs. This gives
>

Right, this looks correct for the above error.

-Stafford

\
 
 \ /
  Last update: 2017-05-06 10:17    [W:0.054 / U:0.164 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site