Port-sparc archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: partially working SMP again



> could you try commenting the "align >>= 1;" at the end of the loop
> in pmap_bootstrap4m() to calculate desired alignment (around line
> 3645 in my tree.)

It works. But in this case, it aligns cpuinfo at 0x100000 (1MB)
while L2 cache size is 512KB (AFAIK it's direct mapped):

---
setting cpus self reference
going to pmap_kenter_pa(va=0xf0502000, pa=0x402000)
set cpu0 ci_self address: 0xf0502000
set cpu1 ci_self address: 0xf0602000
set cpu2 ci_self address: 0xf0702000
set cpu3 ci_self address: 0xf0802000
pmap_bootstrap4m done
 :
cpu0 at mainbus0: mid 8: RT620/625 @ 150 MHz, on-chip FPU
cpu0: 512K byte write-back, 32 bytes/line, sw flush: cache enabled
 :
---

> i don't understand why that is done, but it did appear in the old
> code.

It returns correct cache size so cache flush seems the right thing..

I've also tried a kernel with MULTIPROCESSOR but with only cpu0.
It doesn't fail at le0, but gets lock error again right after
audio0 is attached (i.e. interrupts are enabled?):
---
le0: 8 receive buffers, 2 transmit buffers
bpp0 at sbus0 slot 15 offset 0x4800000 level 2 (ipl 3): DMA rev 2
dbri0 at sbus0 slot 14 offset 0x10000 level 9: rev e
cgsix0 at sbus0 slot 2 offset 0x0 level 9: SUNW,501-2253, 1152 x 900, rev 11
cgsix0: attached to /dev/fb0
cgsix0: framebuffer size: 2 MB
wsdisplay1 at cgsix0 kbdmux 1
eccmemctl0 at mainbus0 ioaddr 0x0: version 0x0/0x2
cpu0: booting secondary processors:
scsibus0: waiting 2 seconds for devices to settle...
wskbd0 at kbd0 mux 1
dbri0: speakerbox detected
dbri0: cs4215 rev E found at offset 8
audio0 at dbri0: full duplex, mmap
Reader / writer lock error: rw_vector_enter: locking against myself

lock address : 0x00000000f03de31c
current cpu  :                  0
current lwp  : 0x00000000f039f700
owner/count  : 0x00000000f039f700 flags    : 0x0000000000000004

panic: lock error
Stopped in pid 0.1 (system) at  netbsd:cpu_Debugger+0x4:        or              
%o7, %g0, %g1
db{0}> tr
cpu_Debugger(0xf0372790, 0xf039f700, 0x4, 0xf039a800, 0x104, 0xf03e8000) at 
netbsd:lockdebug_abort+0x20
lockdebug_abort(0xf03de31c, 0xf039fa20, 0xf03367c8, 0xf035d7d8, 0xffffffff, 
0xffffffff) at netbsd:rw_enter+0xc0
rw_enter(0xf03de31c, 0x0, 0xf039f700, 0x0, 0x1e4000e3, 0xf03e9800) at 
netbsd:uvm_fault_internal+0xd0
uvm_fault_internal(0xf03de318, 0x0, 0x1, 0x0, 0x1e4000e4, 0xf03d84c9) at 
netbsd:mem_access_fault4m+0x500
mem_access_fault4m(0x9, 0x126, 0x3c0, 0xf0394c28, 0x1e4000e5, 0xe) at 0xf0008518
0xf0008518(0xbe08800, 0x1, 0x0, 0x0, 0x1e4007e6, 0x0) at 
netbsd:pmap_pmap_pool_ctor+0x88
pmap_pmap_pool_ctor(0x0, 0xf3bff000, 0x1, 0xf3be7bc0, 0x1e4000e7, 0xf03d853e) 
at netbsd:pool_cache_get_slow+0x148
pool_cache_get_slow(0xf03d2ac0, 0x0, 0xf0394dac, 0x0, 0x1, 0xf03d8551) at 
netbsd:pool_cache_get_paddr+0xe8
pool_cache_get_paddr(0xf03d2940, 0x1, 0x0, 0xf3be79c0, 0x1e4000e1, 0xf03d849e) 
at netbsd:pmap_create+0x10
pmap_create(0xf3bfeeec, 0x3, 0x0, 0x0, 0x1, 0xf3bfeee0) at 
netbsd:uvmspace_init+0x50
uvmspace_init(0xf3bfeee0, 0x0, 0x0, 0xf0000000, 0x1e4000e3, 0xf03d844a) at 
netbsd:uvmspace_alloc+0x28
uvmspace_alloc(0xf3bfeee0, 0xf0000000, 0xf0394f4c, 0x0, 0x1, 0xf03d86a0) at 
netbsd:uvmspace_fork+0x10
uvmspace_fork(0xf03de318, 0x0, 0x1, 0x0, 0x1e4000e5, 0xf03d86ea) at 
netbsd:uvm_proc_fork+0x24
uvm_proc_fork(0xf039f510, 0xf3bf9d20, 0x0, 0xf3be7c00, 0xf3bf9e8c, 0xf03dda04) 
at netbsd:fork1+0x36c
fork1(0xf039f700, 0x0, 0x0, 0x0, 0x1, 0xf00cf4c0) at netbsd:main+0x30c
main(0x0, 0xfffffff8, 0x0, 0x0, 0x0, 0xf0002328) at netbsd:ft_want_ast+0xf78
db{0}> 

---

Some more cache flush is required?

---
Izumi Tsutsui


Home | Main Index | Thread Index | Old Index