From 1d4cc78f8dcca5c411d32fad62ffc681b0125e73 Mon Sep 17 00:00:00 2001 From: peter Date: Thu, 26 Jul 2001 23:06:44 +0000 Subject: [PATCH] Call the early tunable setup functions as soon as kern_envp is available. Some things depend on hz being set not long after this. --- sys/alpha/alpha/machdep.c | 3 +++ sys/amd64/amd64/machdep.c | 3 +++ sys/i386/i386/machdep.c | 3 +++ sys/ia64/ia64/machdep.c | 3 +++ sys/pc98/i386/machdep.c | 3 +++ sys/pc98/pc98/machdep.c | 3 +++ 6 files changed, 18 insertions(+) diff --git a/sys/alpha/alpha/machdep.c b/sys/alpha/alpha/machdep.c index b94b64a5b3b2..f1c21bb58712 100644 --- a/sys/alpha/alpha/machdep.c +++ b/sys/alpha/alpha/machdep.c @@ -662,6 +662,9 @@ alpha_init(pfn, ptb, bim, bip, biv) preload_metadata = (caddr_t)bootinfo.modptr; kern_envp = bootinfo.envp; + /* Do basic tuning, hz etc */ + init_param(); + /* * Initalize the (temporary) bootstrap console interface, so * we can use printf until the VM system starts being setup. diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c index c12e6761fb19..a7f53eb3804c 100644 --- a/sys/amd64/amd64/machdep.c +++ b/sys/amd64/amd64/machdep.c @@ -1796,6 +1796,9 @@ init386(first) if (bootinfo.bi_envp) kern_envp = (caddr_t)bootinfo.bi_envp + KERNBASE; + /* Init basic tunables, hz etc */ + init_param(); + /* * make gdt memory segments, the code segment goes up to end of the * page with etext in it, the data segment goes to the end of diff --git a/sys/i386/i386/machdep.c b/sys/i386/i386/machdep.c index c12e6761fb19..a7f53eb3804c 100644 --- a/sys/i386/i386/machdep.c +++ b/sys/i386/i386/machdep.c @@ -1796,6 +1796,9 @@ init386(first) if (bootinfo.bi_envp) kern_envp = (caddr_t)bootinfo.bi_envp + KERNBASE; + /* Init basic tunables, hz etc */ + init_param(); + /* * make gdt memory segments, the code segment goes up to end of the * page with etext in it, the data segment goes to the end of diff --git a/sys/ia64/ia64/machdep.c b/sys/ia64/ia64/machdep.c index c44e7cd52b15..0ff71fccfe90 100644 --- a/sys/ia64/ia64/machdep.c +++ b/sys/ia64/ia64/machdep.c @@ -391,6 +391,9 @@ ia64_init() preload_metadata = (caddr_t)bootinfo.modptr; kern_envp = bootinfo.envp; + /* Init basic tunables, including hz */ + init_param(); + p = getenv("kernelname"); if (p) strncpy(kernelname, p, sizeof(kernelname) - 1); diff --git a/sys/pc98/i386/machdep.c b/sys/pc98/i386/machdep.c index 68fc2a253030..86b6db25fd58 100644 --- a/sys/pc98/i386/machdep.c +++ b/sys/pc98/i386/machdep.c @@ -1860,6 +1860,9 @@ init386(first) if (bootinfo.bi_envp) kern_envp = (caddr_t)bootinfo.bi_envp + KERNBASE; + /* Init basic tunables, hz etc */ + init_param(); + /* * make gdt memory segments, the code segment goes up to end of the * page with etext in it, the data segment goes to the end of diff --git a/sys/pc98/pc98/machdep.c b/sys/pc98/pc98/machdep.c index 68fc2a253030..86b6db25fd58 100644 --- a/sys/pc98/pc98/machdep.c +++ b/sys/pc98/pc98/machdep.c @@ -1860,6 +1860,9 @@ init386(first) if (bootinfo.bi_envp) kern_envp = (caddr_t)bootinfo.bi_envp + KERNBASE; + /* Init basic tunables, hz etc */ + init_param(); + /* * make gdt memory segments, the code segment goes up to end of the * page with etext in it, the data segment goes to the end of