Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 10 Apr 2022 21:39:21 GMT
From:      Robert Wing <rew@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: d4e8207317ca - main - vmm_instruction_emul.c: fix bhyve build
Message-ID:  <202204102139.23ALdLKV022213@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by rew:

URL: https://cgit.FreeBSD.org/src/commit/?id=d4e8207317ca1827ba2529203d5cc4e67d836fcb

commit d4e8207317ca1827ba2529203d5cc4e67d836fcb
Author:     Robert Wing <rew@FreeBSD.org>
AuthorDate: 2022-04-10 21:37:24 +0000
Commit:     Robert Wing <rew@FreeBSD.org>
CommitDate: 2022-04-10 21:37:24 +0000

    vmm_instruction_emul.c: fix bhyve build
    
    The __diagused macro was used to cure a "set but not used" warning. This
    broke the build for bhyve since __diagused is only defined in the
    kernel. Define __diagused when not building the kernel.
    
    Fixes:          5241577a223d ("vmm: fix set but not used warning")
    Reported by:    Jenkins
---
 sys/amd64/vmm/vmm_instruction_emul.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sys/amd64/vmm/vmm_instruction_emul.c b/sys/amd64/vmm/vmm_instruction_emul.c
index 809fa16bce46..06dffe6a80b9 100644
--- a/sys/amd64/vmm/vmm_instruction_emul.c
+++ b/sys/amd64/vmm/vmm_instruction_emul.c
@@ -58,6 +58,7 @@ __FBSDID("$FreeBSD$");
 #include <string.h>
 #include <strings.h>
 #include <vmmapi.h>
+#define	__diagused
 #define	KASSERT(exp,msg)	assert((exp))
 #define	panic(...)		errx(4, __VA_ARGS__)
 #endif	/* _KERNEL */



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202204102139.23ALdLKV022213>