From owner-svn-src-head@FreeBSD.ORG Fri Jan 4 20:29:06 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E3D7BCA5; Fri, 4 Jan 2013 20:29:06 +0000 (UTC) (envelope-from andrew@fubar.geek.nz) Received: from smtp-out3.electric.net (smtp-out3.electric.net [72.35.12.188]) by mx1.freebsd.org (Postfix) with ESMTP id C79EE7A7; Fri, 4 Jan 2013 20:29:06 +0000 (UTC) Received: from [204.11.168.155] (helo=securemail.onebox.com) by opel.electric.net with esmtp (Exim 4.77) (envelope-from ) id 1TrDsx-0008Ma-Us; Fri, 04 Jan 2013 12:28:59 -0800 Received: from localhost (unverified [49.225.56.12]) by securemail.onebox.com (Rockliffe SMTPRA 9.3.1) with ESMTP id ; Fri, 4 Jan 2013 15:29:01 -0500 Date: Sat, 5 Jan 2013 09:28:42 +1300 From: Andrew Turner To: Nathan Whitehorn Subject: Re: svn commit: r244899 - head/sys/mips/beri Message-ID: <20130105092842.15c64ac5@fubar.geek.nz> In-Reply-To: <50E70D1E.5060208@freebsd.org> References: <201212311106.qBVB6chM016661@svn.freebsd.org> <20130102081746.5435db05@fubar.geek.nz> <20130102110856.7c280fd5@fubar.geek.nz> <0E1E1A5C-BB34-4B82-828F-6FEE770A6037@FreeBSD.org> <20130103100258.2e22763f@fubar.geek.nz> <50E70D1E.5060208@freebsd.org> Organization: SMTP: smtp.paradise.net.nz X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; i386-portbld-freebsd8.1) X-Pirate: Arrrr Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, "Robert N. M. Watson" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 04 Jan 2013 20:29:07 -0000 On Fri, 04 Jan 2013 12:10:54 -0500 Nathan Whitehorn wrote: > On 01/02/13 16:02, Andrew Turner wrote: > > The patch looks good. From my reading of [1] the compatible value > > should be something like "mips,mips4k" as it's value is of the form > > ",". > > > > I have been thinking the best way of merging these almost identical > > decode functions. Linux appears to do it by providing a > > per-controller function that can translate between the interrupt > > spec and the configuration allowing them to have a generic parsing > > function that doesn't need to check if the controller is > > compatible. I would like us to have something similar as it will > > remove the duplicate function. > > > > Andrew > > > > [1] http://www.devicetree.org/Device_Tree_Usage > PowerPC does something very much like this currently in the real OF > case. Looking at the contents of /sys/dev/fdt, it seems like there is > a lot of code duplication in particular with interrupts and PCI > handling compared to the equivalent parts of /sys/dev/ofw (and a few > extra things that are actually MI like /sys/powerpc/ofw_pci*). It > would be very nice if we could make FDT follow the normal OF > codepaths instead of (partially) reinventing the wheel. > -Nathan Ok, I'll look to figure out how much of this code we can use with FDT. Andrew