Subject: Re: sparc/dev/sbus.c rev 1.43 problem
To: Valeriy E. Ushakov <uwe@ptc.spbu.ru>
From: Juergen Hannken-Illjes <hannken@eis.cs.tu-bs.de>
List: port-sparc
Date: 12/29/2001 14:06:37
> On Sat, Dec 29, 2001 at 13:29:47 +0100, Juergen Hannken-Illjes wrote:
> 
> > All my kernels with rev 1.43 of sys/arch/sparc/dev/sbus.c get:
> > 
> > 	cpu0: NMI: system interrupts: 40000000<VME=0,SBUS=0,ME>
> > 	trap type 0x29: pc=0xa1594 npc=0xa1598 psr=4000084<S>
> > 	trap type 0x29: pc=0xf0008410 npc=0xf0008414 psr=44000c0<S,PS>
> > 	kernel: trap trap
> > 	Stopped in pid 212 (Xsun) at Lbcopy_doubles: ldd [%o0 + %g0], %o4
> 
> Did Xsun worked with previous revision of the file?  (I think Xsun has
> been broken since bus_space_mmap changed signature as it was not
> really converted, the method was stubbed out just to get the kernel
> compiling).

A -current kernel works fine if I use rev 1.42.

> > 	cgthree0 at sbus0 slot 0 offset 0x0 level 9: SUNW,501-1718, 1152 x 900
> > 
> > Tracing sbus_bus_mmap I get (args and result):
> > 
> > before t=0xf0508f60 baddr=30000000 off=8fd000 prot=2 flags=2 => 308fd004
> > after	 t=0xf0275ba8 baddr=60000000 off=8fd000 prot=2 flags=2 => 608fd004
> 
> Sorry?  Before and after what?

before your change sparc/sparc/machdep.c::sbus_bus_mmap was called as:

	sbus_bus_mmap(t=0xf0508f60 baddr=30000000 off=8fd000 prot=2 flags=2)

and returned 308fd004.


Now sparc/dev/sbus.c::sbus_bus_mmap gets called with the same arguments:

	sbus_bus_mmap(t=0xf0508f60 baddr=30000000 off=8fd000 prot=2 flags=2)

sets paddr to 60000000 and calls sparc/sparc/machdep.c::sbus_bus_mmap as:

	sbus_bus_mmap(t=0xf0275ba8 baddr=60000000 off=8fd000 prot=2 flags=2)

and returns 608fd004.

> Hmm, baddr 3000.0000 looks right for slot 0 offset 0.  Leading '6'
> would be slot 3.  Can you please give me more details?
> 
> SY, Uwe
> -- 
> uwe@ptc.spbu.ru                         |       Zu Grunde kommen
> http://www.ptc.spbu.ru/~uwe/            |       Ist zu Grunde gehen
> 


-- 
Juergen Hannken-Illjes - hannken@eis.cs.tu-bs.de - TU Braunschweig (Germany)