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

Re: [Minios-devel] [UNIKRAFT PATCH v6 2/7] plat/common: Rename read_virtual_count to generic_timer_get_ticks



Reviewed-by: Santiago Pagani <santiago.pagani@xxxxxxxxx>

On 09.10.19, 15:02, "Jia He" <justin.he@xxxxxxx> wrote:

    From: Wei Chen <wei.chen@xxxxxxx>
    
    Rename to generic_timer_get_ticks would be good for unifing
    the prefix of the generic timer functions.
    
    Signed-off-by: Wei Chen <wei.chen@xxxxxxx>
    Signed-off-by: Jianyong Wu <jianyong.wu@xxxxxxx>
    Signed-off-by: Jia He <justin.he@xxxxxxx>
    ---
     plat/common/arm/time.c | 10 +++++-----
     1 file changed, 5 insertions(+), 5 deletions(-)
    
    diff --git a/plat/common/arm/time.c b/plat/common/arm/time.c
    index a5731e0..d025c08 100644
    --- a/plat/common/arm/time.c
    +++ b/plat/common/arm/time.c
    @@ -179,7 +179,7 @@ endnofreq:
      * the two read values. If bit[32] is different, keep the first value,
      * otherwise keep the second value.
      */
    -static uint64_t read_virtual_count(void)
    +static uint64_t generic_timer_get_ticks(void)
     {
         uint64_t val_1st, val_2nd;
     
    @@ -188,7 +188,7 @@ static uint64_t read_virtual_count(void)
         return (((val_1st ^ val_2nd) >> 32) & 1) ? val_1st : val_2nd;
     }
     #else
    -static inline uint64_t read_virtual_count(void)
    +static inline uint64_t generic_timer_get_ticks(void)
     {
        return SYSREG_READ64(cntvct_el0);
     }
    @@ -200,13 +200,13 @@ static inline uint64_t read_virtual_count(void)
      */
     static __nsec generic_timer_monotonic(void)
     {
    -   return (__nsec)ticks_to_ns(read_virtual_count() - boot_ticks);
    +   return (__nsec)ticks_to_ns(generic_timer_get_ticks() - boot_ticks);
     }
     
     /*
      * Return epoch offset (wall time offset to monotonic clock start).
      */
    -static __u64  generic_timer_epochoffset(void)
    +static uint64_t generic_timer_epochoffset(void)
     {
        return 0;
     }
    @@ -240,7 +240,7 @@ static int generic_timer_init(void)
         * Monotonic time begins at boot_ticks (first read of counter
         * before calibration).
         */
    -   boot_ticks = read_virtual_count();
    +   boot_ticks = generic_timer_get_ticks();
     
        return 0;
     }
    -- 
    2.17.1
    
    

_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

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