linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: Kalra Ashish-B00888 <ashish.kalra@freescale.com>
Cc: linuxppc-dev@ozlabs.org, Li Yang-r58472 <LeoLi@freescale.com>,
	jgarzik@pobox.com, linux-ide@vger.kernel.org
Subject: Re: [PATCH v2] drivers/ata: add support to Freescale 3.0Gbps SATA Controller
Date: Mon, 15 Oct 2007 13:45:06 +0200	[thread overview]
Message-ID: <200710151345.07515.arnd@arndb.de> (raw)
In-Reply-To: <2A6F278C5B66C4459AF4013E77A40CD3FCBB59@zin33exm20.fsl.freescale.net>

On Monday 15 October 2007, Kalra Ashish-B00888 wrote:
> Thanks for your comments and feedback.
> 
> Actually, for PowerPC platforms iowrite32/ioread32 internally call
> writel/readl, which are again mapped to out_le32/in_le32,

This is correct on 6xx and e500 for now, but it's a little more
complicated than that in general:

iowriteXX/ioreadXX are either the simple readX/writeX wrappers
from arch/powerpc/kernel/iomap.c, or the more complex functions
from lib/iomap.c, depending on whether any of the active platforms
has set CONFIG_PPC_INDIRECT_IO.

writeX/readX can either map directly to out_leXX/in_leXX, or do
something more complicated, again depending on the platform.
In general, writeX/readX may need to consider PCI specific error
handling or synchronization requirements, while out_leXX/in_leXX
are low-level accessors that should only be used by device drivers
when they are used on directly connected (non-PCI) devices.

Since iowriteXX/ioreadXX is supposed to be the most generic
variant covering both PCI MMIO (writeX/readX) and PCI PIO
(outX/inX) transfers, it would make sense to extend them to
also do SOC MMIO (out_leXX/in_leXX/out_beXX/in_beXX) and
DCR (dcr_write/dcr_read) accesses in the future.

	Arnd <><

      reply	other threads:[~2007-10-15 11:45 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-12 13:47 [PATCH v2] drivers/ata: add support to Freescale 3.0Gbps SATA Controller Li Yang
2007-10-12 13:55 ` Alan Cox
2007-10-12 14:31   ` Li Yang-r58472
2007-10-12 14:36   ` Kalra Ashish-B00888
2007-10-12 14:21 ` Arnd Bergmann
2007-10-15 11:30   ` Kalra Ashish-B00888
2007-10-15 11:45     ` Arnd Bergmann [this message]

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=200710151345.07515.arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=LeoLi@freescale.com \
    --cc=ashish.kalra@freescale.com \
    --cc=jgarzik@pobox.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linuxppc-dev@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).