mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sam Ravnborg <sam@ravnborg.org>
To: linux-kernel@vger.kernel.org
Subject: Re: Cloning arch-independant KConfig
Date: Fri, 13 Aug 2010 03:20:52 +0200	[thread overview]
Message-ID: <20100813012052.GA2079@merkur.ravnborg.org> (raw)
In-Reply-To: <20100812233837.GG22777@mail.oracle.com>

On Thu, Aug 12, 2010 at 04:38:37PM -0700, Joel Becker wrote:
> Sam,
> 	I guess this is either a feature request or just wondering
> whether KConfig supports this idea.
> 	Often I have a wonderful minimal .config that builds a test
> kernel.  It only compiles the things I want in my kernel and modules,
> nothing more.  Usually I start from a distro kernel and then keep
> turning things off until I reach some minimum.
> 	However, when I get a new machine of a different architecture, I
> can't bring that work forward.  If I take this .config to that arch, the
> oldconfig just breaks.  I don't get good defaults for the arch-specific
> stuff.  Conversely, if I start from a distro .config for the new arch, I
> have to repeat all the whittle-down work.
> 	Is there any way to "extract" the non-arch-specific config
> values?  Essentially, all the "use USB, build ext3, give me these
> network cards" fields should be kept, but I want to start from a default
> architecture config.

Today there are a few ways you can do so already.
Say that you have saved away the known good one as "good", which is
a direct copy of your .config.

Then you can do for example:
KCONFIG_ALLCONFIG=good make alldefconfig

This will produce a config wich is almost equal to what you had before,
and with defaults for all new stuff.
I tested it where I used a sparc defconfig as input to a i386
config and it just worked.

Another possibility:
If you already have configured your kernel, but want to use
"good" but keep the settings for all the new stuff.
Then you can do:

cat .config good > new
mv new .config
make menuconfig

This will trigger a lot of override warnings - which you just ignore.
Resulting config is then mostly from "good".

We do not have a way to say "copy only non-arch specific settings".
So I hope the above is OK.

	Sam

  reply	other threads:[~2010-08-13  1:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-12 23:38 Joel Becker
2010-08-13  1:20 ` Sam Ravnborg [this message]
2010-08-13  1:30   ` Joel Becker

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=20100813012052.GA2079@merkur.ravnborg.org \
    --to=sam@ravnborg.org \
    --cc=linux-kernel@vger.kernel.org \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®