From owner-svn-src-head@freebsd.org Tue Jul 19 15:26:39 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 65DC3B9D26B; Tue, 19 Jul 2016 15:26:39 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from c.mail.sonic.net (c.mail.sonic.net [64.142.111.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 450191509; Tue, 19 Jul 2016 15:26:38 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from zeppelin.tachypleus.net (75-101-50-44.static.sonic.net [75.101.50.44]) (authenticated bits=0) by c.mail.sonic.net (8.15.1/8.15.1) with ESMTPSA id u6JFQYDv012568 (version=TLSv1.2 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); Tue, 19 Jul 2016 08:26:35 -0700 Subject: Re: svn commit: r301453 - in head/sys: arm/arm arm64/arm64 dev/fdt dev/gpio dev/iicbus dev/ofw dev/pci dev/vnic kern mips/mips sys To: Michal Meloun , Svatopluk Kraus , src-committers@FreeBSD.org, svn-src-all@FreeBSD.org, svn-src-head@FreeBSD.org References: <201606051620.u55GKD5S066398@repo.freebsd.org> <578E0B5D.3070105@FreeBSD.org> From: Nathan Whitehorn Message-ID: <7a60092c-392c-abbe-c794-3c4c71e372f0@freebsd.org> Date: Tue, 19 Jul 2016 08:26:34 -0700 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.1.0 MIME-Version: 1.0 In-Reply-To: <578E0B5D.3070105@FreeBSD.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Sonic-CAuth: UmFuZG9tSVbe8T1JFYBikiFadjv2TeGa2CpyTv0mcA9kaHHU2g6r/Bqo94awLuv3tgHAoiGJTPUcqzCMpUMLqB1tbbE7MP+zi1UOaZKeT9Y= X-Sonic-ID: C;PrNtLcVN5hG2aptMTlz00w== M;Bu/DLcVN5hG2aptMTlz00w== X-Spam-Flag: No X-Sonic-Spam-Details: 0.0/5.0 by cerberusd X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.22 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: Tue, 19 Jul 2016 15:26:39 -0000 On 07/19/16 04:13, Michal Meloun wrote: > Dne 19.07.2016 v 2:11 Nathan Whitehorn napsal(a): > Hi Nathan, > I’m afraid that skra is on vacation, for next 2 weeks (at minimum), so > please don’t expect quick response. > >> Could you please describe what this change is in more detail? > Short description is appended. > >> It breaks a lot of encapsulations we have worked very hard to maintain, >> moves ARM code into MI parts of the kernel, and the OFW parts violate >> IEEE 1275 (the Open Firmware standard). In particular, there is no >> guarantee that the interrupts for a newbus (or OF) device are encoded in >> a property called "interrupts" (or, indeed, in any property at all) on >> that node and there are many, many device trees where that is not the >> case (e.g. ones with interrupt maps, as well as Apple hardware). By >> putting that knowledge into the OF root bus device, which we have tried >> to keep it out of, this enforces a standard that doesn't actually exist. > Imho, this patch doesn’t change anything in this area. Only handling of > “interrupts” property is changed, all other cases are unchanged (I > hope). Also, INTRNG code is currently shared by ARM, ARM64 and MIPS. > >> I'm hesitant to ask for reversion on something that landed 6 weeks ago >> without me noticing, but this needs a lot more architectural work before >> any parts of the kernel should use it. >> -Nathan > I think that it’s too late. This patch series consist of r301451 > (https://reviews.freebsd.org/D6632), > r301453, r301539 and 301543. And new GPIO interrupts are currently used > (by in tree drivers or in development trees). > > [See other email for information for detail on why I am concerned about this code] Looking through those commits and the current state of HEAD, it turns out bus_map_intr() is not yet used anywhere in the tree; there is just a stub implementation in dev/ofw/ofwbus.c and a prototype that is never called in sys/bus.h. As such, I would in fact like to ask for the reversion of both r301451 and r301453 at this point, especially from the stable/11 branch. Adding a new API is something we can do to stable/11 at any point; removing one, or changing one, is something we cannot do. After that, I am more than happy to help move ARM code to use the existing dev/ofw scheme for handling interrupt metadata. -Nathan