From patchwork Mon Oct 13 06:41:35 2008 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ingo Molnar X-Patchwork-Id: 4129 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id D5CAFDDE0A for ; Mon, 13 Oct 2008 17:41:49 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753172AbYJMGlp (ORCPT ); Mon, 13 Oct 2008 02:41:45 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753010AbYJMGlo (ORCPT ); Mon, 13 Oct 2008 02:41:44 -0400 Received: from mx2.mail.elte.hu ([157.181.151.9]:43807 "EHLO mx2.mail.elte.hu" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752910AbYJMGln (ORCPT ); Mon, 13 Oct 2008 02:41:43 -0400 Received: from elvis.elte.hu ([157.181.1.14]) by mx2.mail.elte.hu with esmtp (Exim) id 1KpH7a-00055V-9L from ; Mon, 13 Oct 2008 08:41:40 +0200 Received: by elvis.elte.hu (Postfix, from userid 1004) id 7E4073E21A3; Mon, 13 Oct 2008 08:41:36 +0200 (CEST) Date: Mon, 13 Oct 2008 08:41:35 +0200 From: Ingo Molnar To: netdev@vger.kernel.org, "John W. Linville" Cc: Davide Pesavento , linux-kernel@vger.kernel.org Subject: net/mac80211/rx.c: fix build error Message-ID: <20081013064135.GA19719@elte.hu> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Received-SPF: neutral (mx2: 157.181.1.14 is neither permitted nor denied by domain of elte.hu) client-ip=157.181.1.14; envelope-from=mingo@elte.hu; helo=elvis.elte.hu; X-ELTE-VirusStatus: clean X-ELTE-SpamScore: -1.5 X-ELTE-SpamLevel: X-ELTE-SpamCheck: no X-ELTE-SpamVersion: ELTE 2.0 X-ELTE-SpamCheck-Details: score=-1.5 required=5.9 tests=BAYES_00, DNS_FROM_SECURITYSAGE autolearn=no SpamAssassin version=3.2.3 -1.5 BAYES_00 BODY: Bayesian spam probability is 0 to 1% [score: 0.0000] 0.0 DNS_FROM_SECURITYSAGE RBL: Envelope sender in blackholes.securitysage.com Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org FYI, the fixlet below is still needed, even after b0dee578 ("Fix modpost failure when rx handlers are not inlined."). The build error triggered on a -tip testbox. Ingo --------------> From da854dfe310ff62fda6866e13bd8588effaee51f Mon Sep 17 00:00:00 2001 From: Ingo Molnar Date: Mon, 13 Oct 2008 08:37:08 +0200 Subject: [PATCH] net/mac80211/rx.c: fix build error older versions of gcc do not recognize that ieee80211_rx_h_mesh_fwding() is unused when CONFIG_MAC80211_MESH is disabled: net/built-in.o: In function `ieee80211_rx_h_mesh_fwding': rx.c:(.text+0xd89af): undefined reference to `mpp_path_lookup' rx.c:(.text+0xd89c6): undefined reference to `mpp_path_add' as this code construct: if (ieee80211_vif_is_mesh(&sdata->vif)) CALL_RXH(ieee80211_rx_h_mesh_fwding); still causes ieee80211_rx_h_mesh_fwding() to be linked in. Protect these places with an #ifdef. commit b0dee578 ("Fix modpost failure when rx handlers are not inlined.") solved part of this problem - this patch is still needed. Signed-off-by: Ingo Molnar --- net/mac80211/rx.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index 77e7b01..cf6b121 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -1379,6 +1379,7 @@ ieee80211_rx_h_amsdu(struct ieee80211_rx_data *rx) return RX_QUEUED; } +#ifdef CONFIG_MAC80211_MESH static ieee80211_rx_result ieee80211_rx_h_mesh_fwding(struct ieee80211_rx_data *rx) { @@ -1453,7 +1454,7 @@ ieee80211_rx_h_mesh_fwding(struct ieee80211_rx_data *rx) else return RX_DROP_MONITOR; } - +#endif static ieee80211_rx_result debug_noinline ieee80211_rx_h_data(struct ieee80211_rx_data *rx) @@ -1780,8 +1781,10 @@ static void ieee80211_invoke_rx_handlers(struct ieee80211_sub_if_data *sdata, /* must be after MMIC verify so header is counted in MPDU mic */ CALL_RXH(ieee80211_rx_h_remove_qos_control) CALL_RXH(ieee80211_rx_h_amsdu) +#ifdef CONFIG_MAC80211_MESH if (ieee80211_vif_is_mesh(&sdata->vif)) CALL_RXH(ieee80211_rx_h_mesh_fwding); +#endif CALL_RXH(ieee80211_rx_h_data) CALL_RXH(ieee80211_rx_h_ctrl) CALL_RXH(ieee80211_rx_h_action)