From c00595ba565f6ddcedf271268dc6fa3714186f40 Mon Sep 17 00:00:00 2001 From: dg Date: Wed, 25 Jan 1995 20:36:29 +0000 Subject: [PATCH] Don't attempt to clean device_pager backed objects at terminate time. There is similar bogusness in the pageout daemon that will be fixed soon. This fixes a panic pointed out to me by Bruce Evans that occurs when /dev/mem is used to map managed memory. --- sys/vm/vm_object.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/vm/vm_object.c b/sys/vm/vm_object.c index e5424cb8fde5..bbdb707f8f84 100644 --- a/sys/vm/vm_object.c +++ b/sys/vm/vm_object.c @@ -61,7 +61,7 @@ * any improvements or extensions that they make and grant Carnegie the * rights to redistribute these changes. * - * $Id: vm_object.c,v 1.18 1995/01/13 13:30:24 davidg Exp $ + * $Id: vm_object.c,v 1.19 1995/01/24 10:13:14 davidg Exp $ */ /* @@ -384,7 +384,8 @@ vm_object_terminate(object) * object are gone, so we don't need to lock it. */ - if ((object->flags & OBJ_INTERNAL) == 0) { + if (((object->flags & OBJ_INTERNAL) == 0) && + object->pager && (object->pager->pg_type != PG_DEVICE)) { (void) vm_object_page_clean(object, 0, 0, TRUE, TRUE); } /*