Port-powerpc archive

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

when and how to enable caches



Hi,

I'm work on amigappc these days and I'm facing a big problem with the
caches. I cannot enable them without making the system crash. I tried it at
two places in locore: directly in the beginning, and between initppc() and
main(). In both cases the system does not survive cache-enable (yes, I am
sure that the system crashes exactly there).

This is how I invalidate and enable the caches:
    mfspr   9,1008
    ori 9,9,HID0_DCE
    ori 8,9,HID0_DCFI
    sync
    mtspr   1008,8          /* d-cache invalidate */
    mtspr   1008,9          /* d-cache enable */
    isync
    mfspr   9,1008
    ori 9,9,HID0_ICE
    ori 8,9,HID0_ICFI
    isync
    mtspr   1008,8          /* i-cache invalidate */
    mtspr   1008,9          /* i-cache enable */

locore is entered with caches disabled, MMU disabled, BATs and SRs
invalidated. MSR has only the IP-bit set.

Anybody remembers a similar problem? Any idea what I could check or try?

-- 
    _  Frank Wille (frank%phoenix.owl.de@localhost)
 _ //  http://sun.hasenbraten.de/~frank/
 \X/   Phx @ #AmigaGer



Home | Main Index | Thread Index | Old Index