netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Michael Chan" <mchan@broadcom.com>
To: "David S. Miller" <davem@davemloft.net>
Cc: "Arthur Kepner" <akepner@sgi.com>, netdev@oss.sgi.com
Subject: [PATCH 2.6.12-rc2 2/3] tg3: Refresh hw index in tg3_rx()
Date: Mon, 25 Apr 2005 14:09:11 -0700	[thread overview]
Message-ID: <1114463351.4917.39.camel@rh4> (raw)
In-Reply-To: <1114463061.4917.34.camel@rh4>

This patch refreshes the hw rx producer in tg3_rx() so that additional
work posted by the hardware can be processed.

Signed-off-by: Michael Chan <mchan@broadcom.com>

diff -Nru c/drivers/net/tg3.c d/drivers/net/tg3.c
--- c/drivers/net/tg3.c	2005-04-25 12:32:44.000000000 -0700
+++ d/drivers/net/tg3.c	2005-04-25 12:39:46.000000000 -0700
@@ -2802,6 +2802,12 @@
 next_pkt_nopost:
 		sw_idx++;
 		sw_idx %= TG3_RX_RCB_RING_SIZE(tp);
+
+		/* Refresh hw_idx to see if there is new work */
+		if (sw_idx == hw_idx) {
+			hw_idx = tp->hw_status->idx[0].rx_producer;
+			rmb();
+		}
 	}
 
 	/* ACK the status ring. */

       reply	other threads:[~2005-04-25 21:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1114463061.4917.34.camel@rh4>
2005-04-25 21:09 ` Michael Chan [this message]
     [not found]   ` <1114464194.4917.52.camel@rh4>
     [not found]     ` <20050425151816.1910b2ba.davem@davemloft.net>
2005-04-25 21:56       ` [PATCH 2.6.12-rc2 3/3] tg3: Fix tg3_restart_ints() Michael Chan
     [not found]         ` <20050425162416.2b4edd43.davem@davemloft.net>
     [not found]           ` <1114470490.4917.85.camel@rh4>
2005-05-05 23:05             ` David S. Miller
2005-05-05 22:51               ` Michael Chan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1114463351.4917.39.camel@rh4 \
    --to=mchan@broadcom.com \
    --cc=akepner@sgi.com \
    --cc=davem@davemloft.net \
    --cc=netdev@oss.sgi.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).