-/* $OpenBSD: mainbus.c,v 1.6 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: mainbus.c,v 1.7 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2016 Patrick Wildt <patrick@blueri.se>
#include <sys/param.h>
#include <sys/systm.h>
-#include <sys/kernel.h>
#include <sys/device.h>
#include <sys/malloc.h>
-/* $OpenBSD: riscv_cpu_intc.c,v 1.7 2021/05/13 19:26:25 kettenis Exp $ */
+/* $OpenBSD: riscv_cpu_intc.c,v 1.8 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2020, Mars Li <mengshi.li.mars@gmail.com>
#include <sys/param.h>
#include <sys/systm.h>
-#include <sys/queue.h>
#include <sys/malloc.h>
#include <sys/device.h>
-#include <sys/evcount.h>
-#include <machine/bus.h>
#include <machine/fdt.h>
#include <machine/riscvreg.h>
#include <dev/ofw/openfirm.h>
-#include <dev/ofw/fdt.h>
-#include "riscv64/dev/plic.h"
#include "riscv_cpu_intc.h"
struct intrhand {
-/* $OpenBSD: simplebus.c,v 1.3 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: simplebus.c,v 1.4 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2016 Patrick Wildt <patrick@blueri.se>
#include <sys/param.h>
#include <sys/systm.h>
-#include <sys/kernel.h>
#include <sys/device.h>
#include <sys/malloc.h>
-/* $OpenBSD: ast.c,v 1.2 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: ast.c,v 1.3 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2015 Dale Rahn <drahn@dalerahn.com>
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/proc.h>
-#include <sys/signalvar.h>
#include <sys/proc.h>
#include <sys/user.h>
-#include <sys/signal.h>
#include <sys/syscall.h>
#include <sys/syscall_mi.h>
#include <machine/pcb.h>
-/* $OpenBSD: autoconf.c,v 1.3 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: autoconf.c,v 1.4 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2009 Miodrag Vallat.
#include <sys/param.h>
#include <sys/device.h>
-#include <sys/disklabel.h>
#include <sys/reboot.h>
#include <sys/hibernate.h>
#include <sys/systm.h>
#include <netinet/if_ether.h>
#endif
-#include <machine/bootconfig.h>
-
extern void dumpconf(void);
void
-/* $OpenBSD: bus_dma.c,v 1.4 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: bus_dma.c,v 1.5 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2003-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
*/
#include <sys/param.h>
#include <sys/systm.h>
-#include <sys/kernel.h>
#include <sys/proc.h>
#include <sys/malloc.h>
#include <sys/mbuf.h>
-/* $OpenBSD: conf.c,v 1.7 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: conf.c,v 1.8 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 1994, 1995 Charles M. Hannum. All rights reserved.
#include <sys/disklabel.h>
#include <sys/ioctl.h>
#include <sys/tty.h>
-#include <sys/vnode.h>
#include <machine/conf.h>
-/* $OpenBSD: cpu.c,v 1.6 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: cpu.c,v 1.7 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2016 Dale Rahn <drahn@dalerahn.com>
#include <sys/sysctl.h>
#include <machine/fdt.h>
-#include <machine/riscvreg.h>
#include <dev/ofw/openfirm.h>
#include <dev/ofw/ofw_clock.h>
-/* $OpenBSD: intr.c,v 1.5 2021/05/13 19:26:25 kettenis Exp $ */
+/* $OpenBSD: intr.c,v 1.6 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2011 Dale Rahn <drahn@openbsd.org>
#include <sys/param.h>
#include <sys/systm.h>
-#include <sys/timetc.h>
#include <sys/malloc.h>
-#include <dev/clock_subr.h>
#include <machine/cpu.h>
#include <machine/intr.h>
-#include <machine/frame.h>
#include <dev/ofw/openfirm.h>
-/* $OpenBSD: machdep.c,v 1.15 2021/05/13 19:26:25 kettenis Exp $ */
+/* $OpenBSD: machdep.c,v 1.16 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2014 Patrick Wildt <patrick@blueri.se>
#include <sys/user.h>
#include <sys/conf.h>
#include <sys/kcore.h>
-#include <sys/core.h>
#include <sys/msgbuf.h>
#include <sys/buf.h>
-#include <sys/termios.h>
#include <sys/sensors.h>
#include <sys/malloc.h>
#include <sys/syscallargs.h>
-#include <sys/stdarg.h>
#include <net/if.h>
#include <uvm/uvm.h>
-/* $OpenBSD: mem.c,v 1.3 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: mem.c,v 1.4 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 1982, 1986, 1990, 1993
*/
#include <sys/param.h>
-#include <sys/conf.h>
#include <sys/buf.h>
#include <sys/filio.h>
#include <sys/systm.h>
#include <sys/uio.h>
#include <sys/malloc.h>
#include <sys/proc.h>
-#include <sys/fcntl.h>
#include <sys/rwlock.h>
-#include <machine/cpu.h>
#include <machine/conf.h>
#include <uvm/uvm_extern.h>
-/* $OpenBSD: pmap.c,v 1.8 2021/05/13 19:26:25 kettenis Exp $ */
+/* $OpenBSD: pmap.c,v 1.9 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2019-2020 Brian Bamsch <bbamsch@google.com>
*/
#include <sys/param.h>
-#include <sys/malloc.h>
#include <sys/proc.h>
-#include <sys/user.h>
#include <sys/systm.h>
#include <sys/pool.h>
#include <sys/atomic.h>
#include "machine/vmparam.h"
#include "machine/pmap.h"
#include "machine/cpufunc.h"
-#include "machine/pcb.h"
#include "machine/riscvreg.h"
-#include <machine/db_machdep.h>
-#include <ddb/db_extern.h>
-#include <ddb/db_output.h>
-
void pmap_set_satp(struct proc *);
void pmap_free_asid(pmap_t);
-/* $OpenBSD: process_machdep.c,v 1.3 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: process_machdep.c,v 1.4 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2014 Patrick Wildt <patrick@blueri.se>
#include <machine/pcb.h>
#include <machine/reg.h>
-#include <machine/riscvreg.h>
int
process_read_regs(struct proc *p, struct reg *regs)
-/* $OpenBSD: sig_machdep.c,v 1.3 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: sig_machdep.c,v 1.4 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 1990 The Regents of the University of California.
#include <sys/systm.h>
#include <sys/user.h>
-#include <machine/riscvreg.h>
#include <machine/cpu.h>
#include <machine/frame.h>
#include <machine/pcb.h>
-/* $OpenBSD: syscall.c,v 1.5 2021/05/13 19:26:25 kettenis Exp $ */
+/* $OpenBSD: syscall.c,v 1.6 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2020 Brian Bamsch <bbamsch@google.com>
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/proc.h>
-#include <sys/signalvar.h>
#include <sys/user.h>
-#include <sys/vnode.h>
-#include <sys/signal.h>
#include <sys/syscall.h>
#include <sys/syscall_mi.h>
#include <sys/systm.h>
-/* $OpenBSD: trap.c,v 1.8 2021/05/13 06:45:23 kettenis Exp $ */
+/* $OpenBSD: trap.c,v 1.9 2021/05/14 06:48:52 jsg Exp $ */
/*
* Copyright (c) 2020 Shivam Waghela <shivamwaghela@gmail.com>
#include <sys/user.h>
#include <sys/signalvar.h>
#include <sys/siginfo.h>
-#include <sys/syscall.h>
-#include <sys/syscall_mi.h>
#include <machine/riscvreg.h>
#include <machine/syscall.h>
-/* $OpenBSD: vm_machdep.c,v 1.3 2021/05/12 01:20:52 jsg Exp $ */
+/* $OpenBSD: vm_machdep.c,v 1.4 2021/05/14 06:48:52 jsg Exp $ */
/*-
* Copyright (c) 1995 Charles M. Hannum. All rights reserved.
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/proc.h>
-#include <sys/malloc.h>
-#include <sys/vnode.h>
#include <sys/buf.h>
#include <sys/user.h>
-#include <sys/exec.h>
-#include <sys/ptrace.h>
-#include <sys/signalvar.h>
#include <uvm/uvm_extern.h>
#include <machine/cpu.h>
-#include <machine/reg.h>
/*
* Finish a fork operation, with process p2 nearly set up.