Add need-flags for kernfs.
Compile Xen kernfs support only if kernfs is compiled in the kernel. Should fix MODULAR build.
This commit is contained in:
parent
32f92a08ec
commit
ecb2afc2be
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: files.xen,v 1.185 2020/05/05 17:02:01 bouyer Exp $
|
||||
# $NetBSD: files.xen,v 1.186 2020/05/26 10:37:24 bouyer Exp $
|
||||
|
||||
defflag opt_xen.h XEN XENPVH XENPVHVM PAE DOM0OPS
|
||||
|
||||
|
@ -27,7 +27,7 @@ device xenbus {[id = -1]}
|
|||
attach xenbus at xendevbus
|
||||
file arch/xen/xenbus/xenbus_client.c xenbus needs-flag
|
||||
file arch/xen/xenbus/xenbus_comms.c xenbus needs-flag
|
||||
file arch/xen/xenbus/xenbus_dev.c xenbus needs-flag
|
||||
file arch/xen/xenbus/xenbus_dev.c xenbus & kernfs
|
||||
file arch/xen/xenbus/xenbus_probe.c xenbus needs-flag
|
||||
file arch/xen/xenbus/xenbus_xs.c xenbus needs-flag
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: hypervisor.c,v 1.85 2020/05/21 21:12:31 ad Exp $ */
|
||||
/* $NetBSD: hypervisor.c,v 1.86 2020/05/26 10:37:25 bouyer Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2005 Manuel Bouyer.
|
||||
|
@ -53,7 +53,7 @@
|
|||
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: hypervisor.c,v 1.85 2020/05/21 21:12:31 ad Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: hypervisor.c,v 1.86 2020/05/26 10:37:25 bouyer Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -65,6 +65,7 @@ __KERNEL_RCSID(0, "$NetBSD: hypervisor.c,v 1.85 2020/05/21 21:12:31 ad Exp $");
|
|||
#include "isa.h"
|
||||
#include "pci.h"
|
||||
#include "acpica.h"
|
||||
#include "kernfs.h"
|
||||
|
||||
#include "opt_xen.h"
|
||||
#include "opt_mpbios.h"
|
||||
|
@ -778,10 +779,12 @@ kernfs_parentdir_t *kernxen_pkt;
|
|||
void
|
||||
xenkernfs_init(void)
|
||||
{
|
||||
#if NKERNFS > 0
|
||||
kernfs_entry_t *dkt;
|
||||
|
||||
KERNFS_ALLOCENTRY(dkt, KM_SLEEP);
|
||||
KERNFS_INITENTRY(dkt, DT_DIR, "xen", NULL, KFSsubdir, VDIR, DIR_MODE);
|
||||
kernfs_addentry(NULL, dkt);
|
||||
kernxen_pkt = KERNFS_ENTOPARENTDIR(dkt);
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: privcmd.c,v 1.58 2020/05/26 10:11:56 bouyer Exp $ */
|
||||
/* $NetBSD: privcmd.c,v 1.59 2020/05/26 10:37:25 bouyer Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2004 Christian Limpach.
|
||||
|
@ -27,7 +27,7 @@
|
|||
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: privcmd.c,v 1.58 2020/05/26 10:11:56 bouyer Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: privcmd.c,v 1.59 2020/05/26 10:37:25 bouyer Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -782,7 +782,6 @@ privcmd_ioctl(void *v)
|
|||
case IOCTL_PRIVCMD_MMAPBATCH_V2:
|
||||
return privcmd_mmapbatch_v2(ap);
|
||||
|
||||
|
||||
case IOCTL_PRIVCMD_MMAP_RESOURCE:
|
||||
return privcmd_mmap_resource(ap);
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: xenbus_probe.c,v 1.54 2020/05/14 13:18:55 jdolecek Exp $ */
|
||||
/* $NetBSD: xenbus_probe.c,v 1.55 2020/05/26 10:37:25 bouyer Exp $ */
|
||||
/******************************************************************************
|
||||
* Talks to Xen Store to figure out what devices we have.
|
||||
*
|
||||
|
@ -29,7 +29,7 @@
|
|||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: xenbus_probe.c,v 1.54 2020/05/14 13:18:55 jdolecek Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: xenbus_probe.c,v 1.55 2020/05/26 10:37:25 bouyer Exp $");
|
||||
|
||||
#if 0
|
||||
#define DPRINTK(fmt, args...) \
|
||||
|
@ -56,6 +56,8 @@ __KERNEL_RCSID(0, "$NetBSD: xenbus_probe.c,v 1.54 2020/05/14 13:18:55 jdolecek E
|
|||
|
||||
#include "xenbus_comms.h"
|
||||
|
||||
#include "kernfs.h"
|
||||
|
||||
static int xenbus_match(device_t, cfdata_t, void *);
|
||||
static void xenbus_attach(device_t, device_t, void *);
|
||||
static int xenbus_print(void *, const char *);
|
||||
|
@ -719,8 +721,10 @@ xenbus_probe_init(void *unused)
|
|||
#endif /* DOM0OPS */
|
||||
}
|
||||
|
||||
#if NKERNFS > 0
|
||||
/* Publish xenbus and Xenstore info in /kern/xen */
|
||||
xenbus_kernfs_init();
|
||||
#endif
|
||||
|
||||
/* register event handler */
|
||||
xb_init_comms(xenbus_dev);
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# $NetBSD: files.kernfs,v 1.6 2014/10/11 06:42:20 uebayasi Exp $
|
||||
# $NetBSD: files.kernfs,v 1.7 2020/05/26 10:37:25 bouyer Exp $
|
||||
|
||||
deffs KERNFS
|
||||
|
||||
define kernfs: vfs
|
||||
file miscfs/kernfs/kernfs_vfsops.c kernfs
|
||||
file miscfs/kernfs/kernfs_vnops.c kernfs
|
||||
file miscfs/kernfs/kernfs_vnops.c kernfs needs-flag
|
||||
|
|
Loading…
Reference in New Issue