Re: 6.2-PRERELEASE/amd64 boot kernel.gz failes

2006-09-28 Thread Ruslan Ermilov
On Thu, Sep 28, 2006 at 02:33:10AM +0400, Ruslan Ermilov wrote:
> I can confirm this: RELENG_6 doesn't pxeboot when /boot/kernel/kernel
> is gzipped.  In my case, it hangs just after loading a loader.conf file.
> I've also verified that loading gzipped kernels/modules works on
> 7-CURRENT/i386.  So it's either loader vs. pxeboot issue (unlikely,
> since pxeboot reuses the loader binary), or i386 vs. amd64 issue
> (unlikely as well as amd64 reuses the i386 boot code), or more likely
> because some changes were not MFCed.  Perhaps this one:
> 
> : sobomax 2005-12-19 09:00:11 UTC
> : 
> :   FreeBSD src repository
> : 
> :   Modified files:
> : sys/boot/i386/libi386 Makefile biosdisk.c biospnp.c biossmap.c 
> :   i386_copy.c 
> :   Log:
> :   Long-long time ago, when the trees were large and memory expensive amount 
> of
> :   memory directly available to loader(8) and friends was limited to 640K on 
> i386.
> :   Those times have passed long time ago and now loader(8) can directly 
> access
> :   up to 4GB of RAM at least theoretically. At the same time, there are 
> several
> :   places where it's assumed that malloc() will only allocate memory within
> :   first megabyte.
> :   
> :   Remove that assumption by allocating appropriate bounce buffers for BIOS
> :   calls on stack where necessary.
> :   
> :   This allows using memory above first megabyte for heap if necessary.
> :   
> :   Revision  ChangesPath
> :   1.39  +3 -0  src/sys/boot/i386/libi386/Makefile
> :   1.46  +10 -17src/sys/boot/i386/libi386/biosdisk.c
> :   1.10  +1 -1  src/sys/boot/i386/libi386/biospnp.c
> :   1.4   +3 -2  src/sys/boot/i386/libi386/biossmap.c
> :   1.11  +6 -22 src/sys/boot/i386/libi386/i386_copy.c
> 
> I'll narrow this down tomorrow if noone bites me while I sleep.  :-)
> 
Yes, this and the follow-up commit plus the following diff make
pxeboot work with gzipped files.

%%%
Index: i386/loader/main.c
===
RCS file: /home/ncvs/src/sys/boot/i386/loader/main.c,v
retrieving revision 1.37
diff -u -r1.37 main.c
--- i386/loader/main.c  4 Aug 2006 07:56:32 -   1.37
+++ i386/loader/main.c  28 Sep 2006 09:06:02 -
@@ -91,7 +91,7 @@
  */
 bios_getmem();
 
-#ifdef LOADER_BZIP2_SUPPORT
+#if 1
 heap_top = PTOV(memtop_copyin);
 memtop_copyin -= 0x30;
 heap_bottom = PTOV(memtop_copyin);
%%%

Here's the loader "heap" command output on the same machine:

: 6.x /boot/loader (unpatched):
:   OK heap
:   Active Allocations: 803/2173
:   274432 bytes reserved 194432 bytes allocated
:   65 fragments (30016 bytes fragmented)
:   heap base at 0x404c0, top at 0x834c0
: 
: 7.x pxeboot loader (unpatched):
:   OK heap
:   Active Allocations: 896/2209
:   229376 bytes reserved 196728 bytes allocated
:   71 fragments (18992 bytes fragmented)
:   heap base at 0x404c0, top at 0x784c0, upper limit at 0x9fc00
: 
: 7.x pxeboot loader (patched):
:   OK heap
:   Active Allocations: 896/2209
:   229376 bytes reserved 196728 bytes allocated
:   71 fragments (18992 bytes fragmented)
:   heap base at 0xfbce6000, top at 0xfbd1e000, upper limit at 0xfbfe6000


Cheers,
-- 
Ruslan Ermilov
[EMAIL PROTECTED]
FreeBSD committer


pgpaebVazxkOH.pgp
Description: PGP signature


Re: 6.2-PRERELEASE/amd64 boot kernel.gz failes

2006-09-27 Thread Danny Braniss
> Danny Braniss wrote:
> > originally posted to [EMAIL PROTECTED]:
> > 
> > Hi,
> > While trying to figure out why boot/pxeboot failes on some
> > kernels/hosts, I think i've come up with one solid nogo,
> > if the kernel is gzipped it always fails.
> > Can someone confirm this? or am i suffering from some
> > local problem?
> 
> I believe I've seen this before when booting i386 kernels from soekris
> boards.  I've taken to using pxeboot to load netboot and then use
> netboot to load a kernel as the netboot drivers are way faster (for
> soekris at least).  Hopping through netboot also lets you have a menu to
> select one of several kernels to load.
> 
>   Sam
> 

I'll check this asap, btw, does netboot use pxe too?

danny


___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: 6.2-PRERELEASE/amd64 boot kernel.gz failes

