[Asterisk-code-review] Enable rdtsc support on NetBSD (asterisk[master])

Jaco Kroon asteriskteam at digium.com
Thu Dec 16 00:21:09 CST 2021


Jaco Kroon has uploaded this change for review. ( https://gerrit.asterisk.org/c/asterisk/+/17706 )


Change subject: Enable rdtsc support on NetBSD
......................................................................

Enable rdtsc support on NetBSD

MichaƂ supplied me with this patch to submit.

Change-Id: I460ad9b4d971913420ecb84186f5ba5ab03f6f37
Signed-off-by: Jaco Kroon <jaco at uls.co.za>
---
M main/asterisk.c
1 file changed, 2 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/06/17706/1

diff --git a/main/asterisk.c b/main/asterisk.c
index eaf2d7d..4520318 100644
--- a/main/asterisk.c
+++ b/main/asterisk.c
@@ -810,10 +810,10 @@
 /* The RDTSC instruction was introduced on the Pentium processor and is not
  * implemented on certain clones, like the Cyrix 586. Hence, the previous
  * expectation of __i386__ was in error. */
-#if defined ( __i686__) && (defined(__FreeBSD__) || defined(linux))
+#if defined ( __i686__) && (defined(__FreeBSD__) || defined(__NetBSD__) || defined(linux))
 #if defined(__FreeBSD__)
 #include <machine/cpufunc.h>
-#elif defined(linux)
+#elif defined(__NetBSD__) || defined(linux)
 static __inline uint64_t
 rdtsc(void)
 {

-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/17706
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Change-Id: I460ad9b4d971913420ecb84186f5ba5ab03f6f37
Gerrit-Change-Number: 17706
Gerrit-PatchSet: 1
Gerrit-Owner: Jaco Kroon <jaco at uls.co.za>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20211216/b7d92e67/attachment.html>


More information about the asterisk-code-review mailing list