From 754863b46d992f5ab9805d8fcdf37f1620adc54c Mon Sep 17 00:00:00 2001 From: Chris Palmer Date: Fri, 14 Oct 2022 16:16:39 -0700 Subject: sys/fuchsia: reland bti, iommu, pmt syscalls --- sys/fuchsia/bti.txt | 17 +++++++++++++++++ sys/fuchsia/iommu.txt | 12 ++++++++++++ sys/fuchsia/pmt.txt | 10 ++++++++++ 3 files changed, 39 insertions(+) create mode 100644 sys/fuchsia/bti.txt create mode 100644 sys/fuchsia/iommu.txt create mode 100644 sys/fuchsia/pmt.txt (limited to 'sys/fuchsia') diff --git a/sys/fuchsia/bti.txt b/sys/fuchsia/bti.txt new file mode 100644 index 000000000..c8cccb0c8 --- /dev/null +++ b/sys/fuchsia/bti.txt @@ -0,0 +1,17 @@ +# Copyright 2022 syzkaller project authors. All rights reserved. +# Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file. + +# See: https://cs.opensource.google/fuchsia/fuchsia/+/main:zircon/vdso/bti.fidl + +include + +resource zx_bti[zx_handle] + +zx_bti_create(iommu zx_iommu, options flags[bti_create_options], bti_id int64, bti ptr[out, zx_bti]) + +zx_bti_pin(handle zx_bti, options flags[bti_pin_options], vmo zx_vmo, offset int64, size int64, addrs ptr[out, array[intptr]], num_addrs len[addrs], pmt ptr[out, zx_pmt]) + +zx_bti_release_quarantine(bti zx_bti) + +bti_create_options = 0 +bti_pin_options = ZX_BTI_PERM_READ, ZX_BTI_PERM_WRITE, ZX_BTI_PERM_EXECUTE, ZX_BTI_COMPRESS, ZX_BTI_CONTIGUOUS diff --git a/sys/fuchsia/iommu.txt b/sys/fuchsia/iommu.txt new file mode 100644 index 000000000..f6bcffbbf --- /dev/null +++ b/sys/fuchsia/iommu.txt @@ -0,0 +1,12 @@ +# Copyright 2022 syzkaller project authors. All rights reserved. +# Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file. + +# See: https://cs.opensource.google/fuchsia/fuchsia/+/main:zircon/vdso/iommu.fidl + +include + +resource zx_iommu[zx_handle] + +zx_iommu_create(handle zx_handle, type flags[iommu_create_type], desc ptr[in, array[int8]], size len[desc], out_handle ptr[out, zx_iommu]) + +iommu_create_type = ZX_IOMMU_TYPE_DUMMY diff --git a/sys/fuchsia/pmt.txt b/sys/fuchsia/pmt.txt new file mode 100644 index 000000000..7bdd65643 --- /dev/null +++ b/sys/fuchsia/pmt.txt @@ -0,0 +1,10 @@ +# Copyright 2022 syzkaller project authors. All rights reserved. +# Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file. + +# See: https://cs.opensource.google/fuchsia/fuchsia/+/main:zircon/vdso/pmt.fidl + +include + +resource zx_pmt[zx_handle] + +zx_pmt_unpin(handle zx_pmt) -- cgit mrf-deployment