linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: sebastian.hesselbarth@gmail.com (Sebastian Hesselbarth)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 0/7] ARM: berlin: add pinctrl support
Date: Thu, 24 Apr 2014 15:23:29 +0200	[thread overview]
Message-ID: <53591051.9030804@gmail.com> (raw)
In-Reply-To: <CACRpkdbT94HqVroM_0gSJJ8Q2+YaKXLwjFGMn+4SCa_PYiF19Q@mail.gmail.com>

On 04/24/2014 02:52 PM, Linus Walleij wrote:
> On Wed, Apr 23, 2014 at 5:51 PM, Antoine T?nart
> <antoine.tenart@free-electrons.com> wrote:
>
>> This series adds support for the Marvell Berlin pin-controller, allowing
>> to configure the pin muxing from the device tree.
>>
>> The Berlin pin-controller support is divided into 3 drivers, each
>> driving one Berlin SoC. These drivers use a Berlin common part.
>>
>> This series applies on top of patches introducing the Marvell Berlin
>> BG2Q you can find on Sebastian's berlin/for-next branch[1] and the patch
>> allowing not to define the get_group_pins() function[2].
>>
>> Tested on the Berlin BG2Q.
>
> So now I need some advice from the mvebu pinctrl maintainers
> (Thomas, Sebastian etc):
>
> - Is this a totally different pin controller so that drivers/pinctrl/mvebu
>   can not be used?

Unfortunately, yes. Well actually, it _can_ be seen as a subset of
the mvebu pinctrl:

- mvebu (usually) uses 4bit per mux function with 8 functions/register
- berlin uses 1-4bit per mux function with as many functions/register
   as there fit in 32b.

This great feature saves _at least_ one additional address decoding!
It doesn't save registers, because they will never be synthesized, but
at least each SoC has a very different pinmux layout. *sigh*

> - Really?

Yep.

> - OK can you help me review this thing?

Sure thing!

> - Should the base folder really be named "berlin" or is this going to
>    be part of a bigger family of pin controllers so a more neutral name
>    should be sought?

Well, Marvell basically has two groups of SoCs, MVEBU and PXA/MMP. Don't
ask me why but sometimes they share IP, sometimes they don't.

Berlin names Marvell SoCs prefixed 88DExxxx, I *think* it may be derived 
from the PXA/MMP line of SoCs. To make it more confuse,
it also got the marketing name "Armada".

> - Why do hardware engineers seek to reinvent wheels like pin
>    controllers, GPIO and DMA engines all the time :-/

I guess it is: "Look what we found in our IP archives".

Honestly, I can think of making pinctrl/mvebu and pinctrl/berlin
compatible but I don't know if it is worth the pain :P

We have "custom" set/get_function() callbacks in pinctrl/mvebu
so that should fit. Each "group" of pins has a name and a bunch
of "functions", that fits too.

I need some time to think about it, but if you insist on it, I
can possibly make it work.

Sebastian

  parent reply	other threads:[~2014-04-24 13:23 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-23 15:51 [PATCH v2 0/7] ARM: berlin: add pinctrl support Antoine Ténart
2014-04-23 15:51 ` [PATCH v2 1/7] pinctrl: berlin: add the core pinctrl driver for Marvell Berlin SoCs Antoine Ténart
2014-04-26  9:17   ` Sebastian Hesselbarth
2014-04-28 17:06     ` Antoine Ténart
2014-04-23 15:51 ` [PATCH v2 2/7] pinctrl: berlin: add the BG2Q pinctrl driver Antoine Ténart
2014-04-26  9:29   ` Sebastian Hesselbarth
2014-04-28 17:03     ` Antoine Ténart
2014-04-23 15:51 ` [PATCH v2 3/7] pinctrl: berlin: add the BG2 " Antoine Ténart
2014-04-26  9:33   ` Sebastian Hesselbarth
2014-04-23 15:51 ` [PATCH v2 4/7] pinctrl: berlin: add the BG2CD " Antoine Ténart
2014-04-26  9:40   ` Sebastian Hesselbarth
2014-04-23 15:51 ` [PATCH v2 5/7] ARM: berlin: add the pinctrl dependency for the Marvell Berlin SoCs Antoine Ténart
2014-04-23 15:51 ` [PATCH v2 6/7] Documentation: add the Marvell Berlin pinctrl documentation Antoine Ténart
2014-04-26  9:44   ` Sebastian Hesselbarth
2014-04-28 17:05     ` Antoine Ténart
2014-04-23 15:51 ` [PATCH v2 7/7] ARM: dts: berlin: add the pinctrl node and muxing setup for uarts Antoine Ténart
2014-04-26  9:51   ` Sebastian Hesselbarth
2014-04-24 12:52 ` [PATCH v2 0/7] ARM: berlin: add pinctrl support Linus Walleij
2014-04-24 13:08   ` Russell King - ARM Linux
2014-04-24 13:23   ` Sebastian Hesselbarth [this message]
2014-04-24 13:26   ` Thomas Petazzoni
2014-04-25  9:13 ` Linus Walleij
2014-04-26  9:53   ` Sebastian Hesselbarth

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=53591051.9030804@gmail.com \
    --to=sebastian.hesselbarth@gmail.com \
    --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 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).