@ -18,8 +18,6 @@
# define C O N F I G _ S Y S _ M I P S _ C A C H E _ M O D E C O N F _ C M _ C A C H A B L E _ N O N C O H E R E N T
# endif
# define I N D E X _ B A S E C K S E G 0
.macro f_fill64 dst, o f f s e t , v a l
LONG_ S \ v a l , ( \ o f f s e t + 0 * L O N G S I Z E ) ( \ d s t )
LONG_ S \ v a l , ( \ o f f s e t + 1 * L O N G S I Z E ) ( \ d s t )
@ -256,7 +254,7 @@ l2_probe_done:
/ *
* Now c l e a r t h a t m u c h m e m o r y s t a r t i n g f r o m z e r o .
* /
PTR_ L I a0 , C K S E G 1
PTR_ L I a0 , C K S E G 1 A D D R ( C O N F I G _ M I P S _ C A C H E _ I N D E X _ B A S E )
PTR_ A D D U a1 , a0 , v0
2 : PTR_ A D D I U a0 , 6 4
f_ f i l l 6 4 a0 , - 6 4 , z e r o
@ -272,7 +270,7 @@ l2_probe_done:
bnez R _ L 2 _ B Y P A S S E D , l 1 _ i n i t
l2_init :
PTR_ L I t 0 , I N D E X _ B A S E
PTR_ L I t 0 , C K S E G 0 A D D R ( C O N F I G _ M I P S _ C A C H E _ I N D E X _ B A S E )
PTR_ A D D U t 1 , t 0 , R _ L 2 _ S I Z E
1 : cache I N D E X _ S T O R E _ T A G _ S D , 0 ( t 0 )
PTR_ A D D U t 0 , t 0 , R _ L 2 _ L I N E
@ -308,16 +306,16 @@ l1_init:
* Initialize t h e I - c a c h e f i r s t ,
* /
blez R _ I C _ S I Z E , 1 f
PTR_ L I t 0 , I N D E X _ B A S E
PTR_ L I t 0 , C K S E G 0 A D D R ( C O N F I G _ M I P S _ C A C H E _ I N D E X _ B A S E )
PTR_ A D D U t 1 , t 0 , R _ I C _ S I Z E
/* clear tag to invalidate */
cache_ l o o p t 0 , t 1 , R _ I C _ L I N E , I N D E X _ S T O R E _ T A G _ I
# ifdef C O N F I G _ S Y S _ M I P S _ C A C H E _ I N I T _ R A M _ L O A D
/* fill once, so data field parity is correct */
PTR_ L I t 0 , I N D E X _ B A S E
PTR_ L I t 0 , C K S E G 0 A D D R ( C O N F I G _ M I P S _ C A C H E _ I N D E X _ B A S E )
cache_ l o o p t 0 , t 1 , R _ I C _ L I N E , F I L L
/* invalidate again - prudent but not strictly neccessary */
PTR_ L I t 0 , I N D E X _ B A S E
PTR_ L I t 0 , C K S E G 0 A D D R ( C O N F I G _ M I P S _ C A C H E _ I N D E X _ B A S E )
cache_ l o o p t 0 , t 1 , R _ I C _ L I N E , I N D E X _ S T O R E _ T A G _ I
# endif
sync
@ -340,18 +338,18 @@ l1_init:
* then i n i t i a l i z e D - c a c h e .
* /
1 : blez R _ D C _ S I Z E , 3 f
PTR_ L I t 0 , I N D E X _ B A S E
PTR_ L I t 0 , C K S E G 0 A D D R ( C O N F I G _ M I P S _ C A C H E _ I N D E X _ B A S E )
PTR_ A D D U t 1 , t 0 , R _ D C _ S I Z E
/* clear all tags */
cache_ l o o p t 0 , t 1 , R _ D C _ L I N E , I N D E X _ S T O R E _ T A G _ D
# ifdef C O N F I G _ S Y S _ M I P S _ C A C H E _ I N I T _ R A M _ L O A D
/* load from each line (in cached space) */
PTR_ L I t 0 , I N D E X _ B A S E
PTR_ L I t 0 , C K S E G 0 A D D R ( C O N F I G _ M I P S _ C A C H E _ I N D E X _ B A S E )
2 : LONG_ L z e r o , 0 ( t 0 )
PTR_ A D D U t 0 , R _ D C _ L I N E
bne t 0 , t 1 , 2 b
/* clear all tags */
PTR_ L I t 0 , I N D E X _ B A S E
PTR_ L I t 0 , C K S E G 0 A D D R ( C O N F I G _ M I P S _ C A C H E _ I N D E X _ B A S E )
cache_ l o o p t 0 , t 1 , R _ D C _ L I N E , I N D E X _ S T O R E _ T A G _ D
# endif
3 :