Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Feb 2009 14:10:05 GMT
From:      Takahiro Kurosawa <takahiro.kurosawa@gmail.com>
To:        freebsd-emulation@FreeBSD.org
Subject:   Re: kern/131506: pipes in forked procs sometimes hang under Linux  emulation 2.6.16
Message-ID:  <200902181410.n1IEA5Vq060807@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/131506; it has been noted by GNATS.

From: Takahiro Kurosawa <takahiro.kurosawa@gmail.com>
To: Kostik Belousov <kostikbel@gmail.com>
Cc: bug-followup@freebsd.org
Subject: Re: kern/131506: pipes in forked procs sometimes hang under Linux 
	emulation 2.6.16
Date: Wed, 18 Feb 2009 23:08:05 +0900

 2009/2/18 Kostik Belousov <kostikbel@gmail.com>:
 
 > Please, resend the patch without base64-encoding, best as a plain/text
 > attachment.
 
 Sure.  Sending the patch inline...
 The attachment of my previous mail looks broken to me too.
 
 === sys/amd64/linux32/linux32_machdep.c
 ==================================================================
 --- sys/amd64/linux32/linux32_machdep.c	(revision 188741)
 +++ sys/amd64/linux32/linux32_machdep.c	(local)
 @@ -560,7 +560,7 @@
  	/* wait for the children to exit, ie. emulate vfork */
  	PROC_LOCK(p2);
  	while (p2->p_flag & P_PPWAIT)
 -	   	msleep(td->td_proc, &p2->p_mtx, PWAIT, "ppwait", 0);
 +		cv_wait(&p2->p_pwait, &p2->p_mtx);
  	PROC_UNLOCK(p2);
 
  	return (0);
 @@ -749,7 +749,7 @@
  		/* wait for the children to exit, ie. emulate vfork */
  		PROC_LOCK(p2);
  		while (p2->p_flag & P_PPWAIT)
 -			msleep(td->td_proc, &p2->p_mtx, PWAIT, "ppwait", 0);
 +			cv_wait(&p2->p_pwait, &p2->p_mtx);
  		PROC_UNLOCK(p2);
  	}
 
 === sys/i386/linux/linux_machdep.c
 ==================================================================
 --- sys/i386/linux/linux_machdep.c	(revision 188741)
 +++ sys/i386/linux/linux_machdep.c	(local)
 @@ -376,7 +376,7 @@
  	/* wait for the children to exit, ie. emulate vfork */
  	PROC_LOCK(p2);
  	while (p2->p_flag & P_PPWAIT)
 -	   	msleep(td->td_proc, &p2->p_mtx, PWAIT, "ppwait", 0);
 +		cv_wait(&p2->p_pwait, &p2->p_mtx);
  	PROC_UNLOCK(p2);
 
  	return (0);
 @@ -581,7 +581,7 @@
     	   	/* wait for the children to exit, ie. emulate vfork */
     	   	PROC_LOCK(p2);
  		while (p2->p_flag & P_PPWAIT)
 -   		   	msleep(td->td_proc, &p2->p_mtx, PWAIT, "ppwait", 0);
 +			cv_wait(&p2->p_pwait, &p2->p_mtx);
  		PROC_UNLOCK(p2);
  	}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200902181410.n1IEA5Vq060807>