Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 4 Oct 1998 11:21:45 +0200 (METDST)
From:      Michael Class <michaelc@hpbbse.bbn.hp.com>
To:        current@FreeBSD.ORG
Subject:   Problem with 3-stage bootloader
Message-ID:  <Pine.HPP.3.94.981004112111.21393A-100000@hpbbse.bbn.hp.com>

next in thread | raw e-mail | index | archive | help
Hello,

I was just trying to use the new 3-stage bootloader.
It failed for my setup. To me it looks like it will only work,
if the FreeBSD slice is the first in the partition-table of a disk.
I can make it to work with the following patch (not meant as a 
correct solution, but to give you an idea, of what the reason for
the failure is). Basically only the first slice-table entry is copied,
but afterwards the code assumes that all 4 entries are in memory.


*** biosdisk.c	Sun Oct  4 11:08:12 1998
--- biosdisk.c.orig	Sun Oct  4 11:07:22 1998
***************
*** 78,84 ****
  #define BD_MODEEDD3	0x2
  #define BD_FLOPPY	(1<<2)
      struct disklabel		od_disklabel;
!     struct dos_partition	od_parttab[4];
  #define BD_LABELOK	(1<<3)
  #define BD_PARTTABOK	(1<<4)
  };
--- 78,84 ----
  #define BD_MODEEDD3	0x2
  #define BD_FLOPPY	(1<<2)
      struct disklabel		od_disklabel;
!     struct dos_partition	od_parttab;
  #define BD_LABELOK	(1<<3)
  #define BD_PARTTABOK	(1<<4)
  };
***************
*** 288,294 ****
  	sector = 0;
  	goto unsliced;		/* may be a floppy */
      }
!     bcopy(buf + DOSPARTOFF, &od->od_parttab, sizeof(struct dos_partition) * 4);
      dptr = &od->od_parttab;
      od->od_flags |= BD_PARTTABOK;
  
--- 288,294 ----
  	sector = 0;
  	goto unsliced;		/* may be a floppy */
      }
!     bcopy(buf + DOSPARTOFF, &od->od_parttab, sizeof(struct dos_partition));
      dptr = &od->od_parttab;
      od->od_flags |= BD_PARTTABOK;


After this patch I can boot an aout-kernel on my machine. Unfortunately
I am still failing on an ELF-Kernel. I get immediately dropped in the
debugger, but a stacktrace gives only garbage back.


Michael


___________________________________________________________________________
Michael Class                            E-Mail: michael_class@hp.com
E-Business Solutions Center              Phone:  +49 7031 14-3707
EBSO-SERC                                Fax:    +49 7031 14-4196
___________________________________________________________________________
            Hewlett-Packard GmbH, PO Box 1430, 71004 Boeblingen
Sitz der Gesellschaft: Böblingen, Amtsgericht Böblingen HRB 4081
Geschäftsführer: Jörg Menno Harms (Vorsitzender), Heribert Schmitz,
                 Rudi Speier, Fritz Schuller, Hans-Günter Hohmann
___________________________________________________________________________


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.HPP.3.94.981004112111.21393A-100000>