From owner-freebsd-bugs@FreeBSD.ORG Mon Aug 10 17:00:15 2009 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2F4001065670 for ; Mon, 10 Aug 2009 17:00:15 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 034B08FC23 for ; Mon, 10 Aug 2009 17:00:15 +0000 (UTC) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n7AH0ETh007498 for ; Mon, 10 Aug 2009 17:00:14 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n7AH0EtF007497; Mon, 10 Aug 2009 17:00:14 GMT (envelope-from gnats) Date: Mon, 10 Aug 2009 17:00:14 GMT Message-Id: <200908101700.n7AH0EtF007497@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Arrigo Marchiori Cc: Subject: Re: kern/132172: [panic] Page fault panic in scioctl and console-kit-daemon (port: sysutils/consolekit on 6.4-STABLE) X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Arrigo Marchiori List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Aug 2009 17:00:15 -0000 The following reply was made to PR kern/132172; it has been noted by GNATS. From: Arrigo Marchiori To: bug-followup@FreeBSD.org, ardovm@yahoo.it Cc: Subject: Re: kern/132172: [panic] Page fault panic in scioctl and console-kit-daemon (port: sysutils/consolekit on 6.4-STABLE) Date: Mon, 10 Aug 2009 18:32:48 +0200 --liOOAslEiF7prFVr Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Hello, I have adapted this patch: http://lists.freebsd.org/pipermail/freebsd-current/attachments/20080221/6f6e5ded/sys_dev_syscons.obj to the file /usr/src/sys/dev/syscons/syscons.c as in 6.4-STABLE, cvsup'ed today. When this patch is applied, the panic seems to disappear. BUT: I actually don't know what this patch does! I just blindly adapted to "our" file, by finding the similar lines. I think we need a kernel developer to check that this patch doesn't generate other problems. Hope this helps, -- rigo http://rigo.altervista.org --liOOAslEiF7prFVr Content-Type: text/plain; charset=utf-8 Content-Disposition: attachment; filename="syscons_c_patch.txt" --- syscons.c.old 2009-08-10 16:22:28.000000000 +0200 +++ syscons.c 2009-08-10 16:22:18.000000000 +0200 @@ -1052,15 +1052,9 @@ i = (*(int *)data == 0) ? scp->index : (*(int *)data - 1); if ((i < sc->first_vty) || (i >= sc->first_vty + sc->vtys)) return EINVAL; - s = spltty(); - error = sc_clean_up(sc->cur_scp); - splx(s); - if (error) - return error; - scp = sc_get_stat(SC_DEV(sc, i)); - if (scp == scp->sc->cur_scp) + if (i == sc->cur_scp->index) return 0; - error = tsleep(&scp->smode, PZERO | PCATCH, "waitvt", 0); + error = tsleep(SC_DEV(sc, i), PZERO | PCATCH, "waitvt", 0); return error; case VT_GETACTIVE: /* get active vty # */ @@ -2336,7 +2330,7 @@ * be invoked at splhigh(). */ if (debugger == 0) - wakeup(&sc->new_scp->smode); + wakeup(SC_DEV(sc, next_scr)); splx(s); DPRINTF(5, ("switch done (new == old)\n")); return 0; @@ -2359,7 +2353,7 @@ /* wake up processes waiting for this vty */ if (debugger == 0) - wakeup(&sc->cur_scp->smode); + wakeup(SC_DEV(sc, next_scr)); /* wait for the controlling process to acknowledge, if necessary */ if (signal_vt_acq(sc->cur_scp)) { @@ -2385,7 +2379,7 @@ exchange_scr(sc); s = spltty(); /* sc->cur_scp == sc->new_scp */ - wakeup(&sc->cur_scp->smode); + wakeup(SC_DEV(sc, sc->cur_scp->index)); /* wait for the controlling process to acknowledge, if necessary */ if (!signal_vt_acq(sc->cur_scp)) { --liOOAslEiF7prFVr--