From owner-freebsd-current@FreeBSD.ORG Thu Jan 26 18:50:56 2012 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5F21E106566B for ; Thu, 26 Jan 2012 18:50:56 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: from onelab2.iet.unipi.it (onelab2.iet.unipi.it [131.114.59.238]) by mx1.freebsd.org (Postfix) with ESMTP id 271178FC12 for ; Thu, 26 Jan 2012 18:50:55 +0000 (UTC) Received: by onelab2.iet.unipi.it (Postfix, from userid 275) id E1F267300A; Thu, 26 Jan 2012 20:08:17 +0100 (CET) Date: Thu, 26 Jan 2012 20:08:17 +0100 From: Luigi Rizzo To: current@freebsd.org Message-ID: <20120126190817.GA73310@onelab2.iet.unipi.it> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i Cc: Subject: timeouts too long bug again... X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 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: Thu, 26 Jan 2012 18:50:56 -0000 In sep.2009 i noticed that usleep() select() and friends (including the in-kernel callouts) would consistently take one tick longer than they should, and committed a fix to sys/kern/kern_timeout.c to HEAD and RELENG_8 http://svnweb.freebsd.org/base?view=revision&revision=197137 http://svnweb.freebsd.org/base?view=revision&revision=200510 Now it seems that the bug is there again, in some form: on 9.0 (and someone reported this also no HEAD) the minimum sleep interval is now 2 ticks. Callouts seem to be correct (at least, dummynet delays are exact, and the sysctl net.inet.ip.dummynet.tick_adjustment: 2770 now does not grow at 500 HZ as it did in the past. Any idea on what might have reintroduced the problem ? (please spare us the story that usleep gives no guarantees etc etc - we all know that, but FreeBSD is consistently 1 tick above the minimum guaranteed interval) cheers luigi