public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Albert ARIBAUD <albert.u.boot@aribaud.net>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/2] drivers/net/designware, do an explicit memory access instead of implicit, re-written assignments to use readl() and writel(), all of this as preperation for making the driver able to work in a cached environment (I$D$ support).
Date: Wed, 23 Jan 2013 11:21:07 +0100	[thread overview]
Message-ID: <20130123112107.32bcb731@lilith> (raw)
In-Reply-To: <50FFB87F.3060609@st.com>

Hi Vipin,

On Wed, 23 Jan 2013 15:46:31 +0530, Vipin Kumar <vipin.kumar@st.com>
wrote:

> On 1/23/2013 12:25 PM, Albert ARIBAUD wrote:
> > Hi Vipin,
> >
> >> My first feeling is that the descriptors are allocated as Normal
> >> Cachabale memory and it would not help to access them using readl/writel
> >>
> >> Should the desciptors be allocated as non-cachable memory. If yes then
> >> how to do that in u-boot
> >>
> >> I suppose the rest of the code would be better reviewed if we know about
> >> this
> >>
> >> Vipin
> >
> > I would say that yes, descriptors are allocated in DRAM, so they are
> > cacheable.
> >
> > And no, we don't need to allocate them non-cacheable, although in this
> > case we need to use cache flush and invalidate calls. I would suggest
> > doing so rather than allocating the descriptors non cacheable, because
> > using non-cacheable memory makes the dependency between the driver and
> > cache codes implicit (and thus more prone to improperly thought out
> > changes in either code) and the memory usage more complex, while
> > explicit cache operations make the relationship explicit.
> >
> 
> Yes, got it. Thanks Albert
> 
> Frank, so in that case rather changing the code to use readl/writel, 
> cache flush and invalidate operations need to be performed at 
> appropriate places

I believe patch 2/2 adds explicit cache ops, though I haven't read it in
detail and thus don't know if everything needed is present and ok.

Amicalement,
-- 
Albert.

  reply	other threads:[~2013-01-23 10:21 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-22 14:10 [U-Boot] [PATCH 0/2] make u-boot/drivers/net/designware cache supportive Frank Dols
2013-01-22 14:10 ` [U-Boot] [PATCH 1/2] drivers/net/designware, do an explicit memory access instead of implicit, re-written assignments to use readl() and writel(), all of this as preperation for making the driver able to work in a cached environment (I$D$ support) Frank Dols
2013-01-23  5:29   ` Vipin Kumar
2013-01-23  6:55     ` Albert ARIBAUD
2013-01-23 10:16       ` Vipin Kumar
2013-01-23 10:21         ` Albert ARIBAUD [this message]
2013-01-24  9:58           ` Frank Dols
     [not found]           ` <1869199372336F41A75F0B381AC8B48A028B6B@DE02WEMBX1.internal.synopsys.com>
     [not found]             ` <511879F4.206@st.com>
2013-03-01 10:05               ` [U-Boot] FW: " Frank Dols
2013-11-22 19:03                 ` Joe Hershberger
2013-01-22 14:10 ` [U-Boot] [PATCH 2/2] u-boot/drivers/net/designware with cache support Frank Dols
2013-01-23  4:11 ` [U-Boot] [PATCH 0/2] make u-boot/drivers/net/designware cache supportive Vipin Kumar
2013-06-13 11:28   ` Joe Hershberger

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=20130123112107.32bcb731@lilith \
    --to=albert.u.boot@aribaud.net \
    --cc=u-boot@lists.denx.de \
    /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