From: Ralf Baechle <ralf@linux-mips.org>
To: Christoph Hellwig <hch@infradead.org>
Cc: Atsushi Nemoto <anemo@mba.ocn.ne.jp>,
wgowcher@yahoo.com, linux-mips@linux-mips.org
Subject: Re: pci_alloc_consistent usage
Date: Tue, 27 May 2003 13:45:51 +0200 [thread overview]
Message-ID: <20030527114551.GC24905@linux-mips.org> (raw)
In-Reply-To: <20030527123329.A7750@infradead.org>
On Tue, May 27, 2003 at 12:33:29PM +0100, Christoph Hellwig wrote:
> On Tue, May 27, 2003 at 01:22:37PM +0200, Ralf Baechle wrote:
> > [...]
> > portably refer to any piece of memory. If you have a cpu pointer
> > (which may be validly DMA'd too) you may easily obtain the page
> > and offset using something like this:
> >
> > struct page *page = virt_to_page(ptr);
> > unsigned long offset = ((unsigned long)ptr & ~PAGE_MASK);
> > [...]
> >
> > While it's officially documented I still don't like it.
>
> Hmm, I remembered that some ports used vmalloc-like allocators for
> this and virt_to_page doesn't work for those..
There's at least one MIPS system which we don't support anymore but which
would have to be supported by something like this.
Whatever - virt_to_page should then be considered a a legacy API which we
have to try to support as well as possible in the hope it's going to fade
away ...
Ralf
next prev parent reply other threads:[~2003-05-27 11:45 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-05-23 21:59 pci_alloc_consistent usage Wayne Gowcher
2003-05-27 9:17 ` Ralf Baechle
2003-05-27 10:07 ` Atsushi Nemoto
2003-05-27 10:53 ` Christoph Hellwig
2003-05-27 11:22 ` Ralf Baechle
2003-05-27 11:33 ` Christoph Hellwig
2003-05-27 11:45 ` Ralf Baechle [this message]
2003-05-28 1:30 ` Atsushi Nemoto
-- strict thread matches above, loose matches on Subject: below --
2004-07-13 13:01 pci_alloc_consistent() usage Vadivelan Mani
2004-07-13 19:29 ` Ralf Baechle
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=20030527114551.GC24905@linux-mips.org \
--to=ralf@linux-mips.org \
--cc=anemo@mba.ocn.ne.jp \
--cc=hch@infradead.org \
--cc=linux-mips@linux-mips.org \
--cc=wgowcher@yahoo.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