Visa Hankala:

> However, wouldn't it be better if the code avoided the
> situation, for example by defining ADJFREQ_MIN as the negative
> of ADJFREQ_MAX?

Indeed it would.  ok naddy@

> --- kern/kern_time.c  23 Dec 2020 20:45:02 -0000      1.151
> +++ kern/kern_time.c  30 May 2021 15:38:09 -0000
> @@ -396,7 +396,7 @@ sys_settimeofday(struct proc *p, void *v
>  }
>  
>  #define ADJFREQ_MAX (500000000LL << 32)
> -#define ADJFREQ_MIN (-500000000LL << 32)
> +#define ADJFREQ_MIN (-ADJFREQ_MAX)
>  
>  int
>  sys_adjfreq(struct proc *p, void *v, register_t *retval)
> 

-- 
Christian "naddy" Weisgerber                          na...@mips.inka.de

Reply via email to