* Compressed Kernels
@ 2005-03-31 8:35 JP Foster
2005-03-31 8:42 ` Robin H. Johnson
0 siblings, 1 reply; 12+ messages in thread
From: JP Foster @ 2005-03-31 8:35 UTC (permalink / raw)
To: linux-mips
I've noticed that mips doesn't have a compressed kernel option,
so I had added support (ripped shamelessly from arch/i386) for it
to save space on our flash chips.
It works fine for my db1550 and also our product boards.
The patch is pretty messy but if there was interest in it I could clean
it up. Is there any historical reason for it not being included?
--
jp.foster@exterity.co.uk
Digital Simplicity
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed Kernels
2005-03-31 8:35 Compressed Kernels JP Foster
@ 2005-03-31 8:42 ` Robin H. Johnson
2005-03-31 16:24 ` Pete Popov
0 siblings, 1 reply; 12+ messages in thread
From: Robin H. Johnson @ 2005-03-31 8:42 UTC (permalink / raw)
To: linux-mips
[-- Attachment #1: Type: text/plain, Size: 1026 bytes --]
On Thu, Mar 31, 2005 at 09:35:26AM +0100, JP Foster wrote:
> I've noticed that mips doesn't have a compressed kernel option,
> so I had added support (ripped shamelessly from arch/i386) for it
> to save space on our flash chips.
>
> It works fine for my db1550 and also our product boards.
> The patch is pretty messy but if there was interest in it I could clean
> it up. Is there any historical reason for it not being included?
Pete Popov was already working some zImage code.
His link for it:
ftp://ftp.linux-mips.org/pub/linux/mips/people/ppopov/2.6/zImage_2_6_10.patch
It worked for me in January on an XXS1500 device, but I haven't tried it
on any newer kernel since then.
I don't know the current status of it, or if it is going to go into the
main codebase at all.
--
Robin Hugh Johnson
E-Mail : robbat2@orbis-terrarum.net
Home Page : http://www.orbis-terrarum.net/?l=people.robbat2
ICQ# : 30269588 or 41961639
GnuPG FP : 11AC BA4F 4778 E3F6 E4ED F38E B27B 944E 3488 4E85
[-- Attachment #2: Type: application/pgp-signature, Size: 241 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed Kernels
2005-03-31 8:42 ` Robin H. Johnson
@ 2005-03-31 16:24 ` Pete Popov
2005-04-01 9:05 ` JP
0 siblings, 1 reply; 12+ messages in thread
From: Pete Popov @ 2005-03-31 16:24 UTC (permalink / raw)
To: Robin H. Johnson; +Cc: linux-mips
Robin H. Johnson wrote:
> On Thu, Mar 31, 2005 at 09:35:26AM +0100, JP Foster wrote:
>
>>I've noticed that mips doesn't have a compressed kernel option,
>>so I had added support (ripped shamelessly from arch/i386) for it
>>to save space on our flash chips.
>>
>>It works fine for my db1550 and also our product boards.
>>The patch is pretty messy but if there was interest in it I could clean
>>it up. Is there any historical reason for it not being included?
>
> Pete Popov was already working some zImage code.
>
> His link for it:
> ftp://ftp.linux-mips.org/pub/linux/mips/people/ppopov/2.6/zImage_2_6_10.patch
>
> It worked for me in January on an XXS1500 device, but I haven't tried it
> on any newer kernel since then.
>
> I don't know the current status of it, or if it is going to go into the
> main codebase at all.
Should be easy to update if if doesn't apply cleanly anymore. I think the
complaint about that patch is that it duplicates some code from other
architectures and a more common solution is needed. Since I don't have time to
work on something more common, the patch remains stand alone.
Pete
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed Kernels
2005-03-31 16:24 ` Pete Popov
@ 2005-04-01 9:05 ` JP
0 siblings, 0 replies; 12+ messages in thread
From: JP @ 2005-04-01 9:05 UTC (permalink / raw)
To: ppopov; +Cc: Robin H. Johnson, linux-mips
> Should be easy to update if if doesn't apply cleanly anymore. I think the
> complaint about that patch is that it duplicates some code from other
> architectures and a more common solution is needed. Since I don't have time to
> work on something more common, the patch remains stand alone.
Fair enough I'd agree with that as the code I used was straight outta
i386. Other archs use the same arm sh etc. I'll apply your patch for our
boards rather than duplicate the effort. This I guess is a problem for
all arches and really should be addressed at the kernel.org level.
--
mailto:jaypee@hotpop.com
http://jaypee.org.uk
^ permalink raw reply [flat|nested] 12+ messages in thread
* Compressed kernels
@ 2003-11-20 9:10 Colin.Helliwell
2003-11-20 15:21 ` Dan Malek
2003-11-22 2:41 ` Ralf Baechle
0 siblings, 2 replies; 12+ messages in thread
From: Colin.Helliwell @ 2003-11-20 9:10 UTC (permalink / raw)
To: linux-mips
I'm running a 2.4.21 kernel tree, and would like to have kernel
compression. I wondered if this has gone back into the latest versions yet?
Or is the old EV64120 code worth adapting to my needs?
Thanks.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed kernels
2003-11-20 9:10 Compressed kernels Colin.Helliwell
@ 2003-11-20 15:21 ` Dan Malek
2003-11-20 21:02 ` Ralf Baechle
2003-11-22 2:41 ` Ralf Baechle
1 sibling, 1 reply; 12+ messages in thread
From: Dan Malek @ 2003-11-20 15:21 UTC (permalink / raw)
To: Colin.Helliwell; +Cc: linux-mips
Colin.Helliwell@Zarlink.Com wrote:
> I'm running a 2.4.21 kernel tree, and would like to have kernel
> compression. I wondered if this has gone back into the latest versions yet?
If you apply the 'zImage' patch from Pete's ftp directory (look in past
e-mails for this discussion) you will see what I have done for a few of
the boards I'm using. It's quite trivial to add new boards to get
this feature. I'm still working on the method of attaching the
compressed initrd to the same image, which I find quite useful for
embedded applications.
Have fun!
-- Dan
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed kernels
2003-11-20 15:21 ` Dan Malek
@ 2003-11-20 21:02 ` Ralf Baechle
2003-11-20 21:42 ` Dan Malek
2003-11-20 22:33 ` Wolfgang Denk
0 siblings, 2 replies; 12+ messages in thread
From: Ralf Baechle @ 2003-11-20 21:02 UTC (permalink / raw)
To: Dan Malek; +Cc: Colin.Helliwell, linux-mips
On Thu, Nov 20, 2003 at 10:21:27AM -0500, Dan Malek wrote:
> Date: Thu, 20 Nov 2003 10:21:27 -0500
> From: Dan Malek <dan@embeddededge.com>
> To: Colin.Helliwell@Zarlink.Com
> CC: linux-mips@linux-mips.org
> Subject: Re: Compressed kernels
> Content-Type: text/plain; charset=us-ascii; format=flowed
>
> Colin.Helliwell@Zarlink.Com wrote:
>
> >I'm running a 2.4.21 kernel tree, and would like to have kernel
> >compression. I wondered if this has gone back into the latest versions yet?
>
> If you apply the 'zImage' patch from Pete's ftp directory (look in past
> e-mails for this discussion) you will see what I have done for a few of
> the boards I'm using. It's quite trivial to add new boards to get
> this feature. I'm still working on the method of attaching the
> compressed initrd to the same image, which I find quite useful for
> embedded applications.
Compressed kernels seem to be fairly high on everybody's list. Due to
size limits of some boatloaders and flash memory being always too small
and too expensive I guess there would also be some interest in bzip2
support.
Ralf
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed kernels
2003-11-20 21:02 ` Ralf Baechle
@ 2003-11-20 21:42 ` Dan Malek
2003-11-20 22:33 ` Wolfgang Denk
1 sibling, 0 replies; 12+ messages in thread
From: Dan Malek @ 2003-11-20 21:42 UTC (permalink / raw)
To: Ralf Baechle; +Cc: Colin.Helliwell, linux-mips
Ralf Baechle wrote:
> Compressed kernels seem to be fairly high on everybody's list. Due to
> size limits of some boatloaders and flash memory being always too small
> and too expensive I guess there would also be some interest in bzip2
> support.
Interesting thought. I compressed the binary image using bzip2 instead
of gzip, found it was only about 7% smaller (approximately 60K bytes).
To this, we have to add the trade off that the kernel already contains
too many versions of a readily available zlib, and the attached initrd
is also a gzip file. Five years ago we used to be concerned about a
few bytes here and there, which prompted the interest in compressed
kernels, but today the embedded systems I'm working with have lots of
flash memory. It seems product development cost to add a little more
flash is winning over spending the engineering time to squeeze those
last few bytes.
I don't think I'll spend my time doing it, but the process of creating
the compressed image and the calls to the uncompress functions are very
clear if someone else wants to do it :-)
Thanks.
-- Dan
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed kernels
2003-11-20 21:02 ` Ralf Baechle
2003-11-20 21:42 ` Dan Malek
@ 2003-11-20 22:33 ` Wolfgang Denk
2003-11-20 22:50 ` Dan Malek
1 sibling, 1 reply; 12+ messages in thread
From: Wolfgang Denk @ 2003-11-20 22:33 UTC (permalink / raw)
To: Ralf Baechle; +Cc: Dan Malek, Colin.Helliwell, linux-mips
In message <20031120210257.GA758@linux-mips.org> you wrote:
>
> Compressed kernels seem to be fairly high on everybody's list. Due to
> size limits of some boatloaders and flash memory being always too small
> and too expensive I guess there would also be some interest in bzip2
> support.
Well, instead of doing this in the Linux kernel, you could also do
it in the boot loader. U-Boot supports both gzip and bzip2 decom-
pression.
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-4596-87 Fax: (+49)-8142-4596-88 Email: wd@denx.de
If programming was easy, they wouldn't need something as complicated
as a human being to do it, now would they?
- L. Wall & R. L. Schwartz, _Programming Perl_
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: Compressed kernels
2003-11-20 22:33 ` Wolfgang Denk
@ 2003-11-20 22:50 ` Dan Malek
2003-11-25 23:44 ` Ralf Baechle
0 siblings, 1 reply; 12+ messages in thread
From: Dan Malek @ 2003-11-20 22:50 UTC (permalink / raw)
To: Wolfgang Denk; +Cc: Ralf Baechle, Colin.Helliwell, linux-mips
Wolfgang Denk wrote:
> Well, instead of doing this in the Linux kernel, you could also do
> it in the boot loader. U-Boot supports both gzip and bzip2 decom-
> pression.
Just to keep us busy, there are people that chose options
other than u-boot :-) For embedded systems that are really sensitive
to boot time and amount of flash used, they may only have minimal
instructions for processor initialization and then jump to the
compressed kernel image. I'm not going to discuss boot roms any
further (yes, I use u-boot every chance I get).
-- Dan
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed kernels
2003-11-20 22:50 ` Dan Malek
@ 2003-11-25 23:44 ` Ralf Baechle
0 siblings, 0 replies; 12+ messages in thread
From: Ralf Baechle @ 2003-11-25 23:44 UTC (permalink / raw)
To: Dan Malek; +Cc: Wolfgang Denk, Colin.Helliwell, linux-mips
On Thu, Nov 20, 2003 at 05:50:17PM -0500, Dan Malek wrote:
> Just to keep us busy, there are people that chose options
> other than u-boot :-) For embedded systems that are really sensitive
> to boot time and amount of flash used, they may only have minimal
> instructions for processor initialization and then jump to the
> compressed kernel image. I'm not going to discuss boot roms any
> further (yes, I use u-boot every chance I get).
... the lesson I learned about firmware is it's usually not very well
tested because there are only few applications (that is usually
operating systems) running it. Phear da firmware ...
Ralf
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Compressed kernels
2003-11-20 9:10 Compressed kernels Colin.Helliwell
2003-11-20 15:21 ` Dan Malek
@ 2003-11-22 2:41 ` Ralf Baechle
1 sibling, 0 replies; 12+ messages in thread
From: Ralf Baechle @ 2003-11-22 2:41 UTC (permalink / raw)
To: Colin.Helliwell; +Cc: linux-mips
On Thu, Nov 20, 2003 at 09:10:41AM +0000, Colin.Helliwell@Zarlink.Com wrote:
> I'm running a 2.4.21 kernel tree, and would like to have kernel
> compression. I wondered if this has gone back into the latest versions yet?
> Or is the old EV64120 code worth adapting to my needs?
The old code apparently was functioning but replicating code from zlib and
generally was carrying half a firmware as it's baggage.
Ralf
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2005-04-01 9:06 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-31 8:35 Compressed Kernels JP Foster
2005-03-31 8:42 ` Robin H. Johnson
2005-03-31 16:24 ` Pete Popov
2005-04-01 9:05 ` JP
-- strict thread matches above, loose matches on Subject: below --
2003-11-20 9:10 Compressed kernels Colin.Helliwell
2003-11-20 15:21 ` Dan Malek
2003-11-20 21:02 ` Ralf Baechle
2003-11-20 21:42 ` Dan Malek
2003-11-20 22:33 ` Wolfgang Denk
2003-11-20 22:50 ` Dan Malek
2003-11-25 23:44 ` Ralf Baechle
2003-11-22 2:41 ` Ralf Baechle
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox