From patchwork Tue Feb 28 11:38:33 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Lindner X-Patchwork-Id: 143424 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.180.67]) by ozlabs.org (Postfix) with ESMTP id EA6D2B6EEE for ; Tue, 28 Feb 2012 22:39:04 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757124Ab2B1LjC (ORCPT ); Tue, 28 Feb 2012 06:39:02 -0500 Received: from nm11-vm0.bullet.mail.ukl.yahoo.com ([217.146.183.244]:23156 "HELO nm11-vm0.bullet.mail.ukl.yahoo.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1754958Ab2B1LjA (ORCPT ); Tue, 28 Feb 2012 06:39:00 -0500 Received: from [217.146.183.216] by nm11.bullet.mail.ukl.yahoo.com with NNFMP; 28 Feb 2012 11:38:59 -0000 Received: from [77.238.184.60] by tm9.bullet.mail.ukl.yahoo.com with NNFMP; 28 Feb 2012 11:38:59 -0000 Received: from [127.0.0.1] by smtp129.mail.ukl.yahoo.com with NNFMP; 28 Feb 2012 11:38:59 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.de; s=s1024; t=1330429139; bh=76PCkXAHgDQD9HvbuLarAO34SOCHsXpr6DOtK+GDn78=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Received:From:To:Cc:Subject:Date:Message-Id:X-Mailer:In-Reply-To:References; b=ZynRyyhKK2S/gkzvQFc4a1Mexj5imdP1YvOAluqVJ+UzzBE9VD2HyACx4mlYVRx/SsaKSB89AwV0LXbnYgq8FcfYMnllIY0qGAYZkDUOKqHxSiWaxTcdBaPtnlP0Gmr/lfAZW7fNiWEaH8alQwgdkIzDBrC0PhPqzapW2u9JubA= X-Yahoo-Newman-Id: 610912.69032.bm@smtp129.mail.ukl.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: GAABR90VM1kAa6LomTTk.h20BqTzQX.vLfvLz9exfaIzLLI 3ZbGCXpsx7z.IrymZ8Aa2hqXrv9JiIHNikDd5.lv1IGXsmF1T1JjLIEizltz Ofp7BAD8Wc8UBReEULO.A4JHQeewhwArZ2vE9gqvhkTdt54EYaVXzq0yq8K4 9OV7bIPriFf80BUKudHR0zwFsjJdyj1HVwERiL4hjdaBFTKq3fpLmdIkaLbh 4LvMvyDv7F98TK344TBzUQ_3DXalCZSH4WTk42sFyVUfjUhUDh9w4brQ_rvb 6X9dxo1yHR5z3T5Xcx5zzwC7nGS5swF6RLrTyEYPCz_1eYDsLSohncliykos InTPUGl.OWekUnC6ePo9IEf2Up8CPsKSO04bfiz0iZbLFKNV7od7OGO0zq7Q eEZDCMxqlUlA- X-Yahoo-SMTP: tW.h3tiswBBMXO2coYcbPigGD5Lt6zY_.Zc- Received: from localhost (lindner_marek@59.152.213.162 with plain) by smtp129.mail.ukl.yahoo.com with SMTP; 28 Feb 2012 11:38:58 +0000 GMT From: Marek Lindner To: davem@davemloft.net Cc: netdev@vger.kernel.org, b.a.t.m.a.n@lists.open-mesh.org, Antonio Quartulli , Marek Lindner Subject: [PATCH 6/8] batman-adv: TT_CLIENT_PENDING is never set in struct tt_global_entry Date: Tue, 28 Feb 2012 19:38:33 +0800 Message-Id: <1330429113-23409-1-git-send-email-lindner_marek@yahoo.de> X-Mailer: git-send-email 1.7.9 In-Reply-To: <1330428748-23137-1-git-send-email-lindner_marek@yahoo.de> References: <1330428748-23137-1-git-send-email-lindner_marek@yahoo.de> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Antonio Quartulli Actually the TT_CLIENT_PENDING flag is never set in the tt_global_entry structure, therefore this code is useless and can be removed. Reported-by: Simon Wunderlich Signed-off-by: Antonio Quartulli Signed-off-by: Marek Lindner --- net/batman-adv/translation-table.c | 9 +-------- 1 files changed, 1 insertions(+), 8 deletions(-) diff --git a/net/batman-adv/translation-table.c b/net/batman-adv/translation-table.c index 1ff7fbe..9a6f315 100644 --- a/net/batman-adv/translation-table.c +++ b/net/batman-adv/translation-table.c @@ -603,7 +603,7 @@ int tt_global_seq_print_text(struct seq_file *seq, void *offset) struct tt_global_entry, common); seq_printf(seq, " * %pM (%3u) via %pM (%3u) " - "[%c%c%c]\n", + "[%c%c]\n", tt_global_entry->common.addr, tt_global_entry->ttvn, tt_global_entry->orig_node->orig, @@ -613,8 +613,6 @@ int tt_global_seq_print_text(struct seq_file *seq, void *offset) (tt_global_entry->common.flags & TT_CLIENT_ROAM ? 'R' : '.'), (tt_global_entry->common.flags & - TT_CLIENT_PENDING ? 'X' : '.'), - (tt_global_entry->common.flags & TT_CLIENT_WIFI ? 'W' : '.')); } rcu_read_unlock(); @@ -838,11 +836,6 @@ struct orig_node *transtable_search(struct bat_priv *bat_priv, if (!atomic_inc_not_zero(&tt_global_entry->orig_node->refcount)) goto out; - /* A global client marked as PENDING has already moved from that - * originator */ - if (tt_global_entry->common.flags & TT_CLIENT_PENDING) - goto out; - orig_node = tt_global_entry->orig_node; out: