Re: spontaneous reboot only once after power-up

[email protected] (ITOH Yasufumi)
Newsgroups gmane.os.netbsd.ports.dreamcast,gmane.os.netbsd.ports.sh3
Message-ID <[email protected]>
In article <[email protected]>
[email protected] writes:

> In article <[email protected]>
> [email protected] wrote:
> 
> > I'm going to commit this change to work around it.
>  :
> > +	_reg_write_4(SH4_ITLB_DA1, 0);
> > +	_reg_write_4(SH4_ITLB_DA1 | (1 << SH4_ITLB_E_SHIFT), 0);
> > +	_reg_write_4(SH4_ITLB_DA1 | (2 << SH4_ITLB_E_SHIFT), 0);
> > +	_reg_write_4(SH4_ITLB_DA1 | (3 << SH4_ITLB_E_SHIFT), 0);
> 
> It seems these four statements should be in __sh4_itlb_invalidate_all(),
> rather than sh4_tlb_invalidate_all().

I think that VPN / PPN addresses which are not aligned to SZ boundary
caused the problem.
Valid entries are aligned to page size, and this initialization is needed
only once during boot process.

> BTW, __sh4_itlb_invalidate_all() should be declared as static, not extern?

Agreed.

-- 
ITOH Yasufumi
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.