As I said, I removed that SEM_DESTROY(&hd->sd_wiocing) call
from lis_strdoioctl() and that seemingly solved the problem.
Test is running, I'm watching it. So far so good.

>> Do we really need to call SEM_DESTROY(&hd->sd_wiocing) ?
> No.  But the case that you cite above would lead to over-incrementing 
> of the semaphore counter.  That would have to be corrected for by
> calling lis_sem_init() at the beginning of each ioctl operation. 

That lis_sem_init()  is called every time in the
current lis_strdoioctl() anyway:


lis_sem_init(&hd->sd_wiocing, 0) ;<-------------                           
SET_SD_FLAG(hd,IOCWAIT);            /* for strrput */        
CLOCKADD() ;                        /* exclude driver time */
CP(hd,0) ;   
lis_putnext(hd->sd_wq,mioc);        /* do not use PUTNEXT */ 
CLOCKON() ;           
CP(hd,0) ;                                                   
mioc=NULL;     
CLOCKADD() ;   
CP(hd,0) ;
err = lis_wait_for_wiocing(hd,ioc->ic_timout) ;              
               
SEM_DESTROY(&hd->sd_wiocing) ; <------- I removed that call


__________________________________________________________________
Introducing the New Netscape Internet Service. 
Only $9.95 a month -- Sign up today at http://isp.netscape.com/register

Netscape. Just the Net You Need. 

New! Netscape Toolbar for Internet Explorer
Search from anywhere on the Web and block those annoying pop-ups.
Download now at http://channels.netscape.com/ns/search/install.jsp
_______________________________________________
Linux-streams mailing list
[EMAIL PROTECTED]
http://gsyc.escet.urjc.es/mailman/listinfo/linux-streams

Reply via email to