[Armadeus-commitlog] armadeus branch, master, updated. release-3.4-213-ga76ade6
Brought to you by:
sszy
|
From: Fabien M <fa...@us...> - 2011-06-21 16:05:30
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "armadeus".
The branch, master has been updated
via a76ade6bbebb7171c5646c385f1c933cb9bb050c (commit)
via df2dd4b715bd0d9eb8136d424560531b60859398 (commit)
via 5538845c67b41bb022ac7c23102b64012b9a9ff7 (commit)
from e3fc82e13d6c3ab929efeca4dc7fab3225d4ab49 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit a76ade6bbebb7171c5646c385f1c933cb9bb050c
Merge: df2dd4b715bd0d9eb8136d424560531b60859398 e3fc82e13d6c3ab929efeca4dc7fab3225d4ab49
Author: Fabien Marteau <fab...@ar...>
Date: Tue Jun 21 18:04:57 2011 +0200
Merge branch 'master' of ssh://armadeus.git.sourceforge.net/gitroot/armadeus/armadeus
commit df2dd4b715bd0d9eb8136d424560531b60859398
Author: Fabien Marteau <fab...@ar...>
Date: Tue Jun 21 18:04:13 2011 +0200
[buildroot][package][straton_ios] Change led polarity
commit 5538845c67b41bb022ac7c23102b64012b9a9ff7
Author: Fabien Marteau <fab...@ar...>
Date: Tue Jun 21 18:03:07 2011 +0200
[linux] Set GIUS in gpio driver when direction is output
-----------------------------------------------------------------------
Summary of changes:
...rmadeus-gpio_select_dr_register_on_output.patch | 19 +++++++++++++++----
target/packages/straton_ios/straton_ios.c | 4 ++--
2 files changed, 17 insertions(+), 6 deletions(-)
diff --git a/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/409-armadeus-gpio_select_dr_register_on_output.patch b/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/409-armadeus-gpio_select_dr_register_on_output.patch
index 689d329..9b3e7dd 100644
--- a/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/409-armadeus-gpio_select_dr_register_on_output.patch
+++ b/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/409-armadeus-gpio_select_dr_register_on_output.patch
@@ -1,14 +1,18 @@
Select DR register on output direction for imx27.
+Set Gpio In USe bit on init.
Signed-off-by: Fabien Marteau <fab...@ar...>
----
---- linux-2.6.38-rc3.orig/arch/arm/plat-mxc/gpio.c 2011-02-01 04:05:49.000000000 +0100
-+++ linux-2.6.38-rc3/arch/arm/plat-mxc/gpio.c 2011-03-25 16:49:39.000000000 +0100
-@@ -40,6 +40,11 @@
+Index: linux-2.6.38.1/arch/arm/plat-mxc/gpio.c
+===================================================================
+--- linux-2.6.38.1.orig/arch/arm/plat-mxc/gpio.c 2011-03-23 21:04:47.000000000 +0100
++++ linux-2.6.38.1/arch/arm/plat-mxc/gpio.c 2011-06-21 18:01:38.000000000 +0200
+@@ -40,6 +40,12 @@
#define GPIO_IMR (cpu_is_mx1_mx2() ? 0x30 : 0x14)
#define GPIO_ISR (cpu_is_mx1_mx2() ? 0x34 : 0x18)
+#if cpu_is_mx1_mx2()
++# define GPIO_GIUS 0x20
+# define GPIO_OCR1 0x04
+# define GPIO_OCR2 0x08
+#endif
@@ -16,7 +20,7 @@ Signed-off-by: Fabien Marteau <fab...@ar...>
#define GPIO_INT_LOW_LEV (cpu_is_mx1_mx2() ? 0x3 : 0x0)
#define GPIO_INT_HIGH_LEV (cpu_is_mx1_mx2() ? 0x2 : 0x1)
#define GPIO_INT_RISE_EDGE (cpu_is_mx1_mx2() ? 0x0 : 0x2)
-@@ -289,6 +294,27 @@
+@@ -289,6 +295,34 @@
static int mxc_gpio_direction_output(struct gpio_chip *chip,
unsigned offset, int value)
{
@@ -25,11 +29,14 @@ Signed-off-by: Fabien Marteau <fab...@ar...>
+ container_of(chip, struct mxc_gpio_port, chip);
+ void __iomem *reg_ocr1 = port->base + GPIO_OCR1;
+ void __iomem *reg_ocr2 = port->base + GPIO_OCR2;
++ void __iomem *reg_gius = port->base + GPIO_GIUS;
+ u32 ocr1;
+ u32 ocr2;
++ u32 gius;
+ unsigned long flags;
+
+ spin_lock_irqsave(&port->lock, flags);
++ /* select DR mux */
+ ocr1 = __raw_readl(reg_ocr1);
+ ocr2 = __raw_readl(reg_ocr2);
+ if (offset < 16) {
@@ -39,6 +46,10 @@ Signed-off-by: Fabien Marteau <fab...@ar...>
+ ocr2 = ocr2 | (3 << ((offset-16)*2));
+ __raw_writel(ocr2, reg_ocr2);
+ }
++ /* set gpio in use */
++ gius = __raw_readl(reg_gius);
++ gius = gius | (1 << (offset));
++ __raw_writel(gius, reg_gius);
+ spin_unlock_irqrestore(&port->lock, flags);
+#endif
mxc_gpio_set(chip, offset, value);
diff --git a/target/packages/straton_ios/straton_ios.c b/target/packages/straton_ios/straton_ios.c
index 58f8e11..1373a91 100755
--- a/target/packages/straton_ios/straton_ios.c
+++ b/target/packages/straton_ios/straton_ios.c
@@ -11,9 +11,9 @@ static struct as_gpio_device *button;
/* set and get specifics functions */
void led_setvalue(long value) {
if (value = 0)
- as_gpio_set_pin_value(led, 0);
- else
as_gpio_set_pin_value(led, 1);
+ else
+ as_gpio_set_pin_value(led, 0);
return;
}
hooks/post-receive
--
armadeus
|