From owner-cvs-all Mon Aug 23 22:58:55 1999 Delivered-To: cvs-all@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 161D914E23; Mon, 23 Aug 1999 22:58:48 -0700 (PDT) (envelope-from green@FreeBSD.org) Received: (from green@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id WAA62735; Mon, 23 Aug 1999 22:58:37 -0700 (PDT) (envelope-from green@FreeBSD.org) Message-Id: <199908240558.WAA62735@freefall.freebsd.org> From: Brian Feldman Date: Mon, 23 Aug 1999 22:58:36 -0700 (PDT) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/vm vm_swap.c Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk green 1999/08/23 22:58:36 PDT Modified files: sys/vm vm_swap.c Log: When the SYSINIT() was removed, it was replaced with a make_dev on-demand creation of /dev/drum via calling swapon. However, the make_dev has a bogus (insofar that it hasn't been added yet) cdevsw, so later we end up crashing with a null pointer dereference on the swap vp's specinfo. The specinfo points to a dev_t with a major of 254 (uninitialized), and we get a crash on its d_strategy being called. The simple solution to this is to call cdevsw_add before the make_dev is ever used. This fixes the panic which occurred upon swapping. Revision Changes Path 1.83 +2 -1 src/sys/vm/vm_swap.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message