linux-arch.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Mike Frysinger <vapier@gentoo.org>
Cc: Russell King <linux@arm.linux.org.uk>,
	Haavard Skinnemoen <hskinnemoen@gmail.com>,
	Hans-Christian Egtvedt <egtvedt@samfundet.no>,
	Geert Uytterhoeven <geert@linux-m68k.org>,
	Ralf Baechle <ralf@linux-mips.org>,
	Paul Mundt <lethal@linux-sh.org>,
	Guan Xuetao <gxt@mprc.pku.edu.cn>,
	Grant Likely <grant.likely@secretlab.ca>,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org,
	uclinux-dist-devel@blackfin.uclinux.org,
	linux-m68k@lists.linux-m68k.org, linux-mips@linux-mips.org,
	linux-sh@vger.kernel.org, linux-arch@vger.kernel.org
Subject: Re: [PATCH] gpiolib/arches: Centralise bolierplate asm/gpio.h
Date: Wed, 26 Oct 2011 09:33:50 +0200	[thread overview]
Message-ID: <20111026073348.GB2915@opensource.wolfsonmicro.com> (raw)
Message-ID: <20111026073350.cb1SNIPxXKsquECrE2hI9xTBI8iE9bxG_EWKnicdtOo@z> (raw)
In-Reply-To: <CAJaTeTp2w85UHnmH-PPMZsQGQMNa-93kw-tjmDxA_wjJXkYQcQ@mail.gmail.com>

On Tue, Oct 25, 2011 at 07:44:14PM -0400, Mike Frysinger wrote:

> i don't think this is generally how asm-generic is handled.  instead, how about:
>  - move the duplicate code to asm-generic/gpio.h
>  - have the arches which merely need asm-generic/gpio.h add "generic-y
> += gpio.h" to their include/asm/Kbuild
>  - for arches which need to override these common funcs in some way,
> add #ifdef protection to the asm-generic/gpio.h

> and it seems like with slightly more work, this path allow you to
> merge most of arch/sh/include/asm/gpio.h.  and it has the advantage of
> not needing new Kconfig symbols.

That's really not how gpiolib is currently handled, unfortunately -
trying to transition over to that model in one patch would be way too
much.  

The goal here from that point of view is to make transitioning to
something more sensible easier by getting rid of the boilerplate code,
it makes doing the more invasive changes like you're suggesting much
easier as we're only dealing with the architectures that are actually
doing something.  It also means that we're able to immediately work on
turning on gpiolib on random architectures which is a definite win.

  parent reply	other threads:[~2011-10-26  7:34 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-25  7:33 [PATCH] gpiolib/arches: Centralise bolierplate asm/gpio.h Mark Brown
2011-10-25  7:33 ` Mark Brown
2011-10-25  8:33 ` Grant Likely
2011-10-25  8:39   ` Mark Brown
2011-10-25 23:44 ` Mike Frysinger
2011-10-25 23:44   ` Mike Frysinger
2011-10-26  7:33   ` Mark Brown [this message]
2011-10-26  7:33     ` Mark Brown
2012-02-03 23:16     ` Grant Likely
2012-02-03 23:16       ` Grant Likely
2011-10-27 13:01 ` [PATCH] asm-generic/gpio.h: merge basic gpiolib wrappers Mike Frysinger
2011-10-27 13:01   ` Mike Frysinger
2011-10-27 13:11   ` Russell King - ARM Linux
2011-10-27 13:29     ` Mike Frysinger
2011-10-27 13:43       ` Russell King - ARM Linux
2011-10-28 12:15     ` Mike Frysinger
2011-10-28 12:15       ` Mike Frysinger
2011-10-28 12:42       ` Russell King - ARM Linux
2011-10-28 13:51         ` Linus Walleij
2011-10-28 14:04           ` Mike Frysinger
2011-10-27 13:53   ` Russell King - ARM Linux
2011-10-27 22:52   ` [PATCH v2] " Mike Frysinger
2011-10-27 22:52     ` Mike Frysinger
2011-11-03  3:45   ` [PATCH v3] " Mike Frysinger
2011-11-03  3:45     ` Mike Frysinger
2012-02-04 15:54 [PATCH] gpiolib/arches: Centralise bolierplate asm/gpio.h Mark Brown
2012-02-04 15:54 ` Mark Brown
2012-02-04 17:06 ` Sam Ravnborg
2012-02-04 17:06   ` Sam Ravnborg
2012-02-04 17:21   ` Mark Brown
2012-02-04 17:21     ` Mark Brown
2012-02-04 17:41   ` Russell King - ARM Linux
2012-02-06 11:37     ` Mark Brown
2012-02-06 11:37       ` Mark Brown
2012-04-15  9:52 Mark Brown
2012-04-16  7:21 ` Linus Walleij
2012-04-16  7:21   ` Linus Walleij
2012-04-16  7:53   ` Jonas Bonn
2012-04-16  8:15   ` Mark Brown
2012-04-16  8:15     ` Mark Brown
2012-04-16  8:26     ` Linus Walleij
2012-04-16  8:26       ` Linus Walleij
2012-05-12  0:08     ` Grant Likely
2012-05-12  0:08       ` Grant Likely
2012-04-17 18:49 ` Tony Luck
2012-04-17 18:49   ` Tony Luck

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=20111026073348.GB2915@opensource.wolfsonmicro.com \
    --to=broonie@opensource.wolfsonmicro.com \
    --cc=egtvedt@samfundet.no \
    --cc=geert@linux-m68k.org \
    --cc=grant.likely@secretlab.ca \
    --cc=gxt@mprc.pku.edu.cn \
    --cc=hskinnemoen@gmail.com \
    --cc=lethal@linux-sh.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-m68k@lists.linux-m68k.org \
    --cc=linux-mips@linux-mips.org \
    --cc=linux-sh@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=ralf@linux-mips.org \
    --cc=uclinux-dist-devel@blackfin.uclinux.org \
    --cc=vapier@gentoo.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).