Module Name: src Committed By: skrll Date: Sat Apr 6 13:42:18 UTC 2024
Modified Files: src/sys/dev/ic: qemufwcfg.c Log Message: Add RISC-V support To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/dev/ic/qemufwcfg.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/ic/qemufwcfg.c diff -u src/sys/dev/ic/qemufwcfg.c:1.2 src/sys/dev/ic/qemufwcfg.c:1.3 --- src/sys/dev/ic/qemufwcfg.c:1.2 Mon Sep 3 16:29:31 2018 +++ src/sys/dev/ic/qemufwcfg.c Sat Apr 6 13:42:18 2024 @@ -1,4 +1,4 @@ -/* $NetBSD: qemufwcfg.c,v 1.2 2018/09/03 16:29:31 riastradh Exp $ */ +/* $NetBSD: qemufwcfg.c,v 1.3 2024/04/06 13:42:18 skrll Exp $ */ /*- * Copyright (c) 2017 Jared McNeill <jmcne...@invisible.ca> @@ -27,7 +27,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: qemufwcfg.c,v 1.2 2018/09/03 16:29:31 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: qemufwcfg.c,v 1.3 2024/04/06 13:42:18 skrll Exp $"); #include <sys/param.h> #include <sys/device.h> @@ -52,6 +52,11 @@ __KERNEL_RCSID(0, "$NetBSD: qemufwcfg.c, #define FWCFG_SEL_SWAP htobe16 #define FWCFG_DATA_REG 0x00 #define FWCFG_DMA_ADDR 0x10 +#elif defined(__riscv) +#define FWCFG_SEL_REG 0x08 +#define FWCFG_SEL_SWAP htobe16 +#define FWCFG_DATA_REG 0x00 +#define FWCFG_DMA_ADDR 0x10 #else #error driver does not support this architecture #endif