LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Bodo Eggert <7eggert@gmx.de>
To: Mike Frysinger <vapier.adi@gmail.com>
Cc: Bodo Eggert <7eggert@gmx.de>,
	jeffschroeder@computer.org,
	Geert Uytterhoeven <geert@linux-m68k.org>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] use tmpfs for rootfs v3
Date: Mon, 20 Oct 2008 20:13:09 +0200 (CEST)	[thread overview]
Message-ID: <alpine.LSU.0.999.0810202006050.5225@be1.lrz> (raw)
In-Reply-To: <8bd0f97a0810191112v29ca6be9kf4b0b8ecca718ef8@mail.gmail.com>

On Sun, 19 Oct 2008, Mike Frysinger wrote:
> On Fri, Oct 17, 2008 at 07:16, Bodo Eggert wrote:

> > This patch allows chosing tmpfs instead of ramfs for the root filesystem.
> > Having tmpfs is usefull for running systems from RAM, because it does not
> > risk deadlocking the system and possibly allows swapping. Using tmpfs
> > increases the kernel by 10 bytes on x86_64.
> 
> great option, thanks
> 
> > --- linux-2.6.27.2-numlock/fs/Kconfig   2008-10-10 13:18:34.000000000 +0200
> > +++ linux-2.6.27.3-tmpfs/fs/Kconfig     2008-10-11 15:42:21.000000000 +0200
> > @@ -953,6 +953,27 @@ config TMPFS_POSIX_ACL
> >
> >          If you don't know what Access Control Lists are, say N.
> >
> > +config TMPFS_ROOT
> > +       bool "Use tmpfs instrad of ramfs for initramfs"
> > +       depends on TMPFS && SHMEM
> > +       default n
> > +       help
> > +         This replaces the ramfs used for unpacking the cpio images
> > +         with tmpfs.
> > +
> > +         If unsure, say N
> 
> this should be init/Kconfig and depend on BLK_DEV_INITRD i think.  and
> then update the comment to talk about the initial filesystem rather
> than cpio images.

Maybe, but then you'd have to go to filesystems->pseudo-fs to enable tmpfs,
then to i-don't-remember to set it as the rootfs, and then back to
fs->pseudo-fs to unselect ramfs.

Thinking of it as a tmpfs option makes it much easier to use.

> > +config RAMFS
> > +       bool "Ramfs file system support" if TMPFS_ROOT
> 
> if you have initramfs support disabled, then you should be able to
> disable RAMFS as well.  so perhaps the depend should read like:
> if BLK_DEV_INITRD && TMPFS_ROOT || !BLK_DEV_INITRD

No, since a kernel not having initcpio support will mount rootfs anyway,
create some directories and special files and use them to open the console
and to mount the real root into.
-- 
The enemy diversion you have been ignoring will be the main attack.

  reply	other threads:[~2008-10-20 18:13 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-16 12:03 [PATCH] use tmpfs for rootfs Bodo Eggert
2008-10-16 13:10 ` Geert Uytterhoeven
2008-10-16 17:35   ` Bodo Eggert
2008-10-16 17:39   ` [PATCH] use tmpfs for rootfs v2 Bodo Eggert
2008-10-16 20:52     ` Chris Friesen
2008-10-16 22:45       ` Bodo Eggert
2008-10-16 21:03     ` Jeff Schroeder
2008-10-16 22:53       ` Bodo Eggert
2008-10-17 11:16       ` [PATCH] use tmpfs for rootfs v3 Bodo Eggert
2008-10-19 18:12         ` Mike Frysinger
2008-10-20 18:13           ` Bodo Eggert [this message]
2008-10-22 19:03             ` Mike Frysinger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.LSU.0.999.0810202006050.5225@be1.lrz \
    --to=7eggert@gmx.de \
    --cc=geert@linux-m68k.org \
    --cc=jeffschroeder@computer.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vapier.adi@gmail.com \
    --subject='Re: [PATCH] use tmpfs for rootfs v3' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).