Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/evbarm/rpi allow ukbd to be the console keyboard if...



details:   https://anonhg.NetBSD.org/src/rev/03d3b6238a60
branches:  trunk
changeset: 783878:03d3b6238a60
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Fri Jan 11 12:47:38 2013 +0000

description:
allow ukbd to be the console keyboard if genfb is the console display device

diffstat:

 sys/arch/evbarm/rpi/rpi_machdep.c |  13 +++++++++++--
 1 files changed, 11 insertions(+), 2 deletions(-)

diffs (48 lines):

diff -r 93cdfc01dd00 -r 03d3b6238a60 sys/arch/evbarm/rpi/rpi_machdep.c
--- a/sys/arch/evbarm/rpi/rpi_machdep.c Fri Jan 11 12:21:54 2013 +0000
+++ b/sys/arch/evbarm/rpi/rpi_machdep.c Fri Jan 11 12:47:38 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rpi_machdep.c,v 1.27 2013/01/10 14:15:20 jmcneill Exp $        */
+/*     $NetBSD: rpi_machdep.c,v 1.28 2013/01/11 12:47:38 jmcneill Exp $        */
 
 /*-
  * Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rpi_machdep.c,v 1.27 2013/01/10 14:15:20 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rpi_machdep.c,v 1.28 2013/01/11 12:47:38 jmcneill Exp $");
 
 #include "opt_evbarm_boardtype.h"
 
@@ -40,6 +40,7 @@
 #include "bsciic.h"
 #include "plcom.h"
 #include "genfb.h"
+#include "ukbd.h"
 
 #include <sys/param.h>
 #include <sys/device.h>
@@ -81,6 +82,10 @@
 #include <dev/videomode/edidvar.h>
 #endif
 
+#if NUKBD > 0
+#include <dev/usb/ukbdvar.h>
+#endif
+
 #include "ksyms.h"
 
 extern int KERNEL_BASE_phys[];
@@ -762,6 +767,10 @@
                if (get_bootconf_option(boot_args, "console",
                    BOOTOPT_TYPE_STRING, &ptr) && strncmp(ptr, "fb", 2) == 0) {
                        prop_dictionary_set_bool(dict, "is_console", true);
+#if NUKBD > 0
+                       /* allow ukbd to be the console keyboard */
+                       ukbd_cnattach();
+#endif
                } else {
                        prop_dictionary_set_bool(dict, "is_console", false);
                }



Home | Main Index | Thread Index | Old Index