Subject: Booting off of sdb1...

From: Alex deVries <[email-masked]>
Date: Tue, 2 Sep 1997 17:47:13 -0400 (EDT)

First off, thanks to input from Mike, I got my partition setup properly.
Here's how it's done:

In fx in IRIX, create an optional partition.  This will create one huge
partition at the beginning (sdb1), and a volume header (sdb2), which you
won't use.  It doesn't matter what type of partition you label sdb1, Linux
doesn't recognize either.  All this means is you may have to force the
type recognition when doing a mount.

>From within an nfs-rooted Linux, I mke2fs'd it, and copied all the files
over from my nfsroot (esentially Ralf's root .cpio.gz).

But, here's my problem:  I've take my old kernel that boots with NFS root,
and tried to boot it using:  
vmlinux root=/dev/sdb1

The kernel starts, and it finishes off with:

Partition check:
 sda: sad1 sda2 sda3 sda4
 sdb: sdb1 sdb2 sdb3
VFS: Mounted root (ext2 filesystem) readonly.
: Can't open

And then nothing.

What am I missing?

- Alex

      Alex deVries              Success is realizing 
  System Administrator          attainable dreams.
   The EngSoc Project

---

From: Mark Salter <[email-masked]>
Date: Tue, 2 Sep 1997 17:01:43 -0500

>   System Administrator          attainable dreams.

Try this patch to linux/arch/mips/sgi/prom/cmdline.c:

*** cmdline.c.orig      Tue Sep  2 16:59:26 1997
--- cmdline.c   Tue Sep  2 15:59:04 1997
***************
*** 52,57 ****
--- 52,59 ----
        pic_cont:
                actr++;
        }
+       if (cp != &(arcs_cmdline[0])) /* get rid of trailing space */
+               --cp;
        *cp = '\0';
  
  #ifdef DEBUG_CMDLINE

--Mark

---

From: Alex deVries <[email-masked]>
Date: Tue, 2 Sep 1997 19:45:59 -0400 (EDT)

> Try this patch to linux/arch/mips/sgi/prom/cmdline.c:

<snip>

Well, I would try that patch, but I am unable to compile kernels because I
_always_ get this:

make[1]: Entering directory `/usr/src/sgi/linux/arch/mips/kernel'
mips-linux-gcc -D__KERNEL__ -I/usr/src/sgi/linux/include -Wall
-Wstrict-prototypes -O2 -fomit-frame-pointer -G 0 -mno-abicalls -fno-pic
-D__GOGOGO__ -mcpu=r4600 -mips2 -pipe -c entry.S -o entry.o
entry.S: Assembler messages:
entry.S:208: Error: .previous without corresponding .section; ignored
entry.S:208: Error: .previous without corresponding .section; ignored
entry.S:209: Error: .previous without corresponding .section; ignored
entry.S:209: Error: .previous without corresponding .section; ignored
entry.S:216: Error: .previous without corresponding .section; ignored
entry.S:216: Error: .previous without corresponding .section; ignored
entry.S:218: Error: .previous without corresponding .section; ignored
entry.S:218: Error: .previous without corresponding .section; ignored
entry.S:219: Error: .previous without corresponding .section; ignored
entry.S:219: Error: .previous without corresponding .section; ignored
entry.S:220: Error: .previous without corresponding .section; ignored
entry.S:220: Error: .previous without corresponding .section; ignored
make[1]: *** [entry.o] Error 1
make[1]: Leaving directory `/usr/src/sgi/linux/arch/mips/kernel'
make: *** [linuxsubdirs] Error 2

I'm using the gcc that's up on ftp.linux.sgi.com, and I'm using binutils
2.8.1, which is the latest I believe.

_PLEASE_ can someone who is able to succesfully cross compile kernels post
here what versions they are using, and where I can get them from. Not
sorting this out brings my development efforts to a complete stop. 

- Alex

---

From: Miguel de Icaza <[email-masked]>
Date: Tue, 2 Sep 1997 18:58:22 -0500

> Well, I would try that patch, but I am unable to compile kernels because I

Probably you missed my post and Ralf's post on this issue. 

> 2.8.1, which is the latest I believe.

You need to get the binutils tar file as it was made available on
ftp.linux.sgi.com, not the cross-compiler kit, nor the 2.8.1 release
from the FSF.  

> sorting this out brings my development efforts to a complete stop. 

berenice-origin32$ mips-linux-as --version
GNU assembler version 2.7 (mips-linux), using BFD version 2.7

berenice-origin32$ mycc --version
2.7.2

But then, those versions are not really the stock GNU versions, they
are the ones available in ftp.linux.sgi.com

Cheers,
Miguel.

---

From: Alex deVries <[email-masked]>
Date: Wed, 3 Sep 1997 01:44:34 -0400 (EDT)

> ftp.linux.sgi.com, not the cross-compiler kit, nor the 2.8.1 release

Okay, I'm getting closer.

I believe the correct version is binutils-2.7.tar.gz, patched with
ftp://ftp.linux.sgi.com/pub/src/binutils/binutils-2.7-4.diff.gz.  I'd have
used the patch for binutils-2.7.0.6, but I can't find the original
anywhere.

I did a ./configure --target=mips-big-linux (since mips-unknown-linux
produces a functional little endian binutils, which is useless for my
Indy).

I end up with this error when I compile binutils:

gcc -O2    -g  -DTARGET_BYTES_BIG_ENDIAN  -o as.new targ-cpu.o
obj-format.o atof-targ.o app.o as.o atof-generic.o bignum-copy.o cond.o
expr.o flonum-konst.o flonum-copy.o flonum-mult.o frags.o hash.o
input-file.o input-scrub.o literal.o messages.o output-file.o read.o
subsegs.o symbols.o write.o listing.o ecoff.o stabs.o sb.o macro.o
e-mipself.o  -L.../opcodes -lopcodes -L../bfd -lbfd
../libiberty/libiberty.a 
targ-cpu.o: In function `md_begin':
/home/binutils-2.7/gas/targ-cpu.c:826: undefined reference to
`bfd_mips_elf_swap_options_out'
targ-cpu.o: In function `mips_elf_final_processing':
/home/binutils-2.7/gas/targ-cpu.c:7863: undefined reference to
`bfd_mips_elf32_swap_reginfo_out'
/home/binutils-2.7/gas/targ-cpu.c:7879: undefined reference to
`bfd_mips_elf64_swap_reginfo_out'
make[1]: *** [as.new] Error 1
make[1]: Leaving directory `/home/binutils-2.7/gas'
make: *** [all-gas] Error 2

NB:  There's no problem with compiling with --target=mips-unknown-linux.

Ideas?  How have other people gotten around this?

Thanks for getting me started again, Miguel.

- Alex

---

From: Eric Kimminau <[email-masked]>
Date: Wed, 03 Sep 1997 09:43:34 -0400

Does anyone have a built kernel with this patch applied?

Thanks!
                  Eric.

-- 
Eric Kimminau                           System Engineer/RSA
[email-masked]                     Silicon Graphics, Inc
Voice: (248) 848-4455                   39001 West 12 Mile Rd.
Fax:   (248) 848-5600                   Farmington, MI 48331-2903

                 VNet Extension - 6-327-4455
              "I speak my mind and no one else's."
       http://www.dcs.ex.ac.uk/~aba/rsa/perl-rsa-sig.html

    When confronted by a difficult problem, solve it by reducing 
    it to the question, "How would the Lone Ranger handle this?"

Windows 95: n.
    32 bit extensions and a graphical shell for a 16 bit patch to an
    8 bit operating system originally coded for a 4 bit microprocessor,
    written by a 2 bit company that can't stand 1 bit of competition.

    Author unknown.

---

From: Mike Shaver <[email-masked]>
Date: Thu, 4 Sep 1997 16:25:44 -0400 (EDT)

> Try this patch to linux/arch/mips/sgi/prom/cmdline.c:

Fixed it for me.  Thanks.

I'll commit that to the tree and put a new kernel up on
ftp.linux.sgi.com.

Mike

-- 
#> Mike Shaver ([email-masked]) Ingenia Communications Corporation 
#>      Chief System Architect -- will tame sendmail(8) for food       
#>                                                                     
#> "You are a very perverse individual, and I think I'd like to get to 
#>  know you better." --- [email-masked]