From ae8db96a5b4337661adfa52a9635ed24027e922c Mon Sep 17 00:00:00 2001 From: deraadt Date: Tue, 30 Nov 2021 02:13:55 +0000 Subject: [PATCH] enable uhid/fido from Ashton Fagg --- sys/arch/riscv64/conf/GENERIC | 4 +++- sys/arch/riscv64/riscv64/conf.c | 8 +++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/sys/arch/riscv64/conf/GENERIC b/sys/arch/riscv64/conf/GENERIC index e3518fdab81..d4db36b7dfa 100644 --- a/sys/arch/riscv64/conf/GENERIC +++ b/sys/arch/riscv64/conf/GENERIC @@ -1,4 +1,4 @@ -# $OpenBSD: GENERIC,v 1.29 2021/09/02 10:11:21 mlarkin Exp $ +# $OpenBSD: GENERIC,v 1.30 2021/11/30 02:13:55 deraadt Exp $ # # For further information on compiling OpenBSD kernels, see the config(8) # man page. @@ -133,6 +133,8 @@ uwacom* at uhidev? # USB Wacom tablet wsmouse* at uwacom? mux 0 ukbd* at uhidev? wskbd* at ukbd? mux 1 +uhid* at uhidev? # USB generic HID support +fido* at uhidev? # FIDO/U2F security key support udl* at uhub? # DisplayLink USB displays wsdisplay* at udl? umass* at uhub? diff --git a/sys/arch/riscv64/riscv64/conf.c b/sys/arch/riscv64/riscv64/conf.c index 27618a6deb4..f89dccd2540 100644 --- a/sys/arch/riscv64/riscv64/conf.c +++ b/sys/arch/riscv64/riscv64/conf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: conf.c,v 1.12 2021/11/11 10:03:09 claudio Exp $ */ +/* $OpenBSD: conf.c,v 1.13 2021/11/30 02:13:57 deraadt Exp $ */ /* * Copyright (c) 1994, 1995 Charles M. Hannum. All rights reserved. @@ -91,6 +91,8 @@ cdev_decl(lpt); #include "radio.h" #include "drm.h" cdev_decl(drm); +#include "uhid.h" +#include "fido.h" #include "wsdisplay.h" #include "wskbd.h" @@ -178,7 +180,7 @@ struct cdevsw cdevsw[] = cdev_notdef(), /* 60: i4b phone device */ /* End of reserved slots for isdn4bsd. */ cdev_notdef(), /* 61: USB controller */ - cdev_notdef(), /* 62: USB generic HID */ + cdev_usbdev_init(NUHID,uhid), /* 62: USB generic HID */ cdev_notdef(), /* 63: USB generic driver */ cdev_notdef(), /* 64: USB printers */ cdev_notdef(), /* 65: urio */ @@ -219,7 +221,7 @@ struct cdevsw cdevsw[] = cdev_notdef(), /* 95 */ cdev_ipmi_init(NIPMI,ipmi), /* 96: ipmi */ cdev_notdef(), /* 97: was switch(4) */ - cdev_notdef(), /* 98: FIDO/U2F security key */ + cdev_fido_init(NFIDO,fido), /* 98: FIDO/U2F security key */ cdev_pppx_init(NPPPX,pppac), /* 99: PPP Access Concentrator */ cdev_notdef(), /* 100: USB joystick/gamecontroller */ }; -- 2.20.1