seccomp: support riscv64
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
This commit is contained in:
parent
91ceda541b
commit
4b412b8003
@ -44,6 +44,9 @@ func arches() []specs.Arch {
|
|||||||
return []specs.Arch{specs.ArchMIPSEL, specs.ArchMIPSEL64, specs.ArchMIPSEL64N32}
|
return []specs.Arch{specs.ArchMIPSEL, specs.ArchMIPSEL64, specs.ArchMIPSEL64N32}
|
||||||
case "s390x":
|
case "s390x":
|
||||||
return []specs.Arch{specs.ArchS390, specs.ArchS390X}
|
return []specs.Arch{specs.ArchS390, specs.ArchS390X}
|
||||||
|
case "riscv64":
|
||||||
|
// ArchRISCV32 (SCMP_ARCH_RISCV32) does not exist
|
||||||
|
return []specs.Arch{specs.ArchRISCV64}
|
||||||
default:
|
default:
|
||||||
return []specs.Arch{}
|
return []specs.Arch{}
|
||||||
}
|
}
|
||||||
@ -531,6 +534,14 @@ func DefaultProfile(sp *specs.Spec) *specs.LinuxSeccomp {
|
|||||||
Action: specs.ActAllow,
|
Action: specs.ActAllow,
|
||||||
Args: []specs.LinuxSeccompArg{},
|
Args: []specs.LinuxSeccompArg{},
|
||||||
})
|
})
|
||||||
|
case "riscv64":
|
||||||
|
s.Syscalls = append(s.Syscalls, specs.LinuxSyscall{
|
||||||
|
Names: []string{
|
||||||
|
"riscv_flush_icache",
|
||||||
|
},
|
||||||
|
Action: specs.ActAllow,
|
||||||
|
Args: []specs.LinuxSeccompArg{},
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
admin := false
|
admin := false
|
||||||
|
Loading…
Reference in New Issue
Block a user