/* push page in both caches */ /* RZ: cpush %bc DOES invalidate %ic, regardless of DPI */ staticinlinevoid push040(unsignedlong paddr)
{ asmvolatile ( "nop\n\t" ".chip 68040\n\t" "cpushp %%bc,(%0)\n\t" ".chip 68k"
: : "a" (paddr));
}
/* push and invalidate page in both caches, must disable ints
* to avoid invalidating valid data */ staticinlinevoid pushcl040(unsignedlong paddr)
{ unsignedlong flags;
local_irq_save(flags);
push040(paddr); if (CPU_IS_060)
clear040(paddr);
local_irq_restore(flags);
}
/* *040:Hiteverypagecontaininganaddressintherangepaddr..paddr+len-1. *(LoworderbitsoftheeaofaCINVP/CPUSHPare"don'tcare"s). *Hiteverypageuntilthereisapageorlesstogo.Hitthenextpage, *andtheoneafterthatiftherangehitsit.
*/ /* ++roman: A little bit more care is required here: The CINVP instruction *invalidatescacheentriesWITHOUTWRITINGDIRTYDATABACK!Sothebeginning *andtheendoftheregionmustbetreateddifferentlyiftheyarenot *exactlyatthebeginningorendofapageboundary.Else,maybetoomuch *databecomesinvalidatedandthuslostforever.CPUSHPdoeswhatweneed: *itinvalidatesthepageafterpushingdirtydatatomemory.(ThankstoJes *fordiscoveringtheproblem!)
*/ /* ... but on the '060, CPUSH doesn't invalidate (for us, since we have set *theDPIbitintheCACR;woulditcauseproblemswithtemporarilychanging *this?).Sowehavetopushfirstandthenadditionallytoinvalidate.
*/
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.