kern/65278: [patch] sio: kgdb debugger port initialization destroys default serial console speed

Stephan Uphoff ups at tree.com
Tue Apr 6 20:21:46 PDT 2004


>Number:         65278
>Category:       kern
>Synopsis:       [patch] sio: kgdb debugger port initialization destroys default serial console speed
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Apr 06 20:20:19 PDT 2004
>Closed-Date:
>Last-Modified:
>Originator:     Stephan Uphoff
>Release:        current
>Organization:
>Environment:
N/A
>Description:
kgdb debugger port initialization in sio.c destroys default 
serial console baud rate (comdefaultrate) if booted using a 
serial console ( boothowto & RB_SERIAL).

>How-To-Repeat:
Use sio0 as console and sio1 as kgdb port.
Boot using the serial console.

After boot-up comdefaultrate will contain an arbitrary value based on
the state of the divisor of the gdb remote port.

>Fix:
Restrict comdefaultrate changes to console ports.


==== //depot/tree/orca/src/sys/dev/sio/sio.c#2 - /usr/develop/tree/orca/src/sys/dev/sio/sio.c ====
@@ -2945,7 +2945,7 @@
 				continue;
 			iobase = port;
 			s = spltty();
-			if (boothowto & RB_SERIAL) {
+			if ((boothowto & RB_SERIAL) && COM_CONSOLE(flags)) {
 				boot_speed =
 				    siocngetspeed(iobase, comdefaultrclk);
 				if (boot_speed)

>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list