2006-09-27 Thread Danny Braniss
> 
> --3uo+9/B/ebqu+fSQ
> Content-Type: text/plain; charset=us-ascii
> Content-Disposition: inline
> Content-Transfer-Encoding: quoted-printable
> 
> On Wed, Sep 27, 2006 at 05:09:16PM +0300, Danny Braniss wrote:
> > originally posted to [EMAIL PROTECTED]:
> >=20
> > Hi,
> > While trying to figure out why boot/pxeboot failes on some
> > kernels/hosts, I think i've come up with one solid nogo,
> > if the kernel is gzipped it always fails.
> > Can someone confirm this? or am i suffering from some
> > local problem?
> >=20
> I can confirm this: RELENG_6 doesn't pxeboot when /boot/kernel/kernel
> is gzipped.  In my case, it hangs just after loading a loader.conf file.
> I've also verified that loading gzipped kernels/modules works on
> 7-CURRENT/i386.  So it's either loader vs. pxeboot issue (unlikely,
> since pxeboot reuses the loader binary), or i386 vs. amd64 issue
> (unlikely as well as amd64 reuses the i386 boot code), or more likely
> because some changes were not MFCed.  Perhaps this one:
> 
> : sobomax 2005-12-19 09:00:11 UTC
> :=20
> :   FreeBSD src repository
> :=20
> :   Modified files:
> : sys/boot/i386/libi386 Makefile biosdisk.c biospnp.c biossmap.c=20
> :   i386_copy.c=20
> :   Log:
> :   Long-long time ago, when the trees were large and memory expensive amou=
> nt of
> :   memory directly available to loader(8) and friends was limited to 640K =
> on i386.
> :   Those times have passed long time ago and now loader(8) can directly ac=
> cess
> :   up to 4GB of RAM at least theoretically. At the same time, there are se=
> veral
> :   places where it's assumed that malloc() will only allocate memory within
> :   first megabyte.
> :  =20
> :   Remove that assumption by allocating appropriate bounce buffers for BIOS
> :   calls on stack where necessary.
> :  =20
> :   This allows using memory above first megabyte for heap if necessary.
> :  =20
> :   Revision  ChangesPath
> :   1.39  +3 -0  src/sys/boot/i386/libi386/Makefile
> :   1.46  +10 -17src/sys/boot/i386/libi386/biosdisk.c
> :   1.10  +1 -1  src/sys/boot/i386/libi386/biospnp.c
> :   1.4   +3 -2  src/sys/boot/i386/libi386/biossmap.c
> :   1.11  +6 -22 src/sys/boot/i386/libi386/i386_copy.c
> 
> I'll narrow this down tomorrow if noone bites me while I sleep.  :-)

THANKS!
I was begining to climb walls here, let me know when i can test
it!

danny


___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: 6.2-PRERELEASE/amd64 boot kernel.gz failes

2006-09-27 Thread Ruslan Ermilov
On Wed, Sep 27, 2006 at 05:09:16PM +0300, Danny Braniss wrote:
> originally posted to [EMAIL PROTECTED]:
> 
> Hi,
>   While trying to figure out why boot/pxeboot failes on some
> kernels/hosts, I think i've come up with one solid nogo,
> if the kernel is gzipped it always fails.
>   Can someone confirm this? or am i suffering from some
> local problem?
> 
I can confirm this: RELENG_6 doesn't pxeboot when /boot/kernel/kernel
is gzipped.  In my case, it hangs just after loading a loader.conf file.
I've also verified that loading gzipped kernels/modules works on
7-CURRENT/i386.  So it's either loader vs. pxeboot issue (unlikely,
since pxeboot reuses the loader binary), or i386 vs. amd64 issue
(unlikely as well as amd64 reuses the i386 boot code), or more likely
because some changes were not MFCed.  Perhaps this one:

: sobomax 2005-12-19 09:00:11 UTC
: 
:   FreeBSD src repository
: 
:   Modified files:
: sys/boot/i386/libi386 Makefile biosdisk.c biospnp.c biossmap.c 
:   i386_copy.c 
:   Log:
:   Long-long time ago, when the trees were large and memory expensive amount of
:   memory directly available to loader(8) and friends was limited to 640K on 
i386.
:   Those times have passed long time ago and now loader(8) can directly access
:   up to 4GB of RAM at least theoretically. At the same time, there are several
:   places where it's assumed that malloc() will only allocate memory within
:   first megabyte.
:   
:   Remove that assumption by allocating appropriate bounce buffers for BIOS
:   calls on stack where necessary.
:   
:   This allows using memory above first megabyte for heap if necessary.
:   
:   Revision  ChangesPath
:   1.39  +3 -0  src/sys/boot/i386/libi386/Makefile
:   1.46  +10 -17src/sys/boot/i386/libi386/biosdisk.c
:   1.10  +1 -1  src/sys/boot/i386/libi386/biospnp.c
:   1.4   +3 -2  src/sys/boot/i386/libi386/biossmap.c
:   1.11  +6 -22 src/sys/boot/i386/libi386/i386_copy.c

I'll narrow this down tomorrow if noone bites me while I sleep.  :-)


Cheers,
-- 
Ruslan Ermilov
[EMAIL PROTECTED]
FreeBSD committer


pgp71AsPmXP7J.pgp
Description: PGP signature


Re: 6.2-PRERELEASE/amd64 boot kernel.gz failes

2006-09-27 Thread Sam Leffler
Danny Braniss wrote:
> originally posted to [EMAIL PROTECTED]:
> 
> Hi,
>   While trying to figure out why boot/pxeboot failes on some
> kernels/hosts, I think i've come up with one solid nogo,
> if the kernel is gzipped it always fails.
>   Can someone confirm this? or am i suffering from some
> local problem?

I believe I've seen this before when booting i386 kernels from soekris
boards.  I've taken to using pxeboot to load netboot and then use
netboot to load a kernel as the netboot drivers are way faster (for
soekris at least).  Hopping through netboot also lets you have a menu to
select one of several kernels to load.

Sam

___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"