From owner-freebsd-current@FreeBSD.ORG Tue Jul 27 15:19:44 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B98BD16A4CE for ; Tue, 27 Jul 2004 15:19:44 +0000 (GMT) Received: from hak.cnd.mcgill.ca (hak.cnd.mcgill.ca [132.216.11.133]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4B9D243D5E for ; Tue, 27 Jul 2004 15:19:44 +0000 (GMT) (envelope-from mat@hak.cnd.mcgill.ca) Received: from hak.cnd.mcgill.ca (localhost [127.0.0.1]) by hak.cnd.mcgill.ca (8.12.9/8.12.8) with ESMTP id i6RFNRKJ003014; Tue, 27 Jul 2004 11:23:27 -0400 (EDT) (envelope-from mat@hak.cnd.mcgill.ca) Received: (from mat@localhost) by hak.cnd.mcgill.ca (8.12.9/8.12.8/Submit) id i6RFNRP3003013; Tue, 27 Jul 2004 11:23:27 -0400 (EDT) Date: Tue, 27 Jul 2004 11:23:27 -0400 From: Mathew Kanner To: "Conrad J. Sabatier" , freebsd-current@freebsd.org Message-ID: <20040727152327.GA92352@cnd.mcgill.ca> References: <20040726224220.GM991@funkthat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040726224220.GM991@funkthat.com> User-Agent: Mutt/1.4.1i Organization: I speak for myself, operating in Montreal, CANADA X-Spam-Status: No, hits=0.0 required=5.0 tests=none autolearn=no version=2.62 X-Spam-Checker-Version: SpamAssassin 2.62 (2004-01-11) on hak.cnd.mcgill.ca Subject: Re: Questionable code in sys/dev/sound/pcm/channel.c X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Jul 2004 15:19:44 -0000 On Jul 26, John-Mark Gurney wrote: > Conrad J. Sabatier wrote this message on Mon, Jul 26, 2004 at 16:35 -0500: > > Why the formulaic calculation of timeout, if it's simply going to be > > unconditionally set to 1 immediately afterwards anyway? What's going on > > here? > > Well, if you look at the annotations, that absolute set of timeout was > added in rev 1.65 by cg with the comment: > tweaks to reduce latency/pauses in output > I think this has been raised on the mailling list before. IIRC, the logic for this is to check frequently for dead channels but CG is the authoriy. > > Also, at the end of the function: > > > > if (count <= 0) { > > c->flags |= CHN_F_DEAD; > > printf("%s: play interrupt timeout, channel dead\n", c->name); > > } > > > > return ret; > > } > > that was changed in rev1.52 (by cg also), and previously was just a check > for count == 0.. > > So, I'd recommend a message off to cg and ask why he made this changes... I have no clue about this one. --Mat -- We peer so suspiciously at each other that we cannot see that we Canadians are standing on the mountaintop of human wealth, freedom and privilege. - Pierre Elliott Trudeau