NetBSD Problem Report #52622

From www@NetBSD.org  Sun Oct 15 18:10:59 2017
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 0B60B7A17B
	for <gnats-bugs@gnats.NetBSD.org>; Sun, 15 Oct 2017 18:10:59 +0000 (UTC)
Message-Id: <20171015181058.45F257A2A6@mollari.NetBSD.org>
Date: Sun, 15 Oct 2017 18:10:58 +0000 (UTC)
From: cryintothebluesky@googlemail.com
Reply-To: cryintothebluesky@googlemail.com
To: gnats-bugs@NetBSD.org
Subject: Keyboard with DIN connector does not function with NetBSD-8 on Sun Ultra 10
X-Send-Pr-Version: www-1.0

>Number:         52622
>Category:       port-sparc64
>Synopsis:       Keyboard with DIN connector does not function with NetBSD-8 on Sun Ultra 10
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    port-sparc64-maintainer
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Oct 15 18:15:00 +0000 2017
>Closed-Date:    Mon Feb 12 13:32:06 +0000 2018
>Last-Modified:  Mon Feb 12 13:32:06 +0000 2018
>Originator:     Sad Clouds
>Release:        NetBSD 8.0_BETA
>Organization:
>Environment:
NetBSD ultra10 8.0_BETA NetBSD 8.0_BETA (GENERIC) #1: Thu Oct 12 19:41:25 BST 2017  roman@atom510:/opt/obj.sparc64/sys/arch/sparc64/compile/GENERIC sparc64
>Description:
During installation of NetBSD-8 on Sun Ultra 10, Sun keyboard functioned correctly in sysinstall. However when the installed system was booted, Sun keyboard was not responding and nothing was output on the screen when keys were pressed, same issue persisted when running Xorg. When second USB keyboard was plugged in, it functioned correctly, however Sun keyboard was still unresponsive.

By trial and error I discovered that commenting out "ttyflags -a" from /etc/rc.d/ttys resolved the issue and allowed me to use Sun keyboard. Looks like there is a regression with NetBSD-8.
>How-To-Repeat:

>Fix:

>Release-Note:

>Audit-Trail:
From: Martin Husemann <martin@duskware.de>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: port-sparc64/52622: Keyboard with DIN connector does not
 function with NetBSD-8 on Sun Ultra 10
Date: Tue, 17 Oct 2017 19:47:58 +0200

 Can you please append your /etc/ttys file?

 Thanks,

 Martin

From: Sad Clouds <cryintothebluesky@googlemail.com>
To: gnats-bugs@NetBSD.org
Cc: Martin Husemann <martin@duskware.de>,
 port-sparc64-maintainer@netbsd.org, gnats-admin@netbsd.org,
 netbsd-bugs@netbsd.org
Subject: Re: port-sparc64/52622: Keyboard with DIN connector does not
 function with NetBSD-8 on Sun Ultra 10
Date: Tue, 17 Oct 2017 20:08:17 +0100

 On Tue, 17 Oct 2017 17:50:01 +0000 (UTC)
 Martin Husemann <martin@duskware.de> wrote:

 > The following reply was made to PR port-sparc64/52622; it has been
 > noted by GNATS.
 > 
 > From: Martin Husemann <martin@duskware.de>
 > To: gnats-bugs@NetBSD.org
 > Cc: 
 > Subject: Re: port-sparc64/52622: Keyboard with DIN connector does not
 >  function with NetBSD-8 on Sun Ultra 10
 > Date: Tue, 17 Oct 2017 19:47:58 +0200
 > 
 >  Can you please append your /etc/ttys file?
 >  
 >  Thanks,
 >  
 >  Martin
 >  

 It is the same as from the default etc.tgz set created by build.sh

 console "/usr/libexec/getty suncons"    wsvt25  on secure
 constty "/usr/libexec/getty suncons"    wsvt25  off secure
 ttyE0   "/usr/libexec/getty suncons"    wsvt25  off secure
 ttyE1   "/usr/libexec/getty suncons"    wsvt25  off secure
 ttyE2   "/usr/libexec/getty suncons"    wsvt25  off secure
 ttyE3   "/usr/libexec/getty suncons"    wsvt25  off secure
 ttya    "/usr/libexec/getty std.9600"   unknown off secure
 ttyb    "/usr/libexec/getty std.9600"   unknown off secure
 ttyh0   "/usr/libexec/getty std.9600"   unknown off secure
 ttyh1   "/usr/libexec/getty std.9600"   unknown off secure
 ttyC00  "/usr/libexec/getty std.9600"   unknown off secure
 ttyC01  "/usr/libexec/getty std.9600"   unknown off secure

From: Sad Clouds <cryintothebluesky@googlemail.com>
To: gnats-bugs@NetBSD.org
Cc: Martin Husemann <martin@duskware.de>,
 port-sparc64-maintainer@netbsd.org, gnats-admin@netbsd.org,
 netbsd-bugs@netbsd.org
Subject: Re: port-sparc64/52622: Keyboard with DIN connector does not
 function with NetBSD-8 on Sun Ultra 10
Date: Thu, 19 Oct 2017 09:28:25 +0100

 If I comment out the last two lines in /etc/ttys

 #ttyC00  "/usr/libexec/getty std.9600"   unknown off secure
 #ttyC01  "/usr/libexec/getty std.9600"   unknown off secure

 then running "ttyflags -a" does not cause keyboard to hang and it works
 correctly.

From: Martin Husemann <martin@duskware.de>
To: Sad Clouds <cryintothebluesky@googlemail.com>
Cc: gnats-bugs@NetBSD.org
Subject: Re: port-sparc64/52622: Keyboard with DIN connector does not
 function with NetBSD-8 on Sun Ultra 10
Date: Sun, 29 Oct 2017 11:46:44 +0100

 Random observations: I tried a Type 5c keyboard on 8.99.5 on:

  - a U5 using machfb:
    Keyboard did not work at all once the kernel takes over, e.g. "boot -s"
    and you can't answer the shell prompt

  - a U60 using ffb:
    All works fine, can login on console in multiuser

 Both of my installations have no ttyC0{0,1} entries in /etc/ttys though,
 as they predate Matt's commit:

 date: 2015-02-23 14:52:51 +0100;  author: mrg;  state: Exp;  lines: +3 -1;  commitid: mZ5w9cpTb4tFA8by;
 add ttyC00/ttyC01 as found on eg, com(4)-based serial port systems like
 the sunblade 2500.


 On a sunblade 2500, of course, there is no kbd/ms at com:

 com0 at ebus0 addr 3083f8-3083ff ipl 29: ns16550a, working fifo
 com0: console
 kbd0 at com0 (console input)
 com1 at ebus0 addr 3062f8-3062ff ipl 2a: ns16550a, working fifo
 ms0 at com1
 wsmouse0 at ms0 mux 0

 as both mouse and keyboard are USB.

 A com* that has kbd? or ms? attached should of course not react at all
 to tty ioctl settings.

 But, as expected: adding those entries to /etc/ttys and running 
 	/etc/rc.d/ttys start
 breaks my console keyboard on the U60.


 Looking at a proper fix...

 Martin

From: "Martin Husemann" <martin@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/52622 CVS commit: src/sys/dev/sun
Date: Tue, 31 Oct 2017 10:46:47 +0000

 Module Name:	src
 Committed By:	martin
 Date:		Tue Oct 31 10:46:47 UTC 2017

 Modified Files:
 	src/sys/dev/sun: sunkbd.c sunms.c

 Log Message:
 PR port-sparc64/52622: mark the parent device as TS_KERN_ONLY,
 so userland will not touch it (and change serial params w/o our
 controll).


 To generate a diff of this commit:
 cvs rdiff -u -r1.29 -r1.30 src/sys/dev/sun/sunkbd.c
 cvs rdiff -u -r1.32 -r1.33 src/sys/dev/sun/sunms.c

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: open->pending-pullups
State-Changed-By: martin@NetBSD.org
State-Changed-When: Tue, 31 Oct 2017 10:59:53 +0000
State-Changed-Why:
[pullup-8 #338]


From: "Soren Jacobsen" <snj@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/52622 CVS commit: [netbsd-8] src/sys
Date: Mon, 6 Nov 2017 10:29:06 +0000

 Module Name:	src
 Committed By:	snj
 Date:		Mon Nov  6 10:29:06 UTC 2017

 Modified Files:
 	src/sys/arch/sparc64/dev [netbsd-8]: sab.c
 	src/sys/dev/ic [netbsd-8]: com.c z8530tty.c
 	src/sys/dev/sun [netbsd-8]: sunkbd.c sunms.c
 	src/sys/sys [netbsd-8]: tty.h

 Log Message:
 Pull up following revision(s) (requested by martin in ticket #338):
 	sys/arch/sparc64/dev/sab.c: revision 1.55
 	sys/dev/ic/com.c: revision 1.345
 	sys/dev/ic/z8530tty.c: revision 1.132
 	sys/dev/sun/sunkbd.c: revision 1.30
 	sys/dev/sun/sunms.c: revision 1.33
 	sys/sys/tty.h: revision 1.94
 As discussed on tech-kern: define a new tty internal state flag: TS_KERN_ONLY
 Implement it in a few tty drivers. If this flag is set, the underlying
 hardware is used by another driver and userland has no right to open
 it. A few uses will appear soon in sys/dev/sun/sun{kbd,ms}.c.
 --
 PR port-sparc64/52622: mark the parent device as TS_KERN_ONLY,
 so userland will not touch it (and change serial params w/o our
 control).


 To generate a diff of this commit:
 cvs rdiff -u -r1.54 -r1.54.12.1 src/sys/arch/sparc64/dev/sab.c
 cvs rdiff -u -r1.339 -r1.339.10.1 src/sys/dev/ic/com.c
 cvs rdiff -u -r1.131 -r1.131.12.1 src/sys/dev/ic/z8530tty.c
 cvs rdiff -u -r1.29 -r1.29.22.1 src/sys/dev/sun/sunkbd.c
 cvs rdiff -u -r1.32 -r1.32.22.1 src/sys/dev/sun/sunms.c
 cvs rdiff -u -r1.93 -r1.93.12.1 src/sys/sys/tty.h

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: pending-pullups->closed
State-Changed-By: maxv@NetBSD.org
State-Changed-When: Mon, 12 Feb 2018 13:32:06 +0000
State-Changed-Why:
The fix was pulled up.


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.