From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030186AbbCSRJv (ORCPT ); Thu, 19 Mar 2015 13:09:51 -0400 Received: from mail-vc0-f174.google.com ([209.85.220.174]:48595 "EHLO mail-vc0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756493AbbCSRJq (ORCPT ); Thu, 19 Mar 2015 13:09:46 -0400 Date: Thu, 19 Mar 2015 13:09:42 -0400 From: Tejun Heo To: Dmitry Torokhov Cc: Borislav Petkov , Doug Thompson , linux-kernel@vger.kernel.org, linux-edac@vger.kernel.org, Mauro Carvalho Chehab , Tetsuo Handa , Olof Johansson , Arjan van de Ven , Greg Kroah-Hartman , "Luis R . Rodriguez" Subject: Re: [PATCH 3/3] EDAC: amd64_edac: decide if driver can load successfully early. Message-ID: <20150319170942.GQ25365@htj.duckdns.org> References: <1426726150-983-4-git-send-email-dmitry.torokhov@gmail.com> <20150319094054.GC10860@pd.tnic> <20150319152957.GI25365@htj.duckdns.org> <20150319153505.GD11715@pd.tnic> <20150319155253.GA30732@dtor-ws> <20150319155953.GF11715@pd.tnic> <20150319161226.GC30732@dtor-ws> <20150319162301.GH11715@pd.tnic> <20150319163330.GN25365@htj.duckdns.org> <20150319165231.GG30732@dtor-ws> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150319165231.GG30732@dtor-ws> 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 Hello, Dmitry. On Thu, Mar 19, 2015 at 09:52:31AM -0700, Dmitry Torokhov wrote: > I do not think you can teach it to the driver model in general: there is > no definite point when probing is "done". The drivers and devices come > and go, at random moments in time. I mean, it can check right after the initial iteration is complete. More below. > So here the driver just assumes that all devices will be enumerated > before the driver is loaded and acts upon this knowledge. The whole > schema is fragile (I mean can I compile it in the kernel and see > breaking because of link order changes and driver is now initialized > before PCI devices are scanned? Possibly...). So yeah, I agree with you. This is a totally unnecessary and fragile hack which shouldn't exist. The point of pushing "do it in a generic manner" is forcing people to step away from their myopic views. It's kinda easy to get trapped in one's own bubble and trying to apply the solution (or even the problem itself) at larger scale often helps actually understanding the larger picture. And there are off chances that the person sees a clear use case that other people fail to see. If the person can come up with an acceptable generic mechanism which can justify its complexity, it's a win-win situation. Thanks. -- tejun