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

[xen staging] x86/time: scale_delta() can be static



commit 5ecc04d9e02b66e93f63f5ef6494890218b23611
Author:     Jan Beulich <jbeulich@xxxxxxxx>
AuthorDate: Wed Jan 14 14:47:09 2026 +0100
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Wed Jan 14 14:47:09 2026 +0100

    x86/time: scale_delta() can be static
    
    It's used in time.c alone. Modernize types while there.
    
    Amends: 5a82d598d2d ("viridian: unify time sources")
    Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
    Acked-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
---
 xen/arch/x86/include/asm/time.h | 1 -
 xen/arch/x86/time.c             | 4 ++--
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/xen/arch/x86/include/asm/time.h b/xen/arch/x86/include/asm/time.h
index c35d25abd6..e45b9ebbfc 100644
--- a/xen/arch/x86/include/asm/time.h
+++ b/xen/arch/x86/include/asm/time.h
@@ -56,7 +56,6 @@ u64 stime2tsc(s_time_t stime);
 
 struct time_scale;
 void set_time_scale(struct time_scale *ts, u64 ticks_per_sec);
-u64 scale_delta(u64 delta, const struct time_scale *scale);
 
 /* Programmable Interval Timer (8254) */
 
diff --git a/xen/arch/x86/time.c b/xen/arch/x86/time.c
index 36d990f7f4..0664ffb806 100644
--- a/xen/arch/x86/time.c
+++ b/xen/arch/x86/time.c
@@ -133,9 +133,9 @@ static inline u32 mul_frac(u32 multiplicand, u32 multiplier)
  * Scale a 64-bit delta by scaling and multiplying by a 32-bit fraction,
  * yielding a 64-bit result.
  */
-u64 scale_delta(u64 delta, const struct time_scale *scale)
+static uint64_t scale_delta(uint64_t delta, const struct time_scale *scale)
 {
-    u64 product;
+    uint64_t product;
 
     if ( scale->shift < 0 )
         delta >>= -scale->shift;
--
generated by git-patchbot for /home/xen/git/xen.git#staging



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.