Re: Initramfs FSID altered in 3.14

From: Tejun Heo
Date: Thu Apr 03 2014 - 15:16:38 EST


Hello,

On Thu, Apr 03, 2014 at 08:13:50PM +0200, Thomas Bächler wrote:
> Most of these bugs were not caused by rootfs' FSID being different from
> 1, but rather because there was a file system with FSID 0.
>
> Only util-linux/switch_root assumed that rootfs always had exactly FSID
> 1 - which is IMO a wrong assumption.
>
> However, tt seems that people have been assuming that st_dev > 0 for a
> while. If we want to revert this in the kernel, this patch (untested)
> should be sufficient:
>
> diff --git a/fs/super.c b/fs/super.c
> index 80d5cf2..d9fddde 100644
> --- a/fs/super.c
> +++ b/fs/super.c
> @@ -802,7 +802,7 @@ void emergency_remount(void)
> static DEFINE_IDA(unnamed_dev_ida);
> static DEFINE_SPINLOCK(unnamed_dev_lock);/* protects the above */
> -static int unnamed_dev_start = 0; /* don't bother trying below it */
> +static int unnamed_dev_start = 1; /* don't bother trying below it */
> int get_anon_bdev(dev_t *p)
> {

Alexandre, this is the one line change that should fix it. Can you
please test it?

Thomas, can you please write proper patch description with reference
to the following thread and stable # 3.14 tag?

http://lkml.kernel.org/g/CAPEhTTFP3N-ReasmgL5n82mve8p8M3crqmaMvzV+F2p5JCSRbQ@xxxxxxxxxxxxxx

Thanks.

--
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/