linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Scott Wood <scottwood@freescale.com>
To: Jochen Friedrich <jochen@scram.de>
Cc: linux-kernel@vger.kernel.org, linuxppc-embedded@ozlabs.org
Subject: Re: [PATCH4/4] [POWERPC] Fix cpm_uart driver
Date: Mon, 24 Sep 2007 13:22:01 -0500	[thread overview]
Message-ID: <46F80049.2030509@freescale.com> (raw)
In-Reply-To: <46F7EE95.1040509@scram.de>

Jochen Friedrich wrote:
> Scott Wood schrieb:
>> Jochen Friedrich wrote:
>>>
>>> In cpm_uart_core, functions cpm_uart_init_bd and cpm_uart_init_scc
>>> an offset into DP RAM is calculated by substracting a physical
>>> memory constant from an virtual address. This patch fixes the
>>> problem by converting the virtual address into a physical
>>> first.
>>
>> Huh?  DPRAM_BASE is a virtual address.  With this patch, you'd be 
>> subtracting a virtual address from a physical address.
> 
> Thanks for pointing me to it. So the bug is in cpm_uart_cpm1.h assigning 
> a physical memory to DPRAM_BASE (at least on ARC=ppc). cpm_uart_cpm2.h 
> seems to be correct though. I'll submit a new patch for this.

cpmp is a physical address on arch/ppc?
/me looks at arch/ppc/8xx_io/commproc.c

Yikes.  Please don't change cpm_uart_cpm1.h, as it's correct for 
arch/powerpc, and there are numerous other places that assume cpmp is 
virtual (including in the very same function that assigns it a physical 
address).

You could fix arch/ppc if you want, though it may be easier to wait for 
it to die, and insist on identity maps in the meantime. :-)

-Scott

  reply	other threads:[~2007-09-24 18:22 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-23 20:17 [PATCH4/4] [POWERPC] Fix cpm_uart driver Jochen Friedrich
2007-09-24 15:57 ` Scott Wood
2007-09-24 17:06   ` Jochen Friedrich
2007-09-24 18:22     ` Scott Wood [this message]
2007-09-24 19:16       ` Dan Malek
2007-09-24 19:29         ` Scott Wood
2007-09-26 20:32           ` Rune Torgersen
2007-09-26 20:41             ` Scott Wood
2007-09-25 12:09       ` Jochen Friedrich
2007-09-25 15:11         ` Scott Wood

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=46F80049.2030509@freescale.com \
    --to=scottwood@freescale.com \
    --cc=jochen@scram.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-embedded@ozlabs.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).