linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: pawel.moll@arm.com (Pawel Moll)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 00/12] Versatile Express updates
Date: Wed, 12 Feb 2014 12:30:33 +0000	[thread overview]
Message-ID: <1392208233.848.48.camel@hornet> (raw)
In-Reply-To: <2782419.lfJiZZjaFg@wuerfel>

On Tue, 2014-02-11 at 19:28 +0000, Arnd Bergmann wrote:
> On Tuesday 11 February 2014 17:10:24 Pawel Moll wrote:
> > This series is a set of updates following the infrastructure
> > rework and depends on it. It will be finally posted once
> > the main series is merged. For the time being I would really
> > appreciate feedback and/or (n)acks...
> 
> I haven't read the patches yet, but on a general level, do
> you think this code can be (or should) be shared with
> mach-versatile and mach-realview?

Haven't worked with the old ones too much, I just had a look at a couple
of TRMs... The sysregs look similar, don't they? Deceitfully
similar... ;-)

Let me start from the VE side and classify the registers into functional
groups, looking at them from a MFD cells point of view:

- general ID registers like SYS_ID, SYS_MISC, SYS_PROCIDx - either not
really useful for drivers or different bitmasks if needed (eg. the
MASTERSITE bit in SYS_MISC); in other words - good candidates for syscon
if at all interesting

- de-facto GPIO registers like SYS_LED, SYS_MCI, SYS_FLASH - easily
covered via "basic-mmio-gpio" driver; can be simply exposed in the tree
as subnodes

- flags (SYS_*FLAGS*) - used pretty much only for SMP booting; that's
where, I believe, we could unify and move the DT-based operations into
plat_versatile; it is too early for the device model though, so out of
the sysreg driver scope, really (even if the code lives here for now)

- counters (SYS_100HZ, SYS_24MHZ) - the 24MHz one is used on some of the
platforms as a sched clock source; in the fourth patch of the second
series I moved it out into drivers/clocksource - it could be easily
generalised and used across more platforms, but again - it's early code,
so out of sysreg driver scope

- system configuration (SYS_CFG*) - that's the main difference between
VE and its predecessors; the older seem to provide separate system
registers to control infrastructure like clocks etc. (eg. SYS_OSC* on
the realview boards), while here we have the (whatever you call it ;-)
config bus

- other registers that are currently not used at all, but most of them
differ either in naming (and location) or in offset.

All this leads, I believe, to conclusion that they definitely deserve
different compatible values. Therefore they would also require different
mfdcells definitions. Of course we could have more than one in a single
file and pick one via matching table but:

1. There is always that little "extra" (like the master site
configuration on VE, which doesn't happen on the previous ones)

2. I'd rather not to have the non-VE stuff in arm64 kernel.

So, to summarize, I think we need separate files for at least main
families of the sysreg drivers (I didn't spent enough time on this to be
able to find commonalities and differences inside realview and versatile
families), but try to share as much as possible of the "functional"
drivers (with the sched clock and the smp operations being the most
obvious candidates).

> One of the things on my (mid-term) to-do list is to completely
> convert those two platforms over to being entirely DT based
> and having no board specific code so we can actually delete
> the directories along with mach-vexpress

And I sympathise with this goal :-) (interestingly Olof in the past
expressed strong and opposite opinion in the subject ;-)

If you have a look at the last patch of the second series, you'll find
that what's left in the VEXPRESS_DT machine are smp operations and
l2x0_of_init. Then, assuming that we finally get some answer to the CLCD
problem (latest in this subject happened here:
http://thread.gmane.org/gmane.linux.ports.arm.kernel/268037 - I really
lost all hopes for CDF getting anywhere...) removal of the non-DT code
is a matter of a single patch (and a massive negative stat :-). From
there there's only a bunch of PM-related files in arch/arm/mach-vexpress
that I guess could be moved somewhere else (that's what Olof didn't
really like).

