From owner-p4-projects@FreeBSD.ORG Tue Oct 21 02:33:58 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id BB7681065699; Tue, 21 Oct 2008 02:33:58 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7EF7B1065675 for ; Tue, 21 Oct 2008 02:33:58 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 6D9B48FC08 for ; Tue, 21 Oct 2008 02:33:58 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id m9L2XwPR009509 for ; Tue, 21 Oct 2008 02:33:58 GMT (envelope-from nwhitehorn@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id m9L2Xwhv009507 for perforce@freebsd.org; Tue, 21 Oct 2008 02:33:58 GMT (envelope-from nwhitehorn@freebsd.org) Date: Tue, 21 Oct 2008 02:33:58 GMT Message-Id: <200810210233.m9L2Xwhv009507@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to nwhitehorn@freebsd.org using -f From: Nathan Whitehorn To: Perforce Change Reviews Cc: Subject: PERFORCE change 151641 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Oct 2008 02:33:59 -0000 http://perforce.freebsd.org/chv.cgi?CH=151641 Change 151641 by nwhitehorn@nwhitehorn_trantor on 2008/10/21 02:33:00 Missed part of the last commit in nexus. Affected files ... .. //depot/projects/ppc-g5/sys/powerpc/aim/nexus.c#5 edit Differences ... ==== //depot/projects/ppc-g5/sys/powerpc/aim/nexus.c#5 (text+ko) ==== @@ -447,6 +447,7 @@ start = (vm_offset_t)rman_get_start(res); p = pmap_mapdev(start, (vm_size_t)rman_get_size(res)); + if (p == NULL) return (ENOMEM); rman_set_virtual(res, p); @@ -461,7 +462,10 @@ nexus_deactivate_resource(device_t bus, device_t child, int type, int rid, struct resource *res) { - /* Not much to be done yet... */ + if (type == SYS_RES_MEMORY || type == SYS_RES_IOPORT) { + pmap_unmapdev((vm_offset_t)rman_get_virtual(res), + (vm_size_t)rman_get_size(res)); + } return (rman_deactivate_resource(res)); } @@ -469,12 +473,7 @@ nexus_release_resource(device_t bus, device_t child, int type, int rid, struct resource *res) { - if (type != SYS_RES_IRQ) { - device_printf(bus, "unknown resource request from %s\n", - device_get_nameunit(child)); - return (EINVAL); - } - + /* Not much to be done yet... */ return (rman_release_resource(res)); }