Module Name: src Committed By: nonaka Date: Thu May 30 11:15:29 UTC 2019
Modified Files: src/sys/arch/x86/x86: hyperv.c Log Message: Avoid undefined reference to `hyperv_guid_video' without vmbus(4). To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/arch/x86/x86/hyperv.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/arch/x86/x86/hyperv.c diff -u src/sys/arch/x86/x86/hyperv.c:1.2 src/sys/arch/x86/x86/hyperv.c:1.3 --- src/sys/arch/x86/x86/hyperv.c:1.2 Fri May 24 14:28:48 2019 +++ src/sys/arch/x86/x86/hyperv.c Thu May 30 11:15:29 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: hyperv.c,v 1.2 2019/05/24 14:28:48 nonaka Exp $ */ +/* $NetBSD: hyperv.c,v 1.3 2019/05/30 11:15:29 nonaka Exp $ */ /*- * Copyright (c) 2009-2012,2016-2017 Microsoft Corp. @@ -33,7 +33,7 @@ */ #include <sys/cdefs.h> #ifdef __KERNEL_RCSID -__KERNEL_RCSID(0, "$NetBSD: hyperv.c,v 1.2 2019/05/24 14:28:48 nonaka Exp $"); +__KERNEL_RCSID(0, "$NetBSD: hyperv.c,v 1.3 2019/05/30 11:15:29 nonaka Exp $"); #endif #ifdef __FBSDID __FBSDID("$FreeBSD: head/sys/dev/hyperv/vmbus/hyperv.c 331757 2018-03-30 02:25:12Z emaste $"); @@ -43,6 +43,7 @@ __FBSDID("$FreeBSD: head/sys/dev/hyperv/ #include "lapic.h" #include "genfb.h" #include "opt_ddb.h" +#include "vmbus.h" #include "wsdisplay.h" #endif @@ -988,6 +989,7 @@ hyperv_modcmd(modcmd_t cmd, void *aux) return rv; } +#if NVMBUS > 0 /* * genfb at vmbus */ @@ -1086,10 +1088,12 @@ populate_fbinfo(device_t dev, prop_dicti } #endif } +#endif device_t device_hyperv_register(device_t dev, void *aux) { +#if NVMBUS > 0 device_t parent = device_parent(dev); if (parent && device_is_a(parent, "vmbus") && !x86_found_console) { @@ -1128,5 +1132,6 @@ device_hyperv_register(device_t dev, voi return NULL; } } +#endif return NULL; }