Pawel

      reply	other threads:[~2014-02-12 12:30 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-11 17:10 [PATCH 00/12] Versatile Express updates Pawel Moll
2014-02-11 17:10 ` [PATCH 01/12] misc: vexpress-syscfg: Add udelay-based delay Pawel Moll
2014-02-15 19:19   ` Greg Kroah-Hartman
2014-02-11 17:10 ` [PATCH 02/12] power/reset: vexpress: Use udelay instead of timers Pawel Moll
2014-02-11 20:59   ` Arnd Bergmann
2014-02-12 11:56     ` Pawel Moll
2014-02-11 17:10 ` [PATCH 03/12] clk: versatile: Split config options for sp810 and vexpress_osc Pawel Moll
2014-02-11 17:10 ` [PATCH 04/12] clocksource: Sched clock source for Versatile Express Pawel Moll
2014-04-16 13:56   ` Rob Herring
2014-04-16 14:22     ` Pawel Moll
2014-04-16 14:45       ` Rob Herring
2014-04-16 15:05         ` Pawel Moll
2014-05-02 22:14   ` Linus Walleij
2014-05-07  9:57     ` Pawel Moll
2014-05-13  8:47       ` Linus Walleij
2014-02-11 17:10 ` [PATCH 05/12] GPIO: gpio-generic: Add label to platform data Pawel Moll
2014-02-11 17:17   ` Lee Jones
2014-02-11 17:20     ` Pawel Moll
2014-02-11 17:29       ` Pawel Moll
2014-02-11 17:46       ` Lee Jones
2014-02-11 17:10 ` [PATCH 06/12] mfd: vexpress-sysreg: Add labels to gpio banks Pawel Moll
2014-02-11 17:19   ` Lee Jones
2014-02-13 13:08   ` Linus Walleij
2014-02-13 13:11     ` Pawel Moll
2014-02-11 17:10 ` [PATCH 07/12] mfd: syscon: Consider platform data a regmap config name Pawel Moll
2014-02-11 17:24   ` Lee Jones
2014-02-12  7:09   ` Alexander Shiyan
2014-02-12  8:26     ` Lee Jones
2014-02-12 11:06       ` Pawel Moll
2014-02-12 11:18         ` Lee Jones
2014-02-12 11:27         ` Alexander Shiyan
2014-02-12 11:43           ` Pawel Moll
2014-02-11 17:10 ` [PATCH 08/12] mfd: vexpress-sysreg: Add syscon labels as platform data Pawel Moll
2014-02-11 17:29   ` Lee Jones
2014-02-11 17:32     ` Pawel Moll
2014-02-11 17:48       ` Lee Jones
2014-02-11 17:52         ` [PATCH v2 1/2] mfd: syscon: Add platform data with a regmap config name Pawel Moll
2014-02-11 17:52           ` [PATCH v2 2/2] mfd: vexpress-sysreg: Add syscon labels as platform data Pawel Moll
2014-02-12 11:20             ` Lee Jones
2014-02-11 17:55           ` [PATCH v2 1/2] mfd: syscon: Add platform data with a regmap config name Pawel Moll
2014-02-12 11:19           ` Lee Jones
2014-02-11 17:10 ` [PATCH 09/12] hwmon: vexpress: Use devm helper for hwmon device registration Pawel Moll
2014-02-11 20:57   ` Arnd Bergmann
2014-02-11 17:10 ` [PATCH 10/12] ARM: vexpress: remove redundant vexpress_dt_cpus_num to get cpu count Pawel Moll
2014-02-11 17:10 ` [PATCH 11/12] ARM: vexpress: Simplify SMP operations for DT-powered system Pawel Moll
2014-02-11 17:10 ` [PATCH 12/12] ARM: vexpress: move HBI check to sysreg driver Pawel Moll
2014-02-11 19:28 ` [PATCH 00/12] Versatile Express updates Arnd Bergmann
2014-02-12 12:30   ` Pawel Moll [this message]

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=1392208233.848.48.camel@hornet \
    --to=pawel.moll@arm.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).