All of lore.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Christoph Hellwig <hch@lst.de>
Cc: linuxppc-dev <linuxppc-dev@ozlabs.org>,
	Paul Mackerras <paulus@samba.org>
Subject: Re: [PATCH 2/5] [POWERPC] 8xx: generic 8xx code arch/powerpc port
Date: Fri, 17 Nov 2006 09:48:43 +1100	[thread overview]
Message-ID: <1163717323.5940.407.camel@localhost.localdomain> (raw)
In-Reply-To: <20061115182316.GA20719@lst.de>


> But wha do you need this for anyway?  It's not used anywhere currently,
> and it's not 8xx-specific at all?
> 
> > +unsigned long va_to_phys(unsigned long address)
> > +{
> > +	pte_t *pte;
> > +
> > +	pte = va_to_pte(address);
> > +	if (pte)
> > +		return(((unsigned long)(pte_val(*pte)) & PAGE_MASK) | (address & ~(PAGE_MASK)));
> > +	return (0);
> > +}
> 
> Shouldn't you use virt_to_phys instead?
> 
> Also for the last two I'd prefer if you'd find a way to avoid adding
> them.

I think those 2 are used for cases where they either have a non-linear
mapping a-la Amiga/APUS or in cases where they try to get addresses of
things in the vmalloc area no ?.

Ben.

  parent reply	other threads:[~2006-11-16 22:48 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20061114012504.17455.13833.stgit@localhost.localdomain>
2006-11-14  1:28 ` [PATCH 1/5] [POWERPC] 8xx: platform-specific mmu updates Vitaly Bordug
2006-11-14  1:28 ` [PATCH 2/5] [POWERPC] 8xx: generic 8xx code arch/powerpc port Vitaly Bordug
2006-11-15 18:23   ` Christoph Hellwig
2006-11-15 23:36     ` Vitaly Bordug
2006-11-16 22:48     ` Benjamin Herrenschmidt [this message]
2006-11-17  6:49       ` Christoph Hellwig
2006-11-17  8:00   ` Christoph Hellwig
2006-11-18  1:24     ` Dan Malek
2006-11-20 10:24       ` Christoph Hellwig
2006-11-21  0:26         ` Dan Malek
2006-11-14  1:28 ` [PATCH 3/5] [POWERPC] 8xx: platform-related changes to the fsl_soc.c Vitaly Bordug
2006-11-14  2:21   ` Benjamin Herrenschmidt
2006-11-14 12:48     ` Vitaly Bordug
2006-11-14  1:28 ` [PATCH 4/5] [POWERPC] 8xx: powerpc port of core CPM, CPM PIC, etc Vitaly Bordug
2006-11-14  2:44   ` Benjamin Herrenschmidt
2006-11-14  1:28 ` [PATCH 5/5] [POWERPC] 8xx: Add mpc885ads support and common mpc8xx Vitaly Bordug
2006-11-14  2:47   ` Benjamin Herrenschmidt

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=1163717323.5940.407.camel@localhost.localdomain \
    --to=benh@kernel.crashing.org \
    --cc=hch@lst.de \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=paulus@samba.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.