From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1U1Wfh-00052x-D2 for mharc-grub-devel@gnu.org; Sat, 02 Feb 2013 01:33:53 -0500 Received: from eggs.gnu.org ([208.118.235.92]:58523) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U1Wfe-00052d-Ba for grub-devel@gnu.org; Sat, 02 Feb 2013 01:33:52 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U1Wfc-0000u5-OW for grub-devel@gnu.org; Sat, 02 Feb 2013 01:33:50 -0500 Received: from mail-lb0-f171.google.com ([209.85.217.171]:42154) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U1Wfc-0000tu-Fx for grub-devel@gnu.org; Sat, 02 Feb 2013 01:33:48 -0500 Received: by mail-lb0-f171.google.com with SMTP id gg13so5266927lbb.30 for ; Fri, 01 Feb 2013 22:33:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:date:from:to:subject:message-id:in-reply-to:references :x-mailer:mime-version:content-type; bh=jE7C9PgIKn9QuFKRiZJetrE5q+0O6RwXTZESv4w8L8Q=; b=zox5407XRiF8BHI/IrRFp3RfSr56i0dXhJdsG19o6jc3zV+dqZf2EQj99Fztdc6rU8 FLAXtYT7EbT9n7X7VjIooIEP4x/X3Rg7yShrCV9WnlaLKgPPTfdaZyQ3jEWb1AmJTQki +OVwn8RHsEbcyI0tSYvxKJtYFY0vVTyyYfCs/JVj8z5YLmIEdrox++Nr9siFFOk9X09M YKVHgQZncAOG9gyVE1+sibhC5Zc8H7pBhKzx1Kzpdn5J9oOJCa7XBJinZSFB6T8pgcMH ru6iW0tMQtH1Q8F9L2UF3ATHWFio7qEJsoLHR0bogr0XqcjZIpism++9z6jj81RtnlkO vTlQ== X-Received: by 10.112.102.9 with SMTP id fk9mr5584503lbb.100.1359786826988; Fri, 01 Feb 2013 22:33:46 -0800 (PST) Received: from opensuse.site (ppp91-78-198-46.pppoe.mtu-net.ru. [91.78.198.46]) by mx.google.com with ESMTPS id t7sm3197904lbf.12.2013.02.01.22.33.44 (version=SSLv3 cipher=RC4-SHA bits=128/128); Fri, 01 Feb 2013 22:33:45 -0800 (PST) Date: Sat, 2 Feb 2013 10:33:42 +0400 From: Andrey Borzenkov To: The development of GNU GRUB Subject: Re: for ppc, include all modules in the core image Message-ID: <20130202103342.5e2495c5@opensuse.site> In-Reply-To: <5085880D.3020408@gmail.com> References: <20121016062854.Horde.IYLUrZir309QfTbmkvaCoBA@imap.linux.ibm.com> <508045A6.6040309@gmail.com> <20121022133017.Horde.UPexMZir309QhYKpIRXChBA@imap.linux.ibm.com> <5085880D.3020408@gmail.com> X-Mailer: Claws Mail 3.9.0 (GTK+ 2.24.10; x86_64-suse-linux-gnu) Mime-Version: 1.0 Content-Type: multipart/signed; micalg=PGP-SHA1; boundary="Sig_/U.eNBqKjmUvTMnBUQ2YNETK"; protocol="application/pgp-signature" X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 209.85.217.171 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Feb 2013 06:33:52 -0000 --Sig_/U.eNBqKjmUvTMnBUQ2YNETK Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable =D0=92 Mon, 22 Oct 2012 19:53:17 +0200 Vladimir '=CF=86-coder/phcoder' Serbinenko =D0=BF=D0=B8= =D1=88=D0=B5=D1=82: > On 22.10.2012 19:30, Paulo Flabiano Smorigo/Brazil/IBM wrote: >=20 > >=20 > > Quoting Vladimir '=CF=86-coder/phcoder' Serbinenko : > >=20 > >> On 16.10.2012 12:28, Paulo Flabiano Smorigo/Brazil/IBM wrote: > >> > >>> Hi all! > >>> > >>> This patch implements the solution suggested by Gustavo Luiz Duarte > >>> : > >>> > >>> Adding more modules to be built-in to the grub core ELF is easy. It i= s a > >>> parameter passed by grub2-install to grub2-mkimage. However, there is= a > >>> downside > >>> on adding many modules to the core ELF: they are fully initialized in > >>> the grub's > >>> first stage. It means you could hit a bug on a module you don't need = and > >>> end up > >>> with a non-bootable system. > >>> > >>> Another downside is that you wouldn't get updates for these built-in > >>> modules, as > >>> updating the grub2 package only updates the modules residing in /boot > >>> and not > >>> the grub core ELF in the PReP partition. > >>> > >>> A proper solution would be to add to grub the ability of having built= -in > >>> *inactive* modules which would be loaded and initialized only on dema= nd > >>> (i.e. > >>> explicitly calling the insmod command). > >>> > >> > >> This is what memdisk does (i.a.). Why do you need anything else? > >> > >>> > >>> > >>> _______________________________________________ > >>> Grub-devel mailing list > >>> Grub-devel@gnu.org > >>> https://lists.gnu.org/mailman/listinfo/grub-devel > >> > >> > >> > >> --=20 > >> Regards > >> Vladimir '=CF=86-coder/phcoder' Serbinenko > >=20 > > Hi phcoder, > >=20 > > Thanks for the reply. I studied memdisk and tried to use grub-mkstandal= one > > but the idea used in this patch is different. It's like a plan B just in > > case /boot isn't found. It gives the "grub rescue" a new level of recov= ery, > > increasing the chances to fix the system. This extra modules is stored = in a > > different area and will *only* be used in this case. > >=20 > > Otherwise, the normal modules, inside /boot, will be used normally and = If > > there is an update or if grub.cfg changes, the new files will be used. > >=20 >=20 > Can't you attain the same result with memdisk but not pointing root to it? > This part is size-critical and we need a good reason to put new features. >=20 The problem is, currently there is no way to separate module location and the rest (grub.cfg to start with). Both are searched for under $prefix. So while you can embed memory disk that contains all modules, you cannot tell grub to autoload modules from there while continuing to use /boot/grub for everything else.=20 Separate $module_prefix would be useful here. As the minimal step, use $module_prefix for module loading and initialize it to $prefix by default (at the same time as $prefix is computed). Then users can point $module_prefix to memory disk later, in grub.cfg. Will you accept the patch? It looks trivial enough. It does increase size of kernel though, so I would be interested if RH guys would consider using this solution? --Sig_/U.eNBqKjmUvTMnBUQ2YNETK Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (GNU/Linux) iEYEARECAAYFAlEMs0YACgkQR6LMutpd94wWNgCfV/IV26RK3mNnjyprCwic6L29 ozsAnj6s6puC3msbqyzk4VZOWlAciDh5 =OJ8f -----END PGP SIGNATURE----- --Sig_/U.eNBqKjmUvTMnBUQ2YNETK--