public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Matthew Wilcox <matthew@wil.cx>
Cc: Greg KH <greg@kroah.com>,
	linux-pci@atrey.karlin.mff.cuni.cz, linux-kernel@vger.kernel.org,
	linux-ia64@vger.kernel.org
Subject: Re: [PATCH] Introduce PCI <-> CPU address conversion [1/2]
Date: Thu, 14 Oct 2004 13:53:48 +0100	[thread overview]
Message-ID: <20041014125348.GA9633@infradead.org> (raw)
In-Reply-To: <20041014124737.GM16153@parcelfarce.linux.theplanet.co.uk>

> +#define IS_MEMORY(l)	(((l) & PCI_BASE_ADDRESS_SPACE) == \
> +				PCI_BASE_ADDRESS_SPACE_MEMORY)
> +#define IS_64BIT(l)	(((l) & PCI_BASE_ADDRESS_MEM_TYPE_64) != 0)

Should got to pci.h with more descriptive names

>  /*
> + * Convert between the CPU's view of addresses on a PCI card and the PCI
> + * device's view of the same location.  The default implementation is a no-op
> + * as most architectures have the same addresses on the CPU and PCI busses.
> + */
> +
> +#ifndef pci_phys_to_bus
> +#define pci_phys_to_bus(busdev, addr, flags) (addr)
> +#define pci_bus_to_phys(busdev, addr, flags) (addr)
> +#endif

I'd rather have this declared in every architectures asm/ header, so it's
more explicit that it's an per-arch thing.  Also make it a static inline
so we get typechecking.


  reply	other threads:[~2004-10-14 12:53 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-10-14 12:47 [PATCH] Introduce PCI <-> CPU address conversion [1/2] Matthew Wilcox
2004-10-14 12:53 ` Christoph Hellwig [this message]
2004-10-14 13:53   ` Matthew Wilcox
2004-10-14 18:00     ` Christoph Hellwig
2004-10-14 18:07       ` Matthew Wilcox
2004-10-14 22:37         ` Colin Ngam
2004-10-15  0:36           ` Matthew Wilcox
2004-10-14 14:27 ` Ivan Kokshaysky
2004-10-14 14:39   ` Matthew Wilcox
2004-10-15  7:19     ` Richard Henderson
2004-10-15 10:34       ` Ivan Kokshaysky

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=20041014125348.GA9633@infradead.org \
    --to=hch@infradead.org \
    --cc=greg@kroah.com \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@atrey.karlin.mff.cuni.cz \
    --cc=matthew@wil.cx \
    /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