Date: Fri, 03 Jan 2003 22:06:27 +0100 From: phk@freebsd.org To: Bruce Evans <bde@zeta.org.au> Cc: Alfred Perlstein <bright@mu.org>, cvs-committers@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/sys/fs/fifofs fifo_vnops.c Message-ID: <2196.1041627987@critter.freebsd.dk> In-Reply-To: Your message of "Fri, 03 Jan 2003 22:21:31 %2B1100." <20030103213903.I2945-100000@gamplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <20030103213903.I2945-100000@gamplex.bde.org>, Bruce Evans writes: >On Thu, 2 Jan 2003, Alfred Perlstein wrote: > >> 216 if (ap->a_mode & FWRITE) { >> 217 fip->fi_writers++; >> 218 if (fip->fi_writers == 1) { >> 219 fip->fi_readsock->so_state &= ~SS_CANTRCVMORE; >> 220 if (fip->fi_readers > 0) { >> 221 wakeup((caddr_t)&fip->fi_readers); >> 222 sorwakeup(fip->fi_writesock); >> 223 } >> 224 } >> 225 } >> >> This this code is confusing because we have a producer consumer >> relationship between readers and writers. I think that the problem >> is that in this section of code the wakeup should be on fi_writers. > >Certainly not. There is only 1 writer (ourself), and we must wake up >the readers. I can confim this. I have been running with Alfreds suggested change and without the timeout and I just got the hang: setrootbyname failed NFS ROOT: 212.242.86.145:/bang/syv Interface fxp0 IP-Address 212.242.86.130 Broadcast 212.242.86.159 Loading configuration files. hw.bus.devctl_disable: 0 -> 1 Entropy harvesting: interrupts ethernet point_to_point. lock order reversal 1st 0xc414c788 process lock (process lock) @ ../../../kern/kern_descrip.c:2099 2nd 0xc414b234 filedesc structure (filedesc structure) @ ../../../kern/kern_descrip.c:2106 Debugger("witness_lock") Stopped at Debugger+0x54: xchgl %ebx,in_Debugger.0 db> cont Configuring CCD devices. ccdconfig: /dev/ad2s1g: No such file or directory Starting file system checks: nfs: can't update /var/db/mounttab for 212.242.86.145:/bang/syv +++ populate /var using /etc/mtree/BSD.var.dist +++ create log files based on the contents of /etc/newsyslog.conf +++ create lastlog load: 0.30 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.30 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.30 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.30 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.30 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.30 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.30 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.30 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.27 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k load: 0.27 cmd: sendmail 100 [fifoow] 0.00u 0.09s 0% 1808k ^C ^C^C^C -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?2196.1041627987>