time_interpolator: Use readq_relaxed() instead of readq().

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On some platforms readq performs additional work to make sure I/O is done in
a coherent way. This is not needed for time retrieval as done by the time interpolator.
So we can use readq_relaxed instead which will improve performance.

Signed-off-by: Christoph Lameter <[email protected]>

Index: linux-2.6.16-rc4/kernel/timer.c
===================================================================
--- linux-2.6.16-rc4.orig/kernel/timer.c	2006-02-17 14:23:45.000000000 -0800
+++ linux-2.6.16-rc4/kernel/timer.c	2006-02-23 14:03:02.000000000 -0800
@@ -1351,10 +1351,10 @@ static inline u64 time_interpolator_get_
 			return x();
 
 		case TIME_SOURCE_MMIO64	:
-			return readq((void __iomem *) time_interpolator->addr);
+			return readq_relaxed((void __iomem *) time_interpolator->addr);
 
 		case TIME_SOURCE_MMIO32	:
-			return readl((void __iomem *) time_interpolator->addr);
+			return readl_relaxed((void __iomem *) time_interpolator->addr);
 
 		default: return get_cycles();
 	}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux