> didnt drop the GLOCK.  if you keep afs_getevent from dropping the lock
> there is no reason that afs_getevent and afs_addevent cant be merged back
> together.

I guess it finally boils down to whether or not it is possible to
have a version of linux_alloc() that does not drop GLOCK.



                                                                                       
                                                
                      chas williams                                                    
                                                
                      <[EMAIL PROTECTED]        To:       Srikanth 
Vishwanathan/India/IBM@IBMIN                                         
                      y.mil>                   cc:       "openafs-devel" 
<[EMAIL PROTECTED]>, [EMAIL PROTECTED]  
                                               Subject:  Re: [OpenAFS-devel] 
afs_osi_Sleep and afs_osi_Wakeup on Linux                 
                      06/04/2002 03:14                                                 
                                                
                      PM                                                               
                                                
                      Please respond to                                                
                                                
                      chas williams                                                    
                                                
                                                                                       
                                                
                                                                                       
                                                



In message <[EMAIL PROTECTED]>,"Srikanth
Vishw
anathan" writes:
>If afs_getevent() returns NULL, sleep will return prematurely. But this
>is no different from a spurious wakeup. The caller makes sure that sleep
>is called in a "while(condition not satisfied) sleep" loop that takes
>care of this.

the while() does handle the condition for a spurious wakeup.  i believe
all the parts have been found in the afs code that dont loop but you
never know.

however, it probably is still not a good idea to drop the GLOCK during
afs_addevent().  since your previous race was related to GLOCK's being
droppped too soon, it would probably be best if afs_addevent/afs_getevent
didnt drop the GLOCK.  if you keep afs_getevent from dropping the lock
there is no reason that afs_getevent and afs_addevent cant be merged back
together.




_______________________________________________
OpenAFS-devel mailing list
[EMAIL PROTECTED]
https://lists.openafs.org/mailman/listinfo/openafs-devel

Reply via email to