From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from wa-out-1112.google.com ([209.85.146.181]:41945 "EHLO wa-out-1112.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932748AbXIKBSO (ORCPT ); Mon, 10 Sep 2007 21:18:14 -0400 Received: by wa-out-1112.google.com with SMTP id v27so1775931wah for ; Mon, 10 Sep 2007 18:18:11 -0700 (PDT) Message-ID: <6b8cef970709101818g72366544ve1a75804f79499e3@mail.gmail.com> Date: Mon, 10 Sep 2007 21:18:11 -0400 From: "Rob Hussey" To: "Magnus Damm" Subject: Re: [PATCH] cfg80211: fix initialisation if built-in Cc: "Johannes Berg" , "John W. Linville" , linux-wireless , netdev , stable@kernel.org In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 References: <1189424685.4506.63.camel@johannes.berg> Sender: linux-wireless-owner@vger.kernel.org List-ID: On 9/10/07, Magnus Damm wrote: > -module_init(rate_control_simple_init); > +//module_init(rate_control_simple_init); > +postcore_initcall(rate_control_simple_init); > module_exit(rate_control_simple_exit); > > MODULE_DESCRIPTION("Simple rate control algorithm for ieee80211"); Same problem here, except with the rt2x00 driver. I changed it to subsys_initcall(rate_control_simple_init), which also worked. I also found that without this change, it was failing at this point in ieee80211_rate.c: ieee80211_try_rate_control_ops_get(const char *name) { struct rate_control_alg *alg; struct rate_control_ops *ops = NULL; mutex_lock(&rate_ctrl_mutex); list_for_each_entry(alg, &rate_ctrl_algs, list) { <===== Here if (!name || !strcmp(alg->ops->name, name)) if (try_module_get(alg->ops->module)) { ops = alg->ops; break; }