From 8cb7d3dcfcbe11a6d5682743816409d1c8e8f6a0 Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Wed, 20 Sep 2017 21:18:36 +0200 Subject: all: initial support for fuchsia Nothing works, but builds. Update #191 --- sys/fuchsia/init.go | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 sys/fuchsia/init.go (limited to 'sys/fuchsia/init.go') diff --git a/sys/fuchsia/init.go b/sys/fuchsia/init.go new file mode 100644 index 000000000..0dfe874cc --- /dev/null +++ b/sys/fuchsia/init.go @@ -0,0 +1,35 @@ +// Copyright 2017 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. + +package fuchsia + +import ( + "github.com/google/syzkaller/prog" +) + +func initTarget(target *prog.Target) { + arch := &arch{} + + target.PageSize = pageSize + target.DataOffset = dataOffset + target.MmapSyscall = arch.mmapSyscall + target.MakeMmap = arch.makeMmap + target.AnalyzeMmap = arch.analyzeMmap +} + +const ( + pageSize = 4 << 10 + dataOffset = 512 << 20 +) + +type arch struct { +} + +// createMmapCall creates a "normal" mmap call that maps [start, start+npages) page range. +func (arch *arch) makeMmap(start, npages uint64) *prog.Call { + return nil +} + +func (arch *arch) analyzeMmap(c *prog.Call) (start, npages uint64, mapped bool) { + return +} -- cgit mrf-deployment