devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: Tomasz Figa <t.figa@samsung.com>,
	Grant Likely <grant.likely@secretlab.ca>,
	linux-arm-kernel@lists.infradead.org,
	linux-samsung-soc@vger.kernel.org,
	devicetree-discuss@lists.ozlabs.org, kgene.kim@samsung.com,
	thomas.abraham@linaro.org, kyungmin.park@samsung.com,
	m.szyprowski@samsung.com, tomasz.figa@gmail.com
Subject: Re: [PATCH 01/16] ARM: dts: exynos4210: Replace legacy GPIO bank nodes with pinctrl bank nodes
Date: Wed, 10 Oct 2012 10:27:27 -0600	[thread overview]
Message-ID: <5075A1EF.60900@wwwdotorg.org> (raw)
In-Reply-To: <CACRpkdZgH9TSr2uWQW+-8-U7BxJCscQgStVOndGixGmRz74TWw@mail.gmail.com>

On 10/10/2012 01:26 AM, Linus Walleij wrote:
> On Mon, Oct 8, 2012 at 10:39 AM, Tomasz Figa <t.figa@samsung.com> wrote:
> 
>> Seuqential patches from this series introduce SoC-specific data parsing
>> from device tree.
>>
>> This patch removes legacy GPIO bank nodes from exynos4210.dtsi and
>> replaces them with nodes and properties required for these patches.
> 
> So to be clear:
> 
>> +       pinctrl-bank-types {
>> +               bank_off: bank-off {
>> +                       samsung,reg-names = "func", "dat", "pud",
>> +                                               "drv", "conpdn", "pudpdn";
>> +                       samsung,reg-params = <0x00 4>, <0x04 1>, <0x08 2>,
>> +                                               <0x0C 2>, <0x10 2>, <0x14 2>;
>> +               };
> 
> This is starting to look like a firmware language, I have mixed
> feelings about this. Shall this be read:
> 
> "Poke 4 into 0x00, poke 1 into 0x04, poke 2 into 0x08" etc?
> 
> We really need to discuss this, Grant has already NACK:ed
> such approaches once.

Well, I don't think he NACK'd Tony Lindgren's generic pinctrl driver,
which is doing this exact same thing. I did raise the same point about
Tony's driver when he posted it, but nobody seemed inclined to NACK it
based on that at the time, IIRC...

BTW, the idea here is IIRC to create a generic Samsung pinctrl driver
that works across N different Samsung SoCs, each with different register
layout, without having to encode the register layout into tables in the
kernel.

> If you're still going to do this, it is mandatory
> to NOT use magic hex numbers anymore, because Stephen has
> merged preprocessor support to the DTC compiler so you
> can use #defined macros.
> 
> See commit:
> cd296721a9645f9f28800a072490fa15458d1fb7

That feature isn't enabled yet. While dtc has been modified to be able
to accept input that's been generated/processed by cpp, there is still
ongoing discussion about how/whether to actually enable *.dts to use
that feature.

  parent reply	other threads:[~2012-10-10 16:27 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-08  8:39 [PATCH 00/16] pinctrl: samsung: Usability and extensibiltiy improvements Tomasz Figa
2012-10-08  8:39 ` [PATCH 01/16] ARM: dts: exynos4210: Replace legacy GPIO bank nodes with pinctrl bank nodes Tomasz Figa
2012-10-10  7:26   ` Linus Walleij
2012-10-10  8:20     ` Tomasz Figa
2012-10-10 16:27     ` Stephen Warren [this message]
2012-10-10 18:12       ` Tony Lindgren
2012-10-10 18:22         ` Tomasz Figa
2012-10-10 18:26         ` Tomasz Figa
2012-10-08  8:39 ` [PATCH 02/16] pinctrl: exynos: Parse wakeup-eint parameters from DT Tomasz Figa
2012-10-10  7:18   ` Linus Walleij
2012-10-10  8:23     ` Tomasz Figa
2012-10-08  8:39 ` [PATCH 03/16] pinctrl: samsung: Detect and handle unsupported configuration types Tomasz Figa
2012-10-10  7:37   ` Linus Walleij
2012-10-10  8:25     ` Tomasz Figa
2012-10-08  8:39 ` [PATCH 04/16] pinctrl: samsung: Parse pin banks from DT Tomasz Figa
2012-10-10  7:34   ` Linus Walleij
2012-10-10  8:39     ` Tomasz Figa
2012-10-11 13:52       ` Linus Walleij
2012-10-08  8:39 ` [PATCH 05/16] pinctrl: exynos: Remove static SoC-specific data Tomasz Figa
2012-10-08  8:39 ` [PATCH 06/16] pinctrl: samsung: Parse bank-specific eint offset from DT Tomasz Figa
2012-10-08  8:39 ` [PATCH 07/16] pinctrl: samsung: Hold OF node of pin bank in bank struct Tomasz Figa
2012-10-08  8:39 ` [PATCH 08/16] pinctrl: samsung: Hold pointer to driver data " Tomasz Figa
2012-10-08  8:39 ` [PATCH 09/16] pinctrl: exynos: Use one IRQ domain per pin bank Tomasz Figa
2012-10-10  7:40   ` Linus Walleij
2012-10-10  8:45     ` Tomasz Figa
2012-10-08  8:39 ` [PATCH 10/16] pinctrl: samsung: Do not pass gpio_chip to pin_to_reg_bank Tomasz Figa
2012-10-10  7:42   ` Linus Walleij
2012-10-10  8:51     ` Tomasz Figa
2012-10-08  8:39 ` [PATCH 11/16] pinctrl: samsung: Use one GPIO chip per pin bank Tomasz Figa
2012-10-10  7:43   ` Linus Walleij
2012-10-10  8:49     ` Tomasz Figa
2012-10-08  8:39 ` [PATCH 12/16] pinctrl: samsung: Use per-bank IRQ domain for wake-up interrupts Tomasz Figa
2012-10-08  8:39 ` [PATCH 13/16] pinctrl: exynos: Set pin function to EINT in irq_set_type of wake-up EINT Tomasz Figa
2012-10-08  8:39 ` [PATCH 14/16] pinctrl: samsung: Parse offsets of particular registers from DT Tomasz Figa
2012-10-08  8:39 ` [PATCH 15/16] pinctrl: samsung: Add GPIO to IRQ translation Tomasz Figa
2012-10-08  8:39 ` [PATCH 16/16] Documentation: Update samsung-pinctrl device tree bindings documentation Tomasz Figa
2012-10-10  7:46 ` [PATCH 00/16] pinctrl: samsung: Usability and extensibiltiy improvements Linus Walleij
     [not found]   ` <CACRpkdbUmM2=vhjhCq_qN2v=8RUDeWV4b8A8oXXPE4e8Z9C7zg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-10-10  9:04     ` Tomasz Figa
2012-10-10 15:22   ` Tomasz Figa
2012-10-11 13:48     ` Linus Walleij

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=5075A1EF.60900@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=grant.likely@secretlab.ca \
    --cc=kgene.kim@samsung.com \
    --cc=kyungmin.park@samsung.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=m.szyprowski@samsung.com \
    --cc=t.figa@samsung.com \
    --cc=thomas.abraham@linaro.org \
    --cc=tomasz.figa@gmail.com \
    /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).