[Cbe-oss-dev] [PATCH] spufs: Avoid restarting MFC in context	saving
    Jeremy Kerr 
    jk at ozlabs.org
       
    Tue Jul  3 18:00:37 EST 2007
    
    
  
Asayama-san,
Nice catch!
> The current SPU context saving procedure in SPUFS unexpectedly
> restarts MFC when halting decrementer, because MFC_CNTL[Dh] is set
> without MFC_CNTL[Sm].
From reading the CBEA docs, the Dh bit is independent from the Sm bit, 
so I think we should keep them separate, rather than setting both in 
halt_mfc_decr(). Perhaps this bit should be set in suspend_mfc(). Or we 
could just set it in init_priv() and leave it set.
> This bug causes, for example, saving broken DMA  queues.
Could you elaborate on what you've seen happen? I assume the DMA queues 
have continued to be processed during the context switch?
Do you have a testcase that I can use to confirm the fix?
> +#define MFC_CNTL_SUSPEND_DMA_QUEUE_DISABLED	(1ull << 4)
The docs call this a 'Suspend Mask' (setting this bit doesn't 
disbale/suspend the queue, it's the mask for the 0x1 bit). How about 
MFC_CNTL_SUSPEND_MASK?
Cheers,
Jeremy
    
    
More information about the cbe-oss-dev
mailing list