From owner-svn-src-all@FreeBSD.ORG Thu Oct 24 15:44:30 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id F3EE54A1; Thu, 24 Oct 2013 15:44:29 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id E0F0226BC; Thu, 24 Oct 2013 15:44:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9OFiTNM027274; Thu, 24 Oct 2013 15:44:29 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9OFiTOO027273; Thu, 24 Oct 2013 15:44:29 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201310241544.r9OFiTOO027273@svn.freebsd.org> From: Nathan Whitehorn Date: Thu, 24 Oct 2013 15:44:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r257060 - head/sys/dev/fdt X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Oct 2013 15:44:30 -0000 Author: nwhitehorn Date: Thu Oct 24 15:44:29 2013 New Revision: 257060 URL: http://svnweb.freebsd.org/changeset/base/257060 Log: Do not map IRQs twice. This fixes PowerPC/FDT systems with multiple PICs, which would try to treat the previously-mapped interrupts from fdt_decode_intr() as interrupt line numbers on the same parent PIC. Modified: head/sys/dev/fdt/fdt_common.c Modified: head/sys/dev/fdt/fdt_common.c ============================================================================== --- head/sys/dev/fdt/fdt_common.c Thu Oct 24 15:37:32 2013 (r257059) +++ head/sys/dev/fdt/fdt_common.c Thu Oct 24 15:44:29 2013 (r257060) @@ -514,7 +514,7 @@ fdt_intr_to_rl(phandle_t node, struct re pcell_t *intr; pcell_t intr_cells; int interrupt, trig, pol; - int i, intr_num, irq, rv; + int i, intr_num, rv; if (OF_getproplen(node, "interrupts") <= 0) /* Node does not have 'interrupts' property. */ @@ -566,8 +566,7 @@ fdt_intr_to_rl(phandle_t node, struct re intr_sl[i].trig = trig; intr_sl[i].pol = pol; - irq = FDT_MAP_IRQ(iph, interrupt); - resource_list_add(rl, SYS_RES_IRQ, i, irq, irq, 1); + resource_list_add(rl, SYS_RES_IRQ, i, interrupt, interrupt, 1); } out: