Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Mon, 30 Sep 2002 08:34:10 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Mon, 30 Sep 2002 08:34:10 -0400 Received: from as8-6-1.ens.s.bonet.se ([217.215.92.25]:63506 "EHLO zoo.weinigel.se") by vger.kernel.org with ESMTP id ; Mon, 30 Sep 2002 08:34:09 -0400 To: Alan Cox Cc: Linus Torvalds , linux-kernel@vger.kernel.org Subject: Re: NatSemi SCx200 patches for Linux-2.5 References: <87d6qvyb4c.fsf@zoo.weinigel.se> <1033388216.16266.1.camel@irongate.swansea.linux.org.uk> From: Christer Weinigel Organization: Weinigel Ingenjorsbyra AB Date: 30 Sep 2002 14:39:33 +0200 In-Reply-To: <1033388216.16266.1.camel@irongate.swansea.linux.org.uk> Message-ID: <87u1k7wt16.fsf@zoo.weinigel.se> User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1411 Lines: 28 Alan Cox writes: > On Mon, 2002-09-30 at 12:23, Christer Weinigel wrote: > > How can I guarantee that the driver scx200.c is initialized before any > > other drivers that use the scx200_gpio functions (e.g. scx200_i2c.c)? > > I have put scx200.c in in arch/i386/kernel in the hope that this > > directory will always be initialized before anything else, but is this > > really true? > > There are two ways. For built in code you can use the link order to > force ordering. In 2.4 thats your only real choice. For modules you need > to ensure there is a dependancy so modprobe loads the supporting module > first I'll just assume that it works then. With the current link order in 2.5 it works when compiled into the kernel and for the module case there is an explicit dependency. Now I just have to merge back a few things to the 2.4 code; I found a few uglies and want to see if the link order trick works with 2.4. /Christer -- "Just how much can I get away with and still go to heaven?" Freelance consultant specializing in device driver programming for Linux Christer Weinigel http://www.weinigel.se - 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/