From owner-freebsd-hackers Wed Mar 22 12:34:43 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from mass.cdrom.com (mg134-217.ricochet.net [204.179.134.217]) by hub.freebsd.org (Postfix) with ESMTP id 6907E37B636 for ; Wed, 22 Mar 2000 12:34:02 -0800 (PST) (envelope-from msmith@mass.cdrom.com) Received: from mass.cdrom.com (localhost [127.0.0.1]) by mass.cdrom.com (8.9.3/8.9.3) with ESMTP id MAA00615; Wed, 22 Mar 2000 12:36:25 -0800 (PST) (envelope-from msmith@mass.cdrom.com) Message-Id: <200003222036.MAA00615@mass.cdrom.com> X-Mailer: exmh version 2.1.1 10/15/1999 To: Nick Sayer Cc: freebsd-hackers@freebsd.org Subject: Re: md_image compression? In-reply-to: Your message of "Tue, 21 Mar 2000 21:55:39 PST." <200003220555.VAA56886@yoda.sftw.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 22 Mar 2000 12:36:22 -0800 From: Mike Smith Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG If you're using the loader, don't bother. It'll do this for you as it loads the image. See eg. how the install floppies work. > I'm sort of thinking in my head about adding the ability for the > md driver to handle gziped images. md's drvinit() looks like > the perfect place to do this. if strcmp(type,"md_image_gzip") then > gunzip the image and so on. > > Obviously this trades RAM for disk space. The target implementation > is the i-opener -> X terminal transmogrification. I think I can cram > the whole thing into the 16M flash card, and with compression of that > image, I can cram a lot more. To implement it, I have some questions: > > 1. Is there a way to de-allocate or otherwise reuse the original > compressed image after the unzip is finished? > > 2. What is the best strategy for allocating the output image? > malloc(9)? > > 3. This would effectively add libz to the kernel. Does anyone > object, given the proviso that this whole mess would hide inside > of an option (MD_PRELOAD_GZIP springs to mind)? Perhaps instead > the md unzipper could be loaded as a module. The module could > be thrown away using the same mechanism as #1 once the > decompression is finished. > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message > -- \\ Give a man a fish, and you feed him for a day. \\ Mike Smith \\ Tell him he should learn how to fish himself, \\ msmith@freebsd.org \\ and he'll hate you for a lifetime. \\ msmith@cdrom.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message