lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20140807160352.GB1382@ravnborg.org>
Date:	Thu, 7 Aug 2014 18:03:52 +0200
From:	Sam Ravnborg <sam@...nborg.org>
To:	Josh Triplett <josh@...htriplett.org>
Cc:	akpm@...ux-foundation.org, torvalds@...ux-foundation.org,
	David Rientjes <rientjes@...gle.com>,
	"Luis R. Rodriguez" <mcgrof@...e.com>,
	"H. Peter Anvin" <hpa@...or.com>, Ingo Molnar <mingo@...hat.com>,
	Thomas Gleixner <tglx@...utronix.de>, x86@...nel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] x86: Add "make tinyconfig" to configure the tiniest
 possible kernel

On Wed, Aug 06, 2014 at 03:31:54PM -0700, Josh Triplett wrote:
> Since commit 5d2acfc7b974bbd3858b4dd3f2cdc6362dd8843a ("kconfig: make
> allnoconfig disable options behind EMBEDDED and EXPERT") in 3.15-rc1,
> "make allnoconfig" disables every possible config option.
> 
> However, a few configuration options (CC_OPTIMIZE_FOR_SIZE,
> OPTIMIZE_INLINING) produce a smaller kernel when turned on, and a few
> choices exist (compression, highmem, allocator) for which a non-default
> option produces a smaller kernel.
> 
> Add a "tinyconfig" option, which starts from allnoconfig and then sets
> these options to configure the tiniest possible kernel.  This provides a
> better baseline for embedded systems or efforts to reduce kernel size.

In general I dislike the whole approach where we introduce makefile
magic to support diverse config snippets.
Another approch where we factor out this from the MAkefile seems much leaner.

And for this specific patch then this is not x86 specific at all.
If we keep the logic in the makefiles than we should:
1) Make the infrastructure general
2) Document it
3) Find another home for the config snippets that are non-arch specific like this one

	Sam

> diff --git a/arch/x86/configs/tiny.config b/arch/x86/configs/tiny.config
> new file mode 100644
> index 0000000..8f0e54c
> --- /dev/null
> +++ b/arch/x86/configs/tiny.config
> @@ -0,0 +1,5 @@
> +CONFIG_CC_OPTIMIZE_FOR_SIZE=y
> +CONFIG_KERNEL_XZ=y
> +CONFIG_NOHIGHMEM=y
> +CONFIG_OPTIMIZE_INLINING=y
> +CONFIG_SLOB=y
All the above are general options that apply equal to arm than to x86.

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