Martin Pieuchot wrote:
> I'd like to improve the fairness of the scheduler, with the goal of
> mitigating userland starvations.  For that the kernel needs to have
> a better understanding of the amount of executed time per task. 
> 
> The smallest interval currently usable on all our architectures for
> such accounting is a tick.  With the current HZ value of 100, this
> smallest interval is 10ms.  I'd like to bump this value to 1000.

Maybe we want this too, for sh? This looks like accidental netbsd copying. Or
are we intentionally resetting hz on sh for some reason?


Index: arch/sh/sh/clock.c
===================================================================
RCS file: /cvs/src/sys/arch/sh/sh/clock.c,v
retrieving revision 1.9
diff -u -p -r1.9 clock.c
--- arch/sh/sh/clock.c  5 Mar 2016 17:16:33 -0000       1.9
+++ arch/sh/sh/clock.c  14 Aug 2017 20:49:31 -0000
@@ -47,9 +47,6 @@
 
 #define        NWDOG 0
 
-#ifndef HZ
-#define        HZ              64
-#endif
 #define        MINYEAR         2002    /* "today" */
 #define        SH_RTC_CLOCK    16384   /* Hz */
 
@@ -231,10 +228,6 @@ cpu_initclocks(void)
 {
        if (sh_clock.pclock == 0)
                panic("No PCLOCK information.");
-
-       /* Set global variables. */
-       hz = HZ;
-       tick = 1000000 / hz;
 
        /*
         * Use TMU channel 0 as hard clock

Reply via email to