Commit 732f374b authored by Andy Lutomirski's avatar Andy Lutomirski Committed by Ingo Molnar

x86/asm/tsc, drivers/input/gameport: Replace rdtscl() with native_read_tsc()

It's unclear to me why this code exists in the first place.
Signed-off-by: default avatarAndy Lutomirski <luto@kernel.org>
Signed-off-by: default avatarBorislav Petkov <bp@suse.de>
Acked-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: Andy Lutomirski <luto@amacapital.net>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Brian Gerst <brgerst@gmail.com>
Cc: Denys Vlasenko <dvlasenk@redhat.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Huang Rui <ray.huang@amd.com>
Cc: John Stultz <john.stultz@linaro.org>
Cc: Len Brown <lenb@kernel.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: kvm ML <kvm@vger.kernel.org>
Cc: linux-input@vger.kernel.org
Link: http://lkml.kernel.org/r/9e058e72f4cf1f13c6483c1360b39c3d188a2c2a.1434501121.git.luto@kernel.orgSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
parent 016bfc44
...@@ -149,9 +149,9 @@ static int old_gameport_measure_speed(struct gameport *gameport) ...@@ -149,9 +149,9 @@ static int old_gameport_measure_speed(struct gameport *gameport)
for(i = 0; i < 50; i++) { for(i = 0; i < 50; i++) {
local_irq_save(flags); local_irq_save(flags);
rdtscl(t1); t1 = native_read_tsc();
for (t = 0; t < 50; t++) gameport_read(gameport); for (t = 0; t < 50; t++) gameport_read(gameport);
rdtscl(t2); t2 = native_read_tsc();
local_irq_restore(flags); local_irq_restore(flags);
udelay(i * 10); udelay(i * 10);
if (t2 - t1 < tx) tx = t2 - t1; if (t2 - t1 < tx) tx = t2 - t1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment