NetBSD-Bugs archive

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

kern/58069: Panic when trying to connect tty



>Number:         58069
>Category:       kern
>Synopsis:       Panic when trying to connect tty
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Mar 23 18:00:01 +0000 2024
>Originator:     Frédéric Fauberteau
>Release:        NetBSD 10.99.10
>Organization:
>Environment:
System: NetBSD goliath.triaxx.org 10.99.10 NetBSD 10.99.10 (GENERIC) #0: Fri Mar 15 11:15:04 CET 2024  triaxx%goliath.triaxx.org@localhost:/usr/obj/sys/arch/amd64/compile/GENERIC amd64
Architecture: x86_64
Machine: amd64
Revision: 1.609
>Description:
According to https://www.netbsd.org/docs/kernel/kgdb.html, two machines are involded: TARGET and REMOTE.

The TARGET machine:

    $ dmesg -t | grep com0
    com0 at acpi0 (UAR1, PNP0501-0): io 0x3f8-0x3ff irq 4
    com0: ns16550a, 16-byte FIFO

    $ grep "tty00" /etc/ttys 
    tty00   "/usr/libexec/getty std.9600"   unknown off local

On REMOTE machine:

    $ dmesg -t | grep com0
    uplcom0 at uhub1 port 3
    uplcom0: Prolific Technology Inc. (0x067b) USB-Serial Controller (0x2303), rev 2.00/3.00, addr 15
    ucom0 at uplcom0

    $ grep ttyU0 /etc/ttys
    ttyU0   "/usr/libexec/getty std.9600"   unknown off local

    $ cu -l /dev/ttyU0
    Connected

The kernel of the REMOTE machine panics when trying to connect to tty00 linked to com0:

    $ gdb netbsd.1
    GNU gdb (GDB) 13.2
    Copyright (C) 2023 Free Software Foundation, Inc.
    License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
    This is free software: you are free to change and redistribute it.
    There is NO WARRANTY, to the extent permitted by law.
    Type "show copying" and "show warranty" for details.
    This GDB was configured as "x86_64--netbsd".
    Type "show configuration" for configuration details.
    For bug reporting instructions, please see:
    <https://www.gnu.org/software/gdb/bugs/>.
    Find the GDB manual and other documentation resources online at:
        <http://www.gnu.org/software/gdb/documentation/>.
    
    For help, type "help".
    Type "apropos word" to search for commands related to "word"...
    Reading symbols from netbsd.1...
    (No debugging symbols found in netbsd.1)
    (gdb) target kvm netbsd.1.core
    0xffffffff80239c85 in cpu_reboot ()
    (gdb) bt
    #0  0xffffffff80239c85 in cpu_reboot ()
    #1  0xffffffff80ddea88 in kern_reboot ()
    #2  0xffffffff80e25208 in vpanic ()
    #3  0xffffffff80e252dd in panic ()
    #4  0xffffffff80dc293d in heartbeat ()
    #5  0xffffffff80da95c6 in hardclock ()
    #6  0xffffffff8021075e in Xresume_lapic_ltimer ()
    #7  0xffffac882fc93f70 in ?? ()
    Backtrace stopped: previous frame inner to this frame (corrupt stack?)
    (gdb)

    $ addr2line -e netbsd.1 0xffffffff8021075e
    ??:?

>How-To-Repeat:
    $ cu -l /dev/tty00

or

    $ stty -a -f /dev/tty00
    speed 9600 baud; 0 rows; 0 columns; queue = 1024; line = termios;
    lflags: icanon isig iexten echo echoe -echok echoke -echonl echoctl
            -echoprt -altwerase -noflsh -tostop -flusho -pendin -nokerninfo
            -extproc
    iflags: -istrip icrnl -inlcr -igncr ixon -ixoff ixany imaxbel -ignbrk
            brkint -inpck -ignpar -parmrk
    oflags: opost onlcr -ocrnl -oxtabs -onocr -onlret
    cflags: cread cs8 -parenb -parodd hupcl clocal -cstopb -crtscts -mdmbuf
            -cdtrcts
    cchars: discard = ^O; dsusp = ^Y; eof = ^D; eol = <undef>;
            eol2 = <undef>; erase = ^?; intr = ^C; kill = ^U; lnext = ^V;
            min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T;
            stop = ^S; susp = ^Z; time = 0; werase = ^W;
>Fix:



Home | Main Index | Thread Index | Old Index