From patchwork Mon Jul 5 15:07:15 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julia Lawall X-Patchwork-Id: 57916 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 4CED81007D3 for ; Tue, 6 Jul 2010 01:07:52 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758197Ab0GEPHT (ORCPT ); Mon, 5 Jul 2010 11:07:19 -0400 Received: from mgw2.diku.dk ([130.225.96.92]:49030 "EHLO mgw2.diku.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752951Ab0GEPHS (ORCPT ); Mon, 5 Jul 2010 11:07:18 -0400 Received: from localhost (localhost [127.0.0.1]) by mgw2.diku.dk (Postfix) with ESMTP id A846919BB72; Mon, 5 Jul 2010 17:07:16 +0200 (CEST) Received: from mgw2.diku.dk ([127.0.0.1]) by localhost (mgw2.diku.dk [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 01500-08; Mon, 5 Jul 2010 17:07:15 +0200 (CEST) Received: from nhugin.diku.dk (nhugin.diku.dk [130.225.96.140]) by mgw2.diku.dk (Postfix) with ESMTP id B96CB19BB6B; Mon, 5 Jul 2010 17:07:15 +0200 (CEST) Received: from ask.diku.dk (ask.diku.dk [130.225.96.225]) by nhugin.diku.dk (Postfix) with ESMTP id B4A1B6DF845; Mon, 5 Jul 2010 17:06:55 +0200 (CEST) Received: by ask.diku.dk (Postfix, from userid 3767) id 9CE0E200C0; Mon, 5 Jul 2010 17:07:15 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by ask.diku.dk (Postfix) with ESMTP id 8F668200BB; Mon, 5 Jul 2010 17:07:15 +0200 (CEST) Date: Mon, 5 Jul 2010 17:07:15 +0200 (CEST) From: Julia Lawall To: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [PATCH] drivers/net: correct valid flag Message-ID: MIME-Version: 1.0 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Julia Lawall Elsewhere in the "optimized" functions, the "2" constants are used. NV_TX_VALID and NV_TX2_VALID have the same value. Signed-off-by: Julia Lawall --- -- 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/drivers/net/forcedeth.c b/drivers/net/forcedeth.c index 268ea4d..870c18b 100644 --- a/drivers/net/forcedeth.c +++ b/drivers/net/forcedeth.c @@ -2468,7 +2468,8 @@ static int nv_tx_done_optimized(struct net_device *dev, int limit) struct ring_desc_ex* orig_get_tx = np->get_tx.ex; while ((np->get_tx.ex != np->put_tx.ex) && - !((flags = le32_to_cpu(np->get_tx.ex->flaglen)) & NV_TX_VALID) && + !((flags = le32_to_cpu(np->get_tx.ex->flaglen)) & NV_TX2_VALID) + && (tx_work < limit)) { dprintk(KERN_DEBUG "%s: nv_tx_done_optimized: flags 0x%x.\n",