OFW unsecure kernel/initramfs load from zip file

Mitch Bradley wmb at laptop.org
Wed Sep 21 18:39:25 EDT 2011

Yeah, what James said.

That said, in most cases the mount/unmount penalty is not bad, because 
in cases where it was, I did some caching to make it less onerous.  
Cases in point include JFFS2, where mount is inherently horrible, so I 
cache the result of scanning the whole NAND surface, and the network, 
where I cache the DHCP result.

If you have problems, tell me.  My intention is that subsequent mounts 
should be fast enough.

On 9/21/2011 11:39 AM, James Cameron wrote:
> On Wed, Sep 21, 2011 at 04:21:42PM +0100, Daniel Drake wrote:
>> One lingering question is how OFW deals with mounting/unmounting.
>> I know that some words (in some contexts?) cause the disk to be
>> mounted, then the command to be executed, then the disk unmounted.
> Every open effectively causes a device initialisation and read of
> filesystem metadata.  It is one reason why external SD is so slow for
> multiple operations on XO-1.5; there's a coded delay for allowing the
> card supply rail to fall far enough for the card to reset.
> But OpenFirmware isn't doing anything else, so the operations tend to be
> reasonably fast.
>> Will the previously attached code cause a lot of mounts/unmounts?
> Yes.  bundle-present? place-ramdisk ?ofw-reflash $file-exists?
>> I'm particularly worried that it would slow down boot noticably. The
>> ideal of course is that it only gets mounted once, before this code
>> executes.
> Measure it.  In stages if necessary.  Enclose sections in t( )t pairs.
> e.g.
> " last:\boot\vmlinuz" 2dup
> t( $file-exists? ." time: vmlinuz existence" )t cr

More information about the Devel mailing list