linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Vitaly Bordug <vbordug@ru.mvista.com>
To: hs@denx.de
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: [PATCH] CPM_UART: Fixed SMC handling for CPM2 processors
Date: Tue, 13 Feb 2007 14:42:45 +0300	[thread overview]
Message-ID: <20070213144245.51de948b@localhost.localdomain> (raw)
In-Reply-To: <1171354187.5919.29.camel@Apollo>

On Tue, 13 Feb 2007 09:09:47 +0100
Heiko Schocher wrote:

> Hello Vitaly,
> 
> Vitaly Bordug wrote:
> > > I tried the Patch from Kalle Pokki
> > > http://ozlabs.org/pipermail/linuxppc-embedded/2006-November/025108.html
> > > 
> > > but my SMC didnt work, without this patch, it works fine. I think
> > > that the pram_base must be set the follwing way:
> > > 
> > Thanks for the patch, but I guess it requires a bit of
> > investigation first since we cannot just drop ioremapped offset and
> > get back to raw one that has been returned by platform_get_....
> 
> Ok, "Linux" writes/reads with the ioremapped Address in the Dualported
> RAM we get with platform_get_...("pram"), thats Okay, but the CPM
> needs the "real" Dualported RAM Address from this Area at offset
> SMCx_BASE, which we get with platform_get_...("pram_base"), so it can
> find the SMC Parameter RAM, he(CPM) didnt know anything about
> ioremapped addresses.
> 
> > We require ioremap stuff for powerpc approach, and I think we'd
> > have to figure out why ioremapped address did not satisfy smc (and
> > I'll try on my 8xx).
> 
> Hmm... you mean the following?:
> 
>   r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "pram_base");
>   if (r) {
> +           pram_base = (u32)ioremap(r->start, r->end - r->start + 1);
>             out_be16((u16 *)pram_base, base & 0xffff);
> +           iounmap(pram_base);
>          }
> 
> But thats not, what I correct with my patch, the error was, that
> we wrote the ioremapped address pram in pram_base and not the real
> address ... and with this ioremapped address, the CPM cannot do
> anything (I think).
> 

That is what I am about - I think there is a bit of confusion around the upper. I mean, we'll have to investigate
what's happening in arch/powerpc since the SMC CPM works fine for me in aprch/powerpc with the ioremap stuff. Maybe it has to do something with io_block_map() and the ioremap - I'm not sure. Well it worths looking at it, if it will be unclear we can end up with #ifdef that areas to keep ppc/ happy at least.

  reply	other threads:[~2007-02-13 11:42 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-02-12 10:33 [PATCH] CPM_UART: Fixed SMC handling for CPM2 processors Heiko Schocher
2007-02-12 17:55 ` Vitaly Bordug
2007-02-13  8:09   ` Heiko Schocher
2007-02-13 11:42     ` Vitaly Bordug [this message]
  -- strict thread matches above, loose matches on Subject: below --
2006-11-06 13:29 Kalle Pokki
2006-11-06 17:55 ` Vitaly Bordug
2006-11-06 20:49   ` Kalle Pokki
2006-11-07 12:08     ` Vitaly Bordug
2006-11-07 13:21       ` Kalle Pokki
2006-11-07 14:47         ` Vitaly Bordug

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=20070213144245.51de948b@localhost.localdomain \
    --to=vbordug@ru.mvista.com \
    --cc=hs@denx.de \
    --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).