Subject: Re: News from the weird
To: Olivier GALIBERT <Olivier.Galibert@mines.u-nancy.fr>
From: Allen Briggs <briggs@puma.bevd.blacksburg.va.us>
List: port-mac68k
Date: 02/26/1996 23:46:46
> - An unexpected trap on the 040 is 90% of the time a badly
>   handled bus error. The handling code is broken, and since
>   I don't know 040 stack frames nor do I have any doc about
>   them I can't fix it.

Do you have some indications, at least, as to where the problem might
lie?  Like what kind of bus error might cause an unexpected trap?

> - The io mapping is broken. In fact, I think it's a matter of luck
>   that macbsd works. Here is the problem :

Not quite a matter of luck.  On the early macs, at least, the physical
I/O addresses loop 16 times over the same memory in the range 0x50000000
to 0x51000000.  That is, those 4 bits (20-23) of the address are ignored.
The Dev notes say that I/O space starts at 0x50000000, but the MacOS uses
a base of 0x50f00000 and in some systems even maps the lower memory
addresses as invalid.

I've taken your suggestion and removed the references to INTIOBASE and
replaced the pmap_bootstrap.c reference with IOBase.  This code has gone
through a couple of permutations...

> Speaking of IDE the first version of the driver is nearly finished
> (synchronous access, one sector a time, but it works).

Great!  Are you using the wd driver from the x86 or the amiga(?)?  It
might be possible to leverage off those quite a bit, and it might even
be possible and desirable to have one IDE driver for all NetBSD/IDE
systems.

> PS: Ok it's a long letter but when I find a bug I feel important in others
>     code.  I think I have to justify what I say.

Don't apologize.  A letter like that is always the best kind.  I'm more
likely to admit a mistake if you prove to me that it was one.  ;-)

-allen

-- 
  Allen Briggs - end killing - briggs@bev.net ** MacBSD == NetBSD/mac68k **
   Where does all my time go?  <a href="http://www.netbsd.org/">Guess.</a>