Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Mon, 10 Mar 2003 12:50:36 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Mon, 10 Mar 2003 12:50:36 -0500 Received: from 12-231-249-244.client.attbi.com ([12.231.249.244]:5395 "HELO kroah.com") by vger.kernel.org with SMTP id ; Mon, 10 Mar 2003 12:50:34 -0500 Date: Mon, 10 Mar 2003 09:50:44 -0800 From: Greg KH To: Stephen Cameron Cc: linux-kernel@vger.kernel.org, michael.ni@hp.com, torben.mathiasen@hp.com Subject: Re: PCI hotplug w/ drivers linked statically vs. module Message-ID: <20030310175044.GB9792@kroah.com> References: <20030307032740.GA5236@zuul.cca.cpqcorp.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030307032740.GA5236@zuul.cca.cpqcorp.net> User-Agent: Mutt/1.4i Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1191 Lines: 31 On Fri, Mar 07, 2003 at 09:27:40AM +0600, Stephen Cameron wrote: > > I noticed a difference in behavior with PCI hotplug, depending > on if the driver in questino is loaded as a module, or statically > linked. > > For example, the tg3 driver, hot-unplugging, then hot-replugging > works seemingly well if the driver is a module, but differnetly (poorly?) > if it is statically linked. (eth0 disappears and does not come > back.) Is the tg3 driver's remove() function actually being called? In looking at the driver, the callback is declared properly, so it should be present when building the driver into the kernel. > So why the difference in behavior with PCI hotplug and drivers > linked statically vs. as a module? I have no idea right now, sorry. Only thing I can think of is you have to mark the remove function as "__devexit" and not "__exit" to make sure the function is really there if CONFIG_HOTPLUG is enabled. thanks, greg k-h - 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/