From owner-freebsd-current@FreeBSD.ORG Wed Mar 2 08:02:27 2011 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 563D0106564A; Wed, 2 Mar 2011 08:02:27 +0000 (UTC) (envelope-from rdivacky@vlk.vlakno.cz) Received: from vlakno.cz (lev.vlakno.cz [77.93.215.190]) by mx1.freebsd.org (Postfix) with ESMTP id 0E69E8FC12; Wed, 2 Mar 2011 08:02:26 +0000 (UTC) Received: from lev.vlakno.cz (localhost [127.0.0.1]) by vlakno.cz (Postfix) with ESMTP id E33AA9CB149; Wed, 2 Mar 2011 09:02:24 +0100 (CET) X-Virus-Scanned: amavisd-new at vlakno.cz Received: from vlakno.cz ([127.0.0.1]) by lev.vlakno.cz (lev.vlakno.cz [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id CegLfDdrkR-l; Wed, 2 Mar 2011 09:02:24 +0100 (CET) Received: from vlk.vlakno.cz (localhost [127.0.0.1]) by vlakno.cz (Postfix) with ESMTP id E3CD79CB3D1; Wed, 2 Mar 2011 09:02:23 +0100 (CET) Received: (from rdivacky@localhost) by vlk.vlakno.cz (8.14.4/8.14.4/Submit) id p2282NIT091135; Wed, 2 Mar 2011 09:02:23 +0100 (CET) (envelope-from rdivacky) Date: Wed, 2 Mar 2011 09:02:23 +0100 From: Roman Divacky To: Alexander Best Message-ID: <20110302080223.GA90698@freebsd.org> References: <20110228203928.GA93494@freebsd.org> <20110302022854.GA42880@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110302022854.GA42880@freebsd.org> User-Agent: Mutt/1.4.2.3i Cc: current@freebsd.org Subject: Re: [TESTING]: boot2 changes X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Mar 2011 08:02:27 -0000 On Wed, Mar 02, 2011 at 02:28:54AM +0000, Alexander Best wrote: > On Mon Feb 28 11, Roman Divacky wrote: > > hi there, > > > > I have a patch that shrinks boot2 some: > > > > 1) it switches kname to be just a pointer instead of an array > > thus avoiding a couple of memcpy()s > > > > 2) it changes ioctl to unsigned from uint8_t > > > > 3) it changes the first keyhit limit to 5 seconds from 3 > > so that constant propagation can take place > > > > 4) it changes the ticks overflow computation as suggested by bde@ > > > > 5) it removes bi_basemem/bi_extmem/bi_memsizes_valid setting from > > bootinfo as it is unused > > > > > > the patch: > > > > http://lev.vlakno.cz/~rdivacky/boot2-almost-there-diet.patch > > > > It works for me and I'd like you to review/test this patch > > did you also take a look at the code in sys/boot/i386/common? many functions in > sys/boot/i386/boot2/boot2.c are also defined there and some seem to contain > improved code. > > e.g. was the return type of xputc() changed from int to void, i think that's > quite a resonable change and might reduce the boot2 binary size further. I have some more experimental changes locally, and I am working on that, dont worry :) roman