From fc5237a0faea498105e32ce5ded7c7ae0717a431 Mon Sep 17 00:00:00 2001 From: deraadt Date: Sun, 19 Aug 2018 18:01:04 +0000 Subject: [PATCH] pseudo-device must be file-flagged otherwise ramdisks cannot link. --- sys/arch/amd64/amd64/conf.c | 5 +++-- sys/arch/amd64/conf/files.amd64 | 4 ++-- sys/arch/i386/conf/files.i386 | 4 ++-- sys/arch/i386/i386/conf.c | 5 +++-- 4 files changed, 10 insertions(+), 8 deletions(-) diff --git a/sys/arch/amd64/amd64/conf.c b/sys/arch/amd64/amd64/conf.c index b629a95db2b..f6cd4302184 100644 --- a/sys/arch/amd64/amd64/conf.c +++ b/sys/arch/amd64/amd64/conf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: conf.c,v 1.61 2018/08/19 11:42:33 anton Exp $ */ +/* $OpenBSD: conf.c,v 1.62 2018/08/19 18:01:04 deraadt Exp $ */ /* * Copyright (c) 1994, 1995 Charles M. Hannum. All rights reserved. @@ -176,6 +176,7 @@ cdev_decl(kcov); #include "wskbd.h" #include "wsmouse.h" #include "wsmux.h" +#include "kcov.h" #ifdef USER_PCICONF #include "pci.h" @@ -214,7 +215,7 @@ struct cdevsw cdevsw[] = cdev_lpt_init(NLPT,lpt), /* 16: parallel printer */ cdev_ch_init(NCH,ch), /* 17: SCSI autochanger */ cdev_notdef(), /* 18: was: concatenated disk driver */ - cdev_kcov_init(1,kcov), /* 19: kcov */ + cdev_kcov_init(NKCOV,kcov), /* 19: kcov */ cdev_uk_init(NUK,uk), /* 20: unknown SCSI */ cdev_notdef(), /* 21 */ cdev_fd_init(1,filedesc), /* 22: file descriptor pseudo-device */ diff --git a/sys/arch/amd64/conf/files.amd64 b/sys/arch/amd64/conf/files.amd64 index a4b89dde769..b876aa897f4 100644 --- a/sys/arch/amd64/conf/files.amd64 +++ b/sys/arch/amd64/conf/files.amd64 @@ -1,4 +1,4 @@ -# $OpenBSD: files.amd64,v 1.98 2018/08/19 11:42:33 anton Exp $ +# $OpenBSD: files.amd64,v 1.99 2018/08/19 18:01:05 deraadt Exp $ maxpartitions 16 maxusers 2 16 128 @@ -248,7 +248,7 @@ file arch/amd64/amd64/vmm_support.S vmm # KCOV # pseudo-device kcov -file dev/kcov.c kcov +file dev/kcov.c kcov needs-flag # # Machine-independent SD/MMC drivers diff --git a/sys/arch/i386/conf/files.i386 b/sys/arch/i386/conf/files.i386 index 0685b8e8345..f70d8d3a6d2 100644 --- a/sys/arch/i386/conf/files.i386 +++ b/sys/arch/i386/conf/files.i386 @@ -1,4 +1,4 @@ -# $OpenBSD: files.i386,v 1.240 2018/08/19 11:42:33 anton Exp $ +# $OpenBSD: files.i386,v 1.241 2018/08/19 18:01:05 deraadt Exp $ # # new style config file for i386 architecture # @@ -402,7 +402,7 @@ file arch/i386/i386/vmm_support.S vmm # KCOV # pseudo-device kcov -file dev/kcov.c kcov +file dev/kcov.c kcov needs-flag # # IPMI diff --git a/sys/arch/i386/i386/conf.c b/sys/arch/i386/i386/conf.c index 891b3a3a96d..488ee4df745 100644 --- a/sys/arch/i386/i386/conf.c +++ b/sys/arch/i386/i386/conf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: conf.c,v 1.159 2018/08/19 11:42:33 anton Exp $ */ +/* $OpenBSD: conf.c,v 1.160 2018/08/19 18:01:05 deraadt Exp $ */ /* $NetBSD: conf.c,v 1.75 1996/05/03 19:40:20 christos Exp $ */ /* @@ -178,6 +178,7 @@ cdev_decl(kcov); #include "wskbd.h" #include "wsmouse.h" #include "wsmux.h" +#include "kcov.h" #ifdef USER_PCICONF #include "pci.h" @@ -219,7 +220,7 @@ struct cdevsw cdevsw[] = cdev_lpt_init(NLPT,lpt), /* 16: parallel printer */ cdev_ch_init(NCH,ch), /* 17: SCSI autochanger */ cdev_notdef(), /* 18: was: concatenated disk driver */ - cdev_kcov_init(1,kcov), /* 19: kcov */ + cdev_kcov_init(NKCOV,kcov), /* 19: kcov */ cdev_uk_init(NUK,uk), /* 20: unknown SCSI */ cdev_acpiapm_init(1,acpiapm), /* 21: Power Management stuff */ cdev_fd_init(1,filedesc), /* 22: file descriptor pseudo-device */ -- 2.20.1