Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933647AbbLOPRu (ORCPT ); Tue, 15 Dec 2015 10:17:50 -0500 Received: from mail.windriver.com ([147.11.1.11]:46160 "EHLO mail.windriver.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752923AbbLOPRr (ORCPT ); Tue, 15 Dec 2015 10:17:47 -0500 Date: Tue, 15 Dec 2015 10:16:24 -0500 From: Paul Gortmaker To: Arnd Bergmann CC: Thierry Reding , Ley Foon Tan , Geert Uytterhoeven , "linux-kernel@vger.kernel.org" , Linux-sh list , linux-pci , Alexandre Courbot , Pratyush Anand , Michal Simek , Kishon Vijay Abraham I , Murali Karicheri , =?iso-8859-1?Q?S=F6ren?= Brinkmann , Jason Cooper , Stephen Warren , Simon Horman , , "linux-omap@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , Thomas Petazzoni , Richard Zhu , Rocketboard Maillist , Bjorn Helgaas , Lucas Stach Subject: Re: [PATCH 00/10] drivers/pci: avoid module_init in non-modular host/pci* Message-ID: <20151215151624.GB2772@windriver.com> References: <1449970917-12633-1-git-send-email-paul.gortmaker@windriver.com> <20151214091940.GA15126@ulmo.nvidia.com> <3302340.SIljl1qYTl@wuerfel> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <3302340.SIljl1qYTl@wuerfel> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2310 Lines: 51 [Re: [PATCH 00/10] drivers/pci: avoid module_init in non-modular host/pci*] On 14/12/2015 (Mon 11:27) Arnd Bergmann wrote: > On Monday 14 December 2015 10:19:40 Thierry Reding wrote: > > > PCIe host driver that use fixup (DECLARE_PCI_FIXUP_*) can't use tristate. > > > Fixup region is in kernel region and this region if not updated when > > > loading a module. > > > > Interesting, I hadn't thought about that. I suppose this means that the > > module will end up containing an unused section with the fixup code. It > > might be useful to add a way for that to trigger a warning at build > > time. > > > > Perhaps to fix this a mechanism could be introduced to add a table of > > fixups to a host controller driver and that will get applied to all > > children of the bridge. It could be problematic to cover all of the > > different fixup stages, though. > > > > > I think a lot of the fixups shouldn't really be there in the first place, > they are about stuff that we can fix up in the probe function, or that should > be fixed up in the probe function with some appropriate core support added. So, the feedback on this is a bit all over the map, leaving me unsure what to do next. And is the choice we make on a per board/bsp basis or ideally across all platforms? I see the choices as: 1) do nothing; which IMHO is least desirable as it leaves the code misrepresenting itself as modular; one of the key issues I wanted to fix 2) use the patches I've sent ; then as they are genuinely made modular, the person doing so essentially "patch -R" or reverts the change as step one. This has the advantage of solving the "we'll get to it someday" issue if someday never comes. 3) make them all tristate; beat it with a stick until it compiles [M] and modposts -- leaving the fixups and functional testing to people with the boards and low level knowledge to make it _work_ as a module. The downside here is the code is still kind of misrepresenting itself as modularly functional -- a ban of unloading might mitigate that some. Paul. -- > > Arnd -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/