Re: lilo, initrd and RAM > 1GB

From: H. Peter Anvin (hpa@zytor.com)
Date: Tue Jan 01 2002 - 20:03:43 EST


Followup to: <3C2F66FF.13BD2A19@xss.co.at>
By author: Andreas Haumer <andreas@xss.co.at>
In newsgroup: linux.dev.kernel
>
> To me it looks like lilo get's the initrd start address
> wrong if there is more than 1GB of RAM in the system.
> I haven't found anything in the lilo documentation how to
> solve this problem.
>

The initrd end address should be obtained via the following algorithm:

        # high_addr here is the highest byte that can be occupied by
        # the initrd

        if ( bootproto >= 0x203 ) {
           high_addr := header->ramdisk_max
        } else {
           high_addr := 0x37ffffff
        }

        high_addr := min(memsize-1, high_addr)

The "magic constant" 0x37ffffff was widely believed to have been
0x3bffffff (which it might have originally been); this value, however,
doesn't work with most kernels.

This is why the ramdisk ceiling needs to be explicitly reported by the
kernel, as is done in the 2.03 boot protocol.

        -hpa

-- 
<hpa@transmeta.com> at work, <hpa@zytor.com> in private!
"Unix gives you enough rope to shoot yourself in the foot."
http://www.zytor.com/~hpa/puzzle.txt	<amsp@zytor.com>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon Jan 07 2002 - 21:00:16 EST