All of lore.kernel.org
 help / color / mirror / Atom feed
From: nicolas.pitre@linaro.org (Nicolas Pitre)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 0/5] make XIP kernel .data compressed in ROM
Date: Wed, 30 Aug 2017 20:04:33 -0400 (EDT)	[thread overview]
Message-ID: <nycvar.YSQ.7.76.1708301951330.2606@knanqh.ubzr> (raw)
In-Reply-To: <SG2PR06MB1165EF18A363D9CC4C5531FE8A9C0@SG2PR06MB1165.apcprd06.prod.outlook.com>

On Wed, 30 Aug 2017, Chris Brandt wrote:

> On Tuesday, August 29, 2017 1, Nicolas Pitre wrote:
> > This patch series provides the ability to store the XIP kernel .data
> > segment compressed in ROM. It has to be copied to RAM anyway so
> > storing it uncompressed is arguably a waste of ROM resources.
> > 
> > While at it, the copying of .data (when not compressed) and the
> > clearing of .bss is now performed using optimized string routines
> > rather than doing it one word at a time.
> 
> Tested on my XIP system (Cortex-A9) and it seems to work OK.

Good, thanks for testing.

> > This work highlighted some defficiencies in linker scripts, especially
> > the XIP one. So this also includes linker script cleanups and fixes.
> 
> Thank you for this!

More will come eventually.

Did this fix your cramfs issue with 4.13-rc7?

> If you're curious, here are some numbers from my system:
> 
> Original xipImage size: 4,190,068 bytes
> xipImage size with CONFIG_XIP_DEFLATED_DATA=y: 3,985,227 bytes
> 
> A 204,841 byte reduction in image size (4.89%)

In my case it is 1195492 vs 1111632, or a 7% reduction.

This could be improved further by locating most of init.data and 
init.text into the compressed zone even if it is read-only. The 
decompressed form would be located in RAM temporarily and discarded 
after boot. Right now it is left uncompressed in ROM forever. But that's 
for a later round.


Nicolas

  reply	other threads:[~2017-08-31  0:04 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-30  2:55 [PATCH v2 0/5] make XIP kernel .data compressed in ROM Nicolas Pitre
2017-08-30  2:55 ` [PATCH v2 1/5] ARM: head-common.S: speed up startup code Nicolas Pitre
2017-10-03 12:41   ` Geert Uytterhoeven
2017-10-03 12:41     ` Geert Uytterhoeven
2017-10-03 13:15     ` Ard Biesheuvel
2017-10-03 13:15       ` Ard Biesheuvel
2017-10-03 15:24       ` Geert Uytterhoeven
2017-10-03 15:24         ` Geert Uytterhoeven
2017-08-30  2:55 ` [PATCH v2 2/5] ARM: vmlinux*.lds.S: some decruftification Nicolas Pitre
2017-08-30  2:55 ` [PATCH v2 3/5] ARM: vmlinux.lds.S: replace open coded .data sections with generic macros Nicolas Pitre
2017-08-30 15:11   ` Ard Biesheuvel
2017-08-30  2:55 ` [PATCH v2 4/5] ARM: vmlinux-xip.lds.S: fix multiple issues Nicolas Pitre
2017-08-30 15:12   ` Ard Biesheuvel
2017-08-30  2:55 ` [PATCH v2 5/5] ARM: XIP kernel: store .data compressed in ROM Nicolas Pitre
2017-08-30 21:58 ` [PATCH v2 0/5] make XIP kernel " Chris Brandt
2017-08-31  0:04   ` Nicolas Pitre [this message]
2017-08-31  0:43     ` Chris Brandt
2017-08-31  1:02       ` Nicolas Pitre

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=nycvar.YSQ.7.76.1708301951330.2606@knanqh.ubzr \
    --to=nicolas.pitre@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.