netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "David S. Miller" <davem@davemloft.net>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: shemminger@osdl.org, jes@wildopensource.com, netdev@oss.sgi.com
Subject: Re: [PATCH] (3/4) acenic - __iomem warnings cleanup
Date: Mon, 20 Sep 2004 11:45:20 -0700	[thread overview]
Message-ID: <20040920114520.5bca1e56.davem@davemloft.net> (raw)
In-Reply-To: <414F199B.3090806@pobox.com>

On Mon, 20 Sep 2004 13:55:39 -0400
Jeff Garzik <jgarzik@pobox.com> wrote:

> Stephen Hemminger wrote:
> > Remaining warnings are because tx_ring can be either in i/o or not
> > depending on the version of the card.
> 
> Where is this code?  I don't see any {in,out}[bwl] calls?
> 
> If this were true, we should use io{read,write}{8,16,32}...

The driver uses a single pointer that either goes to DMA descriptors
or I/O memory space.

See the assignment and usage of ap->tx_ring

	if (!ACE_IS_TIGON_I(ap)) {
		size = (sizeof(struct tx_desc) * MAX_TX_RING_ENTRIES);

		ap->tx_ring = pci_alloc_consistent(ap->pdev, size,
						   &ap->tx_ring_dma);

		if (ap->tx_ring == NULL)
			goto fail;
	}
 ...

	if (ACE_IS_TIGON_I(ap)) {
		ap->tx_ring = (struct tx_desc *)regs->Window;
		for (i = 0; i < (TIGON_I_TX_RING_ENTRIES * 
				 sizeof(struct tx_desc) / 4); i++) {
			writel(0, (unsigned long)ap->tx_ring + i * 4);
		}

		set_aceaddr(&info->tx_ctrl.rngptr, TX_RING_BASE);
	} else {
		memset(ap->tx_ring, 0,
		       MAX_TX_RING_ENTRIES * sizeof(struct tx_desc));

		set_aceaddr(&info->tx_ctrl.rngptr, ap->tx_ring_dma);
	}

      parent reply	other threads:[~2004-09-20 18:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-20 17:44 [PATCH] (3/4) acenic - __iomem warnings cleanup Stephen Hemminger
2004-09-20 17:55 ` Jeff Garzik
2004-09-20 18:32   ` Stephen Hemminger
2004-09-20 18:45   ` David S. Miller [this message]

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=20040920114520.5bca1e56.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=jes@wildopensource.com \
    --cc=jgarzik@pobox.com \
    --cc=netdev@oss.sgi.com \
    --cc=shemminger@osdl.org \
    /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).