Thread (9 messages) 9 messages, 4 authors, 2007-11-27

Re: [RFC/PATCH] powerpc: Move CPM command handling into the cpm drivers

From: Jochen Friedrich <jochen@scram.de>
Date: 2007-11-24 17:53:47

Hi Vitaly,
quoted
quoted
+       printk(KERN_ERR "%s(): Not able to issue CPM command\n",
+               __FUNCTION__);
+       return -EIO;  
      
Do these need to be protected with a spin lock?
    
Even that might be not enough - we may have simultaneous call of this func in non-smp case...
I was thinking of some kind of refcount, so one that is going to issue CPM command, must do say pq_cpmp_get()
and another driver won't be able to mangle with cpcr while it's not done with previous request.

Yet I am not telling it was better the way it used to be - this approach looks okay but needs some efforts to defend against
deadlocks while we are at it
Wouldn't spin_lock_irqsave() prevent a deadlock?

Thanks,
Jochen
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help