[asterisk-bugs] [Zaptel 0010314]: [patch] Merged in support for high resolution timers in kernel >=2.6.22
noreply at bugs.digium.com
noreply at bugs.digium.com
Sat Jun 7 13:20:41 CDT 2008
A NOTE has been added to this issue.
======================================================================
http://bugs.digium.com/view.php?id=10314
======================================================================
Reported By: darren1713
Assigned To: qwell
======================================================================
Project: Zaptel
Issue ID: 10314
Category: ztdummy
Reproducibility: always
Severity: feature
Priority: normal
Status: closed
Zaptel Version: SVN
SVN Branch (only for SVN checkouts, not tarball releases): N/A
SVN Revision (number only!): 2770
Disclaimer on File?: N/A
Request Review:
Resolution: fixed
Fixed in Version:
======================================================================
Date Submitted: 07-26-2007 18:36 CDT
Last Modified: 06-07-2008 13:20 CDT
======================================================================
Summary: [patch] Merged in support for high resolution timers
in kernel >=2.6.22
Description:
The new high resolution timer in the kernel generates very accurate
periodic timing. Just using the kernel based timing gets these sorts of
results from ztdummy (99.999992% avg):
......
8192 samples in 8192.000000 sample intervals 100.000000%
8192 samples in 8192.008000 sample intervals 99.999908%
--- Results after 123 passes ---
Best: 100.000000 -- Worst: 99.999512 -- Average: 99.999992
The high resolution timer in ztdummy is only built if it's supported and
enabled in the kernel, and will continue to use the RTC timing if the high
resolution timers are not available.
Specifically, CONFIG_HIGH_RES_TIMERS needs to be enabled (Processor type
and features -> High Resolution Timer Support), and optionally, (Processor
type and features -> HPET Timer Support) provides a better clock source.
There should be no side effects to this, since it's the new kernel
timers.
Adding an option into the "make menuselect" to force RTC instead if they
are both available would be a good addition. Configs/Makefiles are not my
fortay, so this would be better for someone else to do.
======================================================================
----------------------------------------------------------------------
svnbot - 06-07-08 13:20
----------------------------------------------------------------------
Repository: dahdi
Revision: 3038
U branches/1.4/ztdummy.c
------------------------------------------------------------------------
r3038 | tzafrir | 2008-06-07 13:20:27 -0500 (Sat, 07 Jun 2008) | 10 lines
Include support for high-resolution timers for linux >= 2.6.22
(http://bugs.digium.com/view.php?id=10314).
Changes from the patch:
* Only support kernels >= 2.6.22, as hrtimer_forward is only exported as
of that version.
* Adapted to my recent changes in ztdummy.c .
* Use ZAPTEL_TIME_NS instead of ZAPTEL_RATE
* Simplified ticks debug statement. Will only be used if debug=2 or
debug=3 .
------------------------------------------------------------------------
http://svn.digium.com/view/dahdi?view=rev&revision=3038
Issue History
Date Modified Username Field Change
======================================================================
06-07-08 13:20 svnbot Checkin
06-07-08 13:20 svnbot Note Added: 0088327
======================================================================
More information about the asterisk-bugs
mailing list