Received: with ECARTIS (v1.0.0; list netdev); Wed, 13 Apr 2005 16:45:13 -0700 (PDT) Received: from ra.tuxdriver.com (ra.tuxdriver.com [24.172.12.4]) by oss.sgi.com (8.13.0/8.13.0) with ESMTP id j3DNipOZ022444 for ; Wed, 13 Apr 2005 16:44:52 -0700 Received: (from uucp@localhost) by ra.tuxdriver.com (8.11.6/8.11.6) with UUCP id j3DNWSP16333; Wed, 13 Apr 2005 19:32:28 -0400 Received: from laptop.mobile (laptop.mobile [127.0.0.1]) by laptop.mobile (8.13.1/8.13.1) with ESMTP id j3DNckf8008871; Wed, 13 Apr 2005 19:38:46 -0400 Received: (from linville@localhost) by laptop.mobile (8.13.1/8.13.1/Submit) id j3DNck7Q008870; Wed, 13 Apr 2005 19:38:46 -0400 Date: Wed, 13 Apr 2005 19:38:46 -0400 From: "John W. Linville" To: linux-kernel@vger.kernel.org, netdev@oss.sgi.com Cc: jgarzik@pobox.com, davem@davemloft.net Subject: [patch 2.6.12-rc2 9/10] tg3: check TG3_FLG2_5750_PLUS flag to set TG3_FLG2_5705_PLUS flag Message-ID: <04132005193846.8835@laptop> In-Reply-To: <04132005193845.8775@laptop> User-Agent: PatchPost/0.1 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV 0.83/825/Tue Apr 12 15:53:21 2005 on oss.sgi.com X-Virus-Status: Clean X-archive-position: 1726 X-ecartis-version: Ecartis v1.0.0 Sender: netdev-bounce@oss.sgi.com Errors-to: netdev-bounce@oss.sgi.com X-original-sender: linville@tuxdriver.com Precedence: bulk X-list: netdev Content-Length: 1193 Lines: 31 Use check of TG3_FLG2_5750_PLUS in tg3_get_invariants to set TG3_FLG2_5705_PLUS flag. Signed-off-by: John W. Linville --- drivers/net/tg3.c | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) --- bcm5752-support/drivers/net/tg3.c.orig 2005-04-08 18:13:24.632333096 -0400 +++ bcm5752-support/drivers/net/tg3.c 2005-04-08 18:13:19.559031079 -0400 @@ -7928,15 +7928,14 @@ static int __devinit tg3_get_invariants( tp->pci_hdr_type = (cacheline_sz_reg >> 16) & 0xff; tp->pci_bist = (cacheline_sz_reg >> 24) & 0xff; - if ((GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5705) || - (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5750) || - (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5752)) - tp->tg3_flags2 |= TG3_FLG2_5705_PLUS; - if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5750 || GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5752) tp->tg3_flags2 |= TG3_FLG2_5750_PLUS; + if ((GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5705) || + (tp->tg3_flags2 & TG3_FLG2_5750_PLUS)) + tp->tg3_flags2 |= TG3_FLG2_5705_PLUS; + if (tp->tg3_flags2 & TG3_FLG2_5750_PLUS) tp->tg3_flags2 |= TG3_FLG2_HW_TSO;