mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
Initialize Kernel.Timekeeper before network NS
PiperOrigin-RevId: 375843579
This commit is contained in:
committed by
gVisor bot
parent
a54cb9d8a2
commit
b63e61828d
@@ -88,6 +88,7 @@ func Boot() (*kernel.Kernel, error) {
|
||||
return nil, fmt.Errorf("creating timekeeper: %v", err)
|
||||
}
|
||||
tk.SetClocks(time.NewCalibratedClocks())
|
||||
k.SetTimekeeper(tk)
|
||||
|
||||
creds := auth.NewRootCredentials(auth.NewRootUserNamespace())
|
||||
|
||||
@@ -96,7 +97,6 @@ func Boot() (*kernel.Kernel, error) {
|
||||
if err = k.Init(kernel.InitKernelArgs{
|
||||
ApplicationCores: uint(runtime.GOMAXPROCS(-1)),
|
||||
FeatureSet: cpuid.HostFeatureSet(),
|
||||
Timekeeper: tk,
|
||||
RootUserNamespace: creds.UserNamespace,
|
||||
Vdso: vdso,
|
||||
RootUTSNamespace: kernel.NewUTSNamespace("hostname", "domain", creds.UserNamespace),
|
||||
|
||||
Reference in New Issue
Block a user