FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Ubuntu > Ubuntu Kernel Team

 
 
LinkBack Thread Tools
 
Old 06-06-2008, 06:03 PM
Tim Gardner
 
Default UBUNTU: Add native_read_tsc to non __i386__ code.

Implement native_read_tsc for 586 and higher.

Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
---
include/asm-x86/msr.h | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/include/asm-x86/msr.h b/include/asm-x86/msr.h
index 34038c0..c571c6b 100644
--- a/include/asm-x86/msr.h
+++ b/include/asm-x86/msr.h
@@ -225,6 +225,13 @@ static inline int wrmsr_safe_on_cpu(unsigned int cpu, u32 msr_no, u32 l, u32 h)

#define write_rdtscp_aux(val) wrmsr(0xc0000103, val, 0)

+static inline unsigned long long native_read_tsc(void)
+{
+ unsigned long long val;
+ rdtscll(val);
+ return val;
+}
+
#define rdpmc(counter,low,high)
__asm__ __volatile__("rdpmc"
: "=a" (low), "=d" (high)
--
1.5.4.3


--------------020604020509080200080405
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team

--------------020604020509080200080405--
 

Thread Tools




All times are GMT. The time now is 07:14 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org