summaryrefslogtreecommitdiff
path: root/arch/sh/boards/mach-migor/lcd_qvga.c
diff options
context:
space:
mode:
authorMagnus Damm <damm@igel.co.jp>2008-10-08 15:42:01 +0400
committerPaul Mundt <lethal@linux-sh.org>2008-10-20 05:34:08 +0400
commit91b6f3c5252937f85e56c71215b37024827ae924 (patch)
treec345ad0d6fb4643b37694cd4fb1f4a3cf71c57e1 /arch/sh/boards/mach-migor/lcd_qvga.c
parent8d7b5b0af7e070b9ae0852541f67aa84da078315 (diff)
downloadlinux-91b6f3c5252937f85e56c71215b37024827ae924.tar.xz
sh: Use sh7722 GPIO on Migo-R board
This patch enables the GPIO code on Migo-R and converts the code from register based pinmux configuration to GPIO based pin by pin setup. Fix whitespace damage while at it and add 2 LEDs and export them to user space. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/boards/mach-migor/lcd_qvga.c')
-rw-r--r--arch/sh/boards/mach-migor/lcd_qvga.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/sh/boards/mach-migor/lcd_qvga.c b/arch/sh/boards/mach-migor/lcd_qvga.c
index 735326c04497..c283cfc2a5c3 100644
--- a/arch/sh/boards/mach-migor/lcd_qvga.c
+++ b/arch/sh/boards/mach-migor/lcd_qvga.c
@@ -17,7 +17,9 @@
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/module.h>
+#include <linux/gpio.h>
#include <video/sh_mobile_lcdc.h>
+#include <asm/sh7722.h>
#include <asm/migor.h>
/* LCD Module is a PH240320T according to board schematics. This module
@@ -30,9 +32,9 @@
static void reset_lcd_module(void)
{
- ctrl_outb(ctrl_inb(PORT_PHDR) & ~0x04, PORT_PHDR);
+ gpio_set_value(GPIO_PTH2, 0);
mdelay(2);
- ctrl_outb(ctrl_inb(PORT_PHDR) | 0x04, PORT_PHDR);
+ gpio_set_value(GPIO_PTH2, 1);
mdelay(1);
}