From owner-cvs-src@FreeBSD.ORG Fri Aug 20 16:52:44 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BF14916A4CE; Fri, 20 Aug 2004 16:52:44 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B247143D5A; Fri, 20 Aug 2004 16:52:44 +0000 (GMT) (envelope-from njl@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.11/8.12.11) with ESMTP id i7KGqiCm030058; Fri, 20 Aug 2004 16:52:44 GMT (envelope-from njl@repoman.freebsd.org) Received: (from njl@localhost) by repoman.freebsd.org (8.12.11/8.12.11/Submit) id i7KGqiRb030057; Fri, 20 Aug 2004 16:52:44 GMT (envelope-from njl) Message-Id: <200408201652.i7KGqiRb030057@repoman.freebsd.org> From: Nate Lawson Date: Fri, 20 Aug 2004 16:52:44 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/dev/acpica acpi_resource.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Aug 2004 16:52:44 -0000 njl 2004-08-20 16:52:44 UTC FreeBSD src repository Modified files: sys/dev/acpica acpi_resource.c Log: Correctly handle BIOS resources that are duplicated (!). There are many systems that have overlapping regions specified in their sysresource objects. This patch fixes ATA DMA and acpi_timer allocation for such sysctems. It should eventually be moved to resource_list_add() if it is a valid generalized approach. The minimal approach for 5.3 is: "Loop through all current resources to see if the new one overlaps any existing ones. If so, the old one always takes precedence and the new one is adjusted (or rejected). We check for three cases: 1. Tail of new resource overlaps head of old resource: truncate the new resource so it is contiguous with the start of the old. 2. New resource wholly contained within the old resource: error. 3. Head of new resource overlaps tail of old resource: truncate the new resource so it is contiguous, following the old." Tested by: Radek Kozlowski Discussed with: imp MFC after: 4 days Revision Changes Path 1.29 +49 -4 src/sys/dev/acpica/acpi_resource.c