[<prev] [next>] [day] [month] [year] [list]
Message-Id: <201208210834.53544.arnd.bergmann@linaro.org>
Date: Tue, 21 Aug 2012 08:34:53 +0000
From: Arnd Bergmann <arnd.bergmann@...aro.org>
To: Viresh Kumar <viresh.kumar@...aro.org>
Cc: Hein Tibosch <hein_tibosch@...oo.es>,
"Hans-Christian Egtvedt" <hans-christian.egtvedt@...el.com>,
Nicolas Ferre <nicolas.ferre@...el.com>,
Havard Skinnemoen <havard@...nnemoen.net>,
"ludovic.desroches" <ludovic.desroches@...el.com>,
linux-kernel@...r.kernel.org,
"spear-devel" <spear-devel@...t.st.com>
Subject: Re: [PATCH] Fixes for dw_dmac and atmel-mci for AP700x
On Tuesday 21 August 2012, Viresh Kumar wrote:
> On 21 August 2012 13:02, Hein Tibosch <hein_tibosch@...oo.es> wrote:
>
> > On 8/21/2012 2:35 PM, Viresh Kumar wrote:
> >
> > It got swapped as 0xAABB.CCDD => 0xCCDD.AABB
> >
>
> @Arnd: How do we explain this? shouldn't it be DD CC BB AA??
Yes, this is very strange. Maybe the compiler already splits the
access into two 16-byte loads and that confuses the device?
> > Memory barriers: within the AVR32 code, one often sees explicit ways to
> > introduce memory barriers, e.g.:
> >
> > hsmc_readl(hsmc, MODE0); /* I/O barrier */
> >
>
> For ARM it has become a bit complex about using barriers. That's why they
> are added in readl/writel to remove any confusion.
To be more exact: the reason why readl/writel have the barriers is that
device drivers written for x86 expect the barrier semantics to be implied.
ARM also has readl_relaxed/writel_relaxed, which don't have a barrier
against DMA but still enforce ordering between the readl calls (implied
by the CPU architecture).
Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists