From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arnd Bergmann Subject: Re: [PATCH 38/38] asm-generic: introduc Kbuild.generic Date: Thu, 17 Jul 2014 12:50:07 +0200 Message-ID: <5003088.VRbrHdWpA3@wuerfel> References: <20140714150609.GA28358@ravnborg.org> <4667634.oiTEQ4v5vj@wuerfel> <20140717103815.GA16291@ravnborg.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Return-path: Received: from mout.kundenserver.de ([212.227.17.10]:54004 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751221AbaGQKuO (ORCPT ); Thu, 17 Jul 2014 06:50:14 -0400 In-Reply-To: <20140717103815.GA16291@ravnborg.org> Sender: linux-arch-owner@vger.kernel.org List-ID: To: Sam Ravnborg Cc: lkml , linux-arch On Thursday 17 July 2014 12:38:15 Sam Ravnborg wrote: > > * We could improve the situation if the definition of this list is > > changed so we only generate the generic header files that are not > > already provided by an architecture. If we do this, we can consolidate > > a lot more here, which is nice, but the cost would be equivalent to > > another level of indirection and a potential for subtle bugs if it's > > not done very careful. > I think this is the way to go - and will try to give it a spin. > > Something along these lines: > include/asm-generic/Kbuild.asm will include a list of all header files > that shall be present for any architecture and may come from asm-generic. > If the architecture provide there own file - good. > If the architecture do not provide their own file => create wrapper. > > The arch provided header file comes first in the search path, > so if a wrapper was generated and later a dedicated file is added > then we will use the dedicated file and not the wrapper that points > back to asm-generic. > > The same logic applies for uapi/asm-generic as well. > > I will try to come up with an implementation of this, > then we can see if this flys. Ok, sounds good. Thanks! Arnd