All of lore.kernel.org
 help / color / mirror / Atom feed
From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3/7] MTD: pxa3xx-nand: add devicetree bindings
Date: Thu, 26 Jul 2012 06:30:36 +0000	[thread overview]
Message-ID: <201207260630.36924.arnd@arndb.de> (raw)
In-Reply-To: <201207260259.51511.marek.vasut@gmail.com>

On Thursday 26 July 2012, Marek Vasut wrote:
> > -     r = platform_get_resource(pdev, IORESOURCE_DMA, 0);
> > -     if (r == NULL) {
> > -             dev_err(&pdev->dev, "no resource defined for data DMA\n");
> > -             ret = -ENXIO;
> > -             goto fail_put_clk;
> > -     }
> > -     info->drcmr_dat = r->start;
> > +     /*
> > +      * This is a dirty hack to make this driver work from devicetree
> > +      * bindings. It can be removed once we have a prober DMA controller
> > +      * framework for DT.
> > +      */
> > +     if (pdev->dev.of_node && cpu_is_pxa3xx()) {
> > +             info->drcmr_dat = 97;
> > +             info->drcmr_cmd = 99;
> 
> cpu_is_() stuff should begone ... besides, what are these numbers here?

They are the numbers from the DMA resource. It's ugly but I think reasonable
to do this here. We will clean it up soon, once the bindings are in place.

I did notice though the the two "info->drcmr_dat = r->start" assignments in
the non-DT case are removed here. I think that's a bug.

	Arnd

  reply	other threads:[~2012-07-26  6:30 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-25 16:17 [PATCH 0/7] Assorted PXA3xx DT patches Daniel Mack
2012-07-25 16:17 ` [PATCH 1/7] RTC: add DT bindings to pxa-rtc Daniel Mack
2012-07-25 17:18   ` Arnd Bergmann
2012-07-26 12:51   ` Sergei Shtylyov
2012-07-25 16:17 ` [PATCH 2/7] MMC: pxa-mci: add DT bindings Daniel Mack
2012-07-25 16:47   ` Chris Ball
2012-07-25 19:09     ` Daniel Mack
2012-07-25 16:17 ` [PATCH 3/7] MTD: pxa3xx-nand: add devicetree bindings Daniel Mack
2012-07-26  0:59   ` Marek Vasut
2012-07-26  6:30     ` Arnd Bergmann [this message]
2012-07-26  6:53       ` Daniel Mack
2012-07-26  6:33     ` Daniel Mack
2012-07-25 16:17 ` [PATCH 4/7] ARM: pxa: add devicetree code for irq handling Daniel Mack
2012-07-25 16:17 ` [PATCH 5/7] ARM: pxa3xx: skip default device initialization when booting via DT Daniel Mack
2012-07-25 16:17 ` [PATCH 6/7] ARM: pxa3xx: add generic DT machine code Daniel Mack
2012-07-25 17:34   ` Arnd Bergmann
2012-07-25 18:07     ` Daniel Mack
2012-07-25 19:04       ` Arnd Bergmann
2012-07-25 16:17 ` [PATCH 7/7] ARM: pxa: add .dtsi files Daniel Mack

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=201207260630.36924.arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=linux-arm-kernel@lists.infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.