From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3/6] arm: kconfig: don't select TWD with local timer for Armada 370/XP
Date: Mon, 21 Jan 2013 20:44:41 +0000 [thread overview]
Message-ID: <201301212044.41865.arnd@arndb.de> (raw)
In-Reply-To: <CAKGA1b=9WQNwHOz=k13XVc=MyZT1UrcaYj8muF2A5B4eJA5+MA@mail.gmail.com>
On Monday 21 January 2013, Matt Sealey wrote:
> On Mon, Jan 21, 2013 at 12:31 PM, Arnd Bergmann <arnd@arndb.de> wrote:
> > On Monday 21 January 2013, Gregory CLEMENT wrote:
> >> @@ -1624,7 +1624,7 @@ config LOCAL_TIMERS
> >> bool "Use local timer interrupts"
> >> depends on SMP
> >> default y
> >> - select HAVE_ARM_TWD if (!ARCH_MSM_SCORPIONMP && !EXYNOS4_MCT)
> >> + select HAVE_ARM_TWD if (!ARCH_MSM_SCORPIONMP && !EXYNOS4_MCT && !ARMADA_370_XP_TIMER)
> >>
> >
> > Maybe it can be written as
> >
> > config LOCAL_TIMERS
> > bool "Use local timer interrupts"
> > depends on SMP
> > default y
> >
> > config HAVE_ARM_TWD
> > depends on LOCAL_TIMERS
> > default ARCH_MULTIPLATFORM || (!ARCH_MSM_SCORPIONMP && !EXYNOS4_MCT)
> > default y
> >
> > This will still be slightly wrong (generating extra code) on a multiplatform
> > kernel that has no platform other than MSM or EXYNOS, but the other alternative
> > would be that each platform with TWD support has to select HAVE_ARM_TWD itself.
>
> Why would having each platform with TWD support select HAVE_ARM_TWD be
> a problem?
Not a big one, it's just one more Kconfig line for each of a large number
of platforms in the long run.
> On multiplatform kernels where at least one arch has TWD support, it
> will be included, and where not, it will not.
>
> It doesn't seem logical for a feature descriptor (HAVE_ARM_TWD) to
> rely on greater knowledge of what platforms may or may not support it.
> If we had to include every platform in that list it would be unwieldy.
I would expect that all future platforms have ARM_TWD, so the list
of the platforms that don't is not going to grow much, but the list
of platforms that do will keep growing.
> Which leads me to this; I wonder if there should be a policy document
> that basically describes what HAVE_* really is meant for, and how
> dependencies on ARCH_* (or MACH_* in the world of multiplatform)
> should be handled for architectural features? That way there's a
> little more fixed definition of how Kconfigs should be written to
> effectively support multiplatform kernels and allow people to identify
> misuses and get rid of them for multiplatform, if only just to get the
> information out of the heads of maintainers and into a file somewhere
> that we can reference... maybe it exists already but I am missing it?
Documentation is generally considered a good thing, but few people
can be bothered to write it, and few of the other people that should
read it actually do.
To some extent this problem will improve over time for the ARM
multiplatform support as we find all the bugs like this one
and fix them.
Arnd
WARNING: multiple messages have this Message-ID (diff)
From: Arnd Bergmann <arnd@arndb.de>
To: Matt Sealey <matt@genesi-usa.com>
Cc: Lior Amsalem <alior@marvell.com>, Andrew Lunn <andrew@lunn.ch>,
Ike Pan <ike.pan@canonical.com>,
John Stultz <johnstul@us.ibm.com>,
Grant Likely <grant.likely@secretlab.ca>,
David Marlin <dmarlin@redhat.com>,
Yehuda Yitschak <yehuday@marvell.com>,
Jani Monoses <jani.monoses@canonical.com>,
Russell King <linux@arm.linux.org.uk>,
Tawfik Bayouk <tawfik@marvell.com>,
Dan Frazier <dann.frazier@canonical.com>,
Eran Ben-Avi <benavi@marvell.com>,
Leif Lindholm <leif.lindholm@arm.com>,
Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>,
Jason Cooper <jason@lakedaemon.net>,
Nadav Haklai <nadavh@marvell.com>, Jon Masters <jcm@redhat.com>,
"devicetree-discuss@lists.ozlabs.org"
<devicetree-discuss@lists.ozlabs.org>,
Rob Herring <rob.herring@calxeda.com>,
Gregory CLEMENT <gregory.clement@free-electrons.com>,
Thomas Gleixner <tglx@linutronix.de>,
Linux ARM Kernel ML <linux-arm-k>
Subject: Re: [PATCH 3/6] arm: kconfig: don't select TWD with local timer for Armada 370/XP
Date: Mon, 21 Jan 2013 20:44:41 +0000 [thread overview]
Message-ID: <201301212044.41865.arnd@arndb.de> (raw)
In-Reply-To: <CAKGA1b=9WQNwHOz=k13XVc=MyZT1UrcaYj8muF2A5B4eJA5+MA@mail.gmail.com>
On Monday 21 January 2013, Matt Sealey wrote:
> On Mon, Jan 21, 2013 at 12:31 PM, Arnd Bergmann <arnd@arndb.de> wrote:
> > On Monday 21 January 2013, Gregory CLEMENT wrote:
> >> @@ -1624,7 +1624,7 @@ config LOCAL_TIMERS
> >> bool "Use local timer interrupts"
> >> depends on SMP
> >> default y
> >> - select HAVE_ARM_TWD if (!ARCH_MSM_SCORPIONMP && !EXYNOS4_MCT)
> >> + select HAVE_ARM_TWD if (!ARCH_MSM_SCORPIONMP && !EXYNOS4_MCT && !ARMADA_370_XP_TIMER)
> >>
> >
> > Maybe it can be written as
> >
> > config LOCAL_TIMERS
> > bool "Use local timer interrupts"
> > depends on SMP
> > default y
> >
> > config HAVE_ARM_TWD
> > depends on LOCAL_TIMERS
> > default ARCH_MULTIPLATFORM || (!ARCH_MSM_SCORPIONMP && !EXYNOS4_MCT)
> > default y
> >
> > This will still be slightly wrong (generating extra code) on a multiplatform
> > kernel that has no platform other than MSM or EXYNOS, but the other alternative
> > would be that each platform with TWD support has to select HAVE_ARM_TWD itself.
>
> Why would having each platform with TWD support select HAVE_ARM_TWD be
> a problem?
Not a big one, it's just one more Kconfig line for each of a large number
of platforms in the long run.
> On multiplatform kernels where at least one arch has TWD support, it
> will be included, and where not, it will not.
>
> It doesn't seem logical for a feature descriptor (HAVE_ARM_TWD) to
> rely on greater knowledge of what platforms may or may not support it.
> If we had to include every platform in that list it would be unwieldy.
I would expect that all future platforms have ARM_TWD, so the list
of the platforms that don't is not going to grow much, but the list
of platforms that do will keep growing.
> Which leads me to this; I wonder if there should be a policy document
> that basically describes what HAVE_* really is meant for, and how
> dependencies on ARCH_* (or MACH_* in the world of multiplatform)
> should be handled for architectural features? That way there's a
> little more fixed definition of how Kconfigs should be written to
> effectively support multiplatform kernels and allow people to identify
> misuses and get rid of them for multiplatform, if only just to get the
> information out of the heads of maintainers and into a file somewhere
> that we can reference... maybe it exists already but I am missing it?
Documentation is generally considered a good thing, but few people
can be bothered to write it, and few of the other people that should
read it actually do.
To some extent this problem will improve over time for the ARM
multiplatform support as we find all the bugs like this one
and fix them.
Arnd
next prev parent reply other threads:[~2013-01-21 20:44 UTC|newest]
Thread overview: 64+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-21 17:53 [PATCH 0/6] arm: mvebu: add support for local timer for Armada 370/XP Gregory CLEMENT
2013-01-21 17:53 ` Gregory CLEMENT
2013-01-21 17:53 ` [PATCH 1/6] arm: mvebu: Add support for local interrupt Gregory CLEMENT
2013-01-21 17:53 ` Gregory CLEMENT
2013-01-21 17:53 ` Gregory CLEMENT
2013-01-21 18:17 ` Thomas Petazzoni
2013-01-21 18:17 ` Thomas Petazzoni
2013-01-21 22:07 ` Gregory CLEMENT
2013-01-21 22:07 ` Gregory CLEMENT
2013-01-21 23:26 ` Ezequiel Garcia
2013-01-21 23:26 ` Ezequiel Garcia
2013-01-22 9:09 ` Gregory CLEMENT
2013-01-22 9:09 ` Gregory CLEMENT
2013-01-22 16:55 ` Thomas Petazzoni
2013-01-22 16:55 ` Thomas Petazzoni
2013-01-21 17:53 ` [PATCH 2/6] clocksource: time-armada-370-xp: add local timer support Gregory CLEMENT
2013-01-21 17:53 ` Gregory CLEMENT
2013-01-21 17:53 ` Gregory CLEMENT
2013-01-21 17:59 ` Russell King - ARM Linux
2013-01-21 17:59 ` Russell King - ARM Linux
2013-01-21 18:04 ` Gregory CLEMENT
2013-01-21 18:04 ` Gregory CLEMENT
2013-01-23 13:11 ` Gregory CLEMENT
2013-01-23 13:11 ` Gregory CLEMENT
2013-01-21 17:53 ` [PATCH 3/6] arm: kconfig: don't select TWD with local timer for Armada 370/XP Gregory CLEMENT
2013-01-21 17:53 ` Gregory CLEMENT
2013-01-21 18:31 ` Arnd Bergmann
2013-01-21 18:31 ` Arnd Bergmann
2013-01-21 19:29 ` Matt Sealey
2013-01-21 19:29 ` Matt Sealey
2013-01-21 20:44 ` Arnd Bergmann [this message]
2013-01-21 20:44 ` Arnd Bergmann
2013-01-22 17:12 ` Russell King - ARM Linux
2013-01-22 17:12 ` Russell King - ARM Linux
2013-01-22 20:46 ` Rob Herring
2013-01-22 20:46 ` Rob Herring
2013-01-22 20:46 ` Rob Herring
2013-01-22 21:19 ` Arnd Bergmann
2013-01-22 21:19 ` Arnd Bergmann
2013-01-22 21:19 ` Arnd Bergmann
2013-01-21 22:37 ` Gregory CLEMENT
2013-01-21 22:37 ` Gregory CLEMENT
2013-01-22 15:57 ` Arnd Bergmann
2013-01-22 15:57 ` Arnd Bergmann
2013-01-22 16:34 ` Gregory CLEMENT
2013-01-22 16:34 ` Gregory CLEMENT
2013-01-22 17:42 ` [PATCH] arm: kconfig: always select TWD with local timer for multiplatform Gregory CLEMENT
2013-01-22 17:18 ` [PATCH 3/6] arm: kconfig: don't select TWD with local timer for Armada 370/XP Russell King - ARM Linux
2013-01-22 17:18 ` Russell King - ARM Linux
2013-01-22 17:42 ` Arnd Bergmann
2013-01-22 17:42 ` Arnd Bergmann
2013-01-21 17:54 ` [PATCH 4/6] arm: mvebu: update defconfig with local timer support Gregory CLEMENT
2013-01-21 17:54 ` Gregory CLEMENT
2013-01-21 17:54 ` Gregory CLEMENT
2013-01-21 17:54 ` [PATCH 5/6] arm: mvebu: update DT to support local timers Gregory CLEMENT
2013-01-21 17:54 ` Gregory CLEMENT
2013-01-21 17:54 ` [PATCH 6/6] clocksource: update and move armada-370-xp-timer documentation to timer directory Gregory CLEMENT
2013-01-21 17:54 ` Gregory CLEMENT
2013-01-21 18:22 ` Arnd Bergmann
2013-01-21 18:22 ` Arnd Bergmann
2013-01-21 22:05 ` Gregory CLEMENT
2013-01-21 22:05 ` Gregory CLEMENT
2013-01-21 22:26 ` Arnd Bergmann
2013-01-21 22:26 ` Arnd Bergmann
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=201301212044.41865.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.