From: Anton Vorontsov <avorontsov@ru•mvista.com>
To: Kumar Gala <galak@kernel•crashing.org>
Cc: Scott Wood <scottwood@freescale•com>,
linuxppc-dev@ozlabs•org, Timur Tabi <timur@freescale•com>
Subject: [PATCH] powerpc/QE: use arch_initcall to probe QUICC Engine GPIOs
Date: Thu, 12 Jun 2008 03:42:14 +0400 [thread overview]
Message-ID: <20080611234214.GA5296@polina.dev.rtsoft.ru> (raw)
In-Reply-To: <CF897329-1FD6-4F3D-B91C-2C7B4225126E@kernel.crashing.org>
It was discussed that global arch_initcall() is preferred way to probe
QE GPIOs, so let's use it.
Signed-off-by: Anton Vorontsov <avorontsov@ru•mvista.com>
---
On Wed, Jun 11, 2008 at 08:52:16AM -0500, Kumar Gala wrote:
[...]
>>> applied.
>>
>> I've just rebased on the pushed out powerpc-next branch, and noticed
>> that you merged this patch from the old series.
>>
>> The difference is in absence of arch_initcall() for QE GPIOs
>> initialization, i.e. in this version boards should explicitly call
>> qe_add_gpiochips(). So.. was this done deliberately? Or should I send
>> you an update?
>
> just send me an update to my tree at this point.
Here it is.
Thanks,
arch/powerpc/sysdev/qe_lib/gpio.c | 5 ++++-
include/asm-powerpc/qe.h | 1 -
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/arch/powerpc/sysdev/qe_lib/gpio.c b/arch/powerpc/sysdev/qe_lib/gpio.c
index c712e24..8e5a0bc 100644
--- a/arch/powerpc/sysdev/qe_lib/gpio.c
+++ b/arch/powerpc/sysdev/qe_lib/gpio.c
@@ -12,6 +12,7 @@
*/
#include <linux/kernel.h>
+#include <linux/init.h>
#include <linux/spinlock.h>
#include <linux/io.h>
#include <linux/of.h>
@@ -102,7 +103,7 @@ static int qe_gpio_dir_out(struct gpio_chip *gc, unsigned int gpio, int val)
return 0;
}
-void __init qe_add_gpiochips(void)
+static int __init qe_add_gpiochips(void)
{
struct device_node *np;
@@ -143,4 +144,6 @@ err:
kfree(qe_gc);
/* try others anyway */
}
+ return 0;
}
+arch_initcall(qe_add_gpiochips);
diff --git a/include/asm-powerpc/qe.h b/include/asm-powerpc/qe.h
index 1355e72..edee15d 100644
--- a/include/asm-powerpc/qe.h
+++ b/include/asm-powerpc/qe.h
@@ -101,7 +101,6 @@ struct qe_pio_regs {
#endif
};
-extern void __init qe_add_gpiochips(void);
extern int par_io_init(struct device_node *np);
extern int par_io_of_config(struct device_node *np);
#define QE_PIO_DIR_IN 2
--
1.5.5.4
next prev parent reply other threads:[~2008-06-11 23:42 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-19 17:45 [PATCH 0/7] Patches for Kumar's powerpc-next tree Anton Vorontsov
2008-05-19 17:46 ` [PATCH 1/7] [POWERPC] sysdev: implement FSL GTM support Anton Vorontsov
2008-05-20 6:04 ` Kumar Gala
2008-05-20 12:32 ` Anton Vorontsov
2008-05-20 13:15 ` Kumar Gala
2008-05-20 14:08 ` Anton Vorontsov
2008-05-20 14:20 ` Kumar Gala
2008-05-20 14:32 ` Anton Vorontsov
2008-05-20 14:35 ` Anton Vorontsov
2008-05-20 14:24 ` Grant Likely
2008-05-20 12:41 ` Anton Vorontsov
2008-05-20 13:16 ` Kumar Gala
2008-05-20 14:38 ` Timur Tabi
2008-05-19 17:46 ` [PATCH 2/7] [POWERPC] QE: add support for QE USB clocks routing Anton Vorontsov
2008-05-20 4:04 ` Stephen Rothwell
2008-05-20 12:10 ` Anton Vorontsov
2008-05-19 17:46 ` [PATCH 3/7] [POWERPC] QE: prepare QE PIO code for GPIO LIB support Anton Vorontsov
2008-05-19 17:47 ` [PATCH 4/7] [POWERPC] QE: implement support for the GPIO LIB API Anton Vorontsov
2008-06-10 16:15 ` Kumar Gala
2008-06-11 12:29 ` Anton Vorontsov
2008-06-11 13:52 ` Kumar Gala
2008-06-11 23:42 ` Anton Vorontsov [this message]
2008-06-24 15:05 ` [PATCH] powerpc/QE: use arch_initcall to probe QUICC Engine GPIOs Kumar Gala
2008-05-19 17:47 ` [PATCH 5/7] [POWERPC] 83xx: new board support: MPC8360E-RDK Anton Vorontsov
2008-05-19 17:47 ` [PATCH 6/7] [POWERPC] booting-without-of: add FHCI USB, FSL MCU, FSL UPM and GPIO LEDs bindings Anton Vorontsov
2008-05-19 17:47 ` [PATCH 7/7] [POWERPC] qe_lib: switch to the cpm_muram implementation Anton Vorontsov
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=20080611234214.GA5296@polina.dev.rtsoft.ru \
--to=avorontsov@ru$(echo .)mvista.com \
--cc=galak@kernel$(echo .)crashing.org \
--cc=linuxppc-dev@ozlabs$(echo .)org \
--cc=scottwood@freescale$(echo .)com \
--cc=timur@freescale$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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