From owner-freebsd-hackers Tue Mar 4 15:37:56 2003 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C4CEB37B405 for ; Tue, 4 Mar 2003 15:37:54 -0800 (PST) Received: from digitaldaemon.com (digitaldaemon.com [63.105.9.34]) by mx1.FreeBSD.org (Postfix) with SMTP id 1ED3A43F85 for ; Tue, 4 Mar 2003 15:37:53 -0800 (PST) (envelope-from jan@digitaldaemon.com) Received: (qmail 28382 invoked from network); 4 Mar 2003 23:36:17 -0000 Received: from unknown (HELO digitaldaemon.com) (192.168.0.220) by digitaldaemon.com with SMTP; 4 Mar 2003 23:36:17 -0000 Message-ID: <3E653A08.7090107@digitaldaemon.com> Date: Tue, 04 Mar 2003 18:43:04 -0500 From: Jan Knepper Organization: http://www.digitaldaemon.com/ User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3b) Gecko/20030210 X-Accept-Language: en-us, en MIME-Version: 1.0 To: "M. Warner Losh" Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: 'ticks' in kernel. References: <3E64E941.3030205@digitaldaemon.com> <20030304.104403.34570707.imp@bsdimp.com> <3E64F7B2.9040008@digitaldaemon.com> <20030304.154113.90196009.imp@bsdimp.com> In-Reply-To: <20030304.154113.90196009.imp@bsdimp.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG M. Warner Losh wrote: >In message: <3E64F7B2.9040008@digitaldaemon.com> > Jan Knepper writes: >: How would they return me the 'value' of 'ticks'? >: >: The problem is... I have a value's somewhere that has been assigned from >: 'ticks', like: >: ptr -> value = ticks; >: >: at an other moment I need to do something like... >: >: age = boottime + ( ticks - ptr -> value ) / factor; >: >: The problem in the second case however is that I can not seem to get to >: 'ticks' as it is userland code... > >ptr->value should be set with getmicrotime() or microtime(). You can >then do a gettimeofday in userland to figure out the age. > I agree with you. Except that ptr->value is tcpcb->t_starttime which is being set in the kernel... For the rest, see my other email that I forgot (but now did) sent to the group. Thanks for the help though. Jan To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message