From patchwork Thu Aug 12 15:03:03 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jon Mason X-Patchwork-Id: 61619 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 BC4FBB70CB for ; Fri, 13 Aug 2010 01:02:36 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753744Ab0HLPCc (ORCPT ); Thu, 12 Aug 2010 11:02:32 -0400 Received: from mail-px0-f174.google.com ([209.85.212.174]:53355 "EHLO mail-px0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753373Ab0HLPCb (ORCPT ); Thu, 12 Aug 2010 11:02:31 -0400 Received: by pxi10 with SMTP id 10so465376pxi.19 for ; Thu, 12 Aug 2010 08:02:31 -0700 (PDT) Received: by 10.114.52.17 with SMTP id z17mr231306waz.53.1281625350972; Thu, 12 Aug 2010 08:02:30 -0700 (PDT) Received: from arkham.kudzu.us (cpe-72-177-2-76.austin.res.rr.com [72.177.2.76]) by mx.google.com with ESMTPS id 33sm2520608wad.6.2010.08.12.08.02.27 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 12 Aug 2010 08:02:30 -0700 (PDT) Received: by arkham.kudzu.us (sSMTP sendmail emulation); Thu, 12 Aug 2010 10:03:04 -0500 From: Jon Mason To: David Miller Cc: netdev@vger.kernel.org, Ramkrishna Vepa , Sivakumar Subramani , Sreenivasa Honnur Subject: [PATCH 1/2] s2io: remove unused code Date: Thu, 12 Aug 2010 10:03:03 -0500 Message-Id: <1281625384-26927-1-git-send-email-jon.mason@exar.com> X-Mailer: git-send-email 1.7.0.4 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org usr_addrs is never referenced outside the initial struct population during open, thus making it unnecessary. Remove it, the code that references it, and the struct that it is the only user of. Signed-off-by: Jon Mason --- drivers/net/s2io.c | 2 -- drivers/net/s2io.h | 8 -------- 2 files changed, 0 insertions(+), 10 deletions(-) diff --git a/drivers/net/s2io.c b/drivers/net/s2io.c index 18bc5b7..0124f12 100644 --- a/drivers/net/s2io.c +++ b/drivers/net/s2io.c @@ -5124,8 +5124,6 @@ static void s2io_set_multicast(struct net_device *dev) /* Create the new Rx filter list and update the same in H/W. */ i = 0; netdev_for_each_mc_addr(ha, dev) { - memcpy(sp->usr_addrs[i].addr, ha->addr, - ETH_ALEN); mac_addr = 0; for (j = 0; j < ETH_ALEN; j++) { mac_addr |= ha->addr[j]; diff --git a/drivers/net/s2io.h b/drivers/net/s2io.h index 0af0335..924f618 100644 --- a/drivers/net/s2io.h +++ b/drivers/net/s2io.h @@ -816,12 +816,6 @@ struct mac_info { struct stat_block *stats_info; /* Logical address of the stat block */ }; -/* structure representing the user defined MAC addresses */ -struct usr_addr { - char addr[ETH_ALEN]; - int usage_cnt; -}; - /* Default Tunable parameters of the NIC. */ #define DEFAULT_FIFO_0_LEN 4096 #define DEFAULT_FIFO_1_7_LEN 512 @@ -894,9 +888,7 @@ struct s2io_nic { #define ALL_MULTI 2 #define MAX_ADDRS_SUPPORTED 64 - u16 usr_addr_count; u16 mc_addr_count; - struct usr_addr usr_addrs[256]; u16 m_cast_flg; u16 all_multi_pos;