Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Nov 2011 22:08:15 +0100
From:      Hans Petter Selasky <hselasky@c2i.net>
To:        mdf@freebsd.org
Cc:        "svn-src-head@freebsd.org" <svn-src-head@freebsd.org>, "svn-src-all@freebsd.org" <svn-src-all@freebsd.org>, "src-committers@freebsd.org" <src-committers@freebsd.org>
Subject:   Re: svn commit: r227541 - head/sys/dev/usb/controller
Message-ID:  <201111152208.15443.hselasky@c2i.net>
In-Reply-To: <CAMBSHm_Hs1rhNTb2Fp_MU0Wzkrom721oJjzDaqe8sArp6FFivg@mail.gmail.com>
References:  <201111152048.pAFKmvNC016452@svn.freebsd.org> <CAMBSHm_Hs1rhNTb2Fp_MU0Wzkrom721oJjzDaqe8sArp6FFivg@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tuesday 15 November 2011 21:54:28 mdf@freebsd.org wrote:
> Is there some reason these functions aren't asking for a delay in
> terms of milli- or microseconds, and converting to hz internally?

There is no strong reason for this except, that when everything is computed in 
system ticks, there is no need for further conversion when interfacing to the 
pause(), cv_timedwait() etc. Integer division can be quite expensive on 
embedded systems, and there are now several ports of my USB stack to other 
platforms :-) where most of them don't have anything near GHz CPU's.

--HPS



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