Problem with CUPS?

Matthew Dillon dillon at apollo.backplane.com
Thu Aug 19 16:47:35 PDT 2004


:Has anyone had any issues with their machines locking up soon after
:cups starts up? :-)  Nothing shows up on the console (ie. no debugger),
:but my entire machine locks solid.
:
:Adam

    Adam (and anyone with the freeze-on-serial-port or freeze-on-CUPS-start
    problem), do me a favor and try some things:

    (1) rename /dev/ttyd0, ttyd1, ttyd2, and ttyd3 to something else, e.g.
	/dev/ttyd0.x, /dev/ttyd1.x, ...  Then see if CUPS starts up.

    (2) Restore the original namings and try to run a getty on ttyd0 by
	editing /etc/ttys and HUPing init.  See if that crashes the machine.

    (3) If it does crash the machine, reboot (single user) and fix ttys back,
	remove the last modification I had made to the serial port code 
	(see patch below), and try running a getty on ttyd0 again to see if
	it still crashes.


					Matthew Dillon 
					<dillon at xxxxxxxxxxxxx>


Index: sio.c
===================================================================
RCS file: /cvs/src/sys/dev/serial/sio/sio.c,v
retrieving revision 1.17
retrieving revision 1.16
diff -u -r1.17 -r1.16
--- sio.c	3 Jul 2004 21:23:37 -0000	1.17
+++ sio.c	19 May 2004 22:52:49 -0000	1.16
@@ -31,7 +31,7 @@
  * SUCH DAMAGE.
  *
  * $FreeBSD: src/sys/isa/sio.c,v 1.291.2.35 2003/05/18 08:51:15 murray Exp $
- * $DragonFly: src/sys/dev/serial/sio/sio.c,v 1.17 2004/07/03 21:23:37 dillon Exp $
+ * $DragonFly: src/sys/dev/serial/sio/sio.c,v 1.16 2004/05/19 22:52:49 dillon Exp $
  *	from: @(#)com.c	7.5 (Berkeley) 5/16/91
  *	from: i386/isa sio.c,v 1.234
  */
@@ -733,21 +733,6 @@
 	}
 
 	/*
-	 * Make sure we can drain the receiver.  If we can't, the serial
-	 * port may not exist.
-	 */
-	for (fn = 0; fn < 256; ++fn) {
-		if ((sio_getreg(com, com_lsr) & LSR_RXRDY) == 0)
-			break;
-		(void)sio_getreg(com, com_data);
-	}
-	if (fn == 256) {
-		printf("sio%d: can't drain, serial port might "
-			"not exist, disabling\n", device_get_unit(dev));
-		return (ENXIO);
-	}
-
-	/*
 	 * Enable the interrupt gate and disable device interupts.  This
 	 * should leave the device driving the interrupt line low and
 	 * guarantee an edge trigger if an interrupt can be generated.





More information about the Bugs mailing list