Subject: MO drives, Booter/Serial Console clash, etc
To: None <port-mac68k@NetBSD.ORG>
From: Nigel Pearson <nigel@ind.tansu.com.au>
List: port-mac68k
Date: 11/25/1996 17:46:43
	Hi folks. I finally got my Q840av to boot on Friday. Hooray!!!
Hans-Christian Becker was able to point out the elusive problem:

-------------------------------------------------------------------------------

* On a Q840av, there is a problem booting with Serial Console enabled.
  A typical kernel (this one is Alan's, for.hans) does the following:

NetBSD 1.2A (GENERIC) #21: Sat Nov  9 10:16:20 EST 1996
    briggs@puma:/u/home/briggs/netbsd/sys/arch/mac68k/compile/GENERIC
Apple Macintosh Quadra 840AV  (68040)
real mem = 33554432
avail mem = 29630464
using 204 buffers containing 835584 bytes of memory
mrg: kernel has no ROM vectors for this machine!
adb: using serial console
mainbus0 (root)
obio0 at mainbus0
adb0 at obio0 (ADB event device)
esp0 at obio0: address 0x898000: NCR53C96 25Mhz, target 7
scsibus0 at esp0
sd0 at scsibus0 targ 2 lun 0: <HP, C2247, 0BC4> SCSI2 0/direct fixed
sd0: 1003MB, 2051 cyl, 13 head, 77 sec, 512 bytes/sec
cd0 at scsibus0 targ 3 lun 0: <MATSHITA, CD-ROM CR-8008, 8.0e> SCSI2 5/cdrom rem
ovable
sd1 at scsibus0 targ 6 lun 0: <QUANTUM, CTS40S, 4.07> SCSI2 0/direct fixed
sd1: 40MB, 1536 cyl, 1 head, 53 sec, 512 bytes/sec
zsc0 at obio0 chip type 0
zstty0 at zsc0 channel 0
zstty1 at zsc0 channel 1 (console)
fpu0 at obio0 (mc68040)
nubus0 at mainbus0
root on sd1a swap on sd1b
PRAM time does not appear to have been read correctly.
PRAM: 0x83da4f80, macos_boottime: 0x328d9938.
init: not found
panic: no init
Stopped at      _Debugger+0x6:  unlk    a6
db>

	If Serial Console is turned off, the mrg: and adb: messages appear
they should:

mrg: 'Quadra AV ROMs' ROM glue, tracing off, debug off, silent traps
mrg: I/O map kludge for ROMs that use hardware addresses directly.
adb: bus subsystem
Got following HwCfgFlags: 0xfc00, 0x4900081f, 0x 300bf26, 0x  9393b8
mrg: setup_egret:
mrg: setup_egret: done.
adb: mapped device (5) at 2
adb: 200 dpi mouse at 3

-------------------------------------------------------------------------------

	I also bought a new toy on the weekend, a Fujitsu 230MB Magneto
Optical drive. To see if it was possible, I tried to install base12, etc12,
comp12 and a kernel onto, and then boot off of, an optical cartridge.

	The good news is that it is possible, but I wouldn't recommend it ;-)
What, with trying to get the partition geometry right, and over 4 hours
to install the packages (MO drives are slow for lots of small writes,
like when the installer has to update directory entries after each file gets
un-tarred [1]), it took me nearly a day. But, at the end, it actually booted,
with just a few kernel messages complaining about not being able to determine
the drive geometry. It was about half the speed of my slow 40MB drive.

[1] Possible booter improvement, have an unsafe (cacheing) mode
    which writes a few [MB of?] files at a time, and then updates
    the filesystem or directory information.

-------------------------------------------------------------------------------

	Now that I have a good working system, I'm going to start stealing
the drivers from the MkLinux source (I found drivers for NCR53C94 and Cuda
chips) and patching them into the kernel.

* Anyone know of the differences between the 53C94 (which the Quadra 660av
  and 840av machines have) and the 53C96 (which the other Quadras use)?

* I know Steve Campbell FTP'd AMD's technical docs for the 53C96.
  Does the same site have 53C94 docs?

* I read on the Mac Linux page that source code from our kernel is deemed
  not acceptable for distribution by the Linux maintainers, and that the
  code from the MkLinux src may not be either. Is Linus just being choosy?

* Does anyone know what the story might be if I, say, used cuda.c from
  MkLinux src? The file header says that it can be distributed if the headers
  remain intact. (and they actually used some early NetBSD ioctl code, the
  copyright headers are still there!)
  Can we subsequently modify and re-distribute?

-- 
| Nigel Pearson, nigel@ind.tansu.com.au |"so we came up with a golden rule   |
|     Telstra IN Platforms,  Sydney     | whatever works for you             |
| Office: 9206 3468    Fax:  9281 1301  | so we started up a whole new school|
| Mobile: 014 611 322  Home: 9579 3293  | where nothing's absolute" C.Peacock|