Pawel Osciak | edd6e3f | 2009-11-17 08:41:19 +0100 | [diff] [blame] | 1 | /* |
Marek Szyprowski | b884c0e | 2010-05-18 12:38:43 +0200 | [diff] [blame] | 2 | * linux/arch/arm/mach-s5pc100/setup-fb-24bpp.c |
Pawel Osciak | edd6e3f | 2009-11-17 08:41:19 +0100 | [diff] [blame] | 3 | * |
| 4 | * Copyright 2009 Samsung Electronics |
| 5 | * |
Marek Szyprowski | b884c0e | 2010-05-18 12:38:43 +0200 | [diff] [blame] | 6 | * Base S5PC100 setup information for 24bpp LCD framebuffer |
Pawel Osciak | edd6e3f | 2009-11-17 08:41:19 +0100 | [diff] [blame] | 7 | * |
| 8 | * This program is free software; you can redistribute it and/or modify |
| 9 | * it under the terms of the GNU General Public License version 2 as |
| 10 | * published by the Free Software Foundation. |
| 11 | */ |
| 12 | |
| 13 | #include <linux/kernel.h> |
| 14 | #include <linux/types.h> |
| 15 | #include <linux/fb.h> |
| 16 | #include <linux/gpio.h> |
| 17 | |
| 18 | #include <mach/regs-fb.h> |
| 19 | #include <mach/map.h> |
| 20 | #include <plat/fb.h> |
| 21 | #include <plat/gpio-cfg.h> |
Pawel Osciak | edd6e3f | 2009-11-17 08:41:19 +0100 | [diff] [blame] | 22 | |
| 23 | #define DISR_OFFSET 0x7008 |
| 24 | |
| 25 | void s5pc100_fb_gpio_setup_24bpp(void) |
| 26 | { |
| 27 | unsigned int gpio = 0; |
| 28 | |
| 29 | for (gpio = S5PC100_GPF0(0); gpio <= S5PC100_GPF0(7); gpio++) { |
| 30 | s3c_gpio_cfgpin(gpio, S3C_GPIO_SFN(2)); |
| 31 | s3c_gpio_setpull(gpio, S3C_GPIO_PULL_NONE); |
| 32 | } |
| 33 | |
| 34 | for (gpio = S5PC100_GPF1(0); gpio <= S5PC100_GPF1(7); gpio++) { |
| 35 | s3c_gpio_cfgpin(gpio, S3C_GPIO_SFN(2)); |
| 36 | s3c_gpio_setpull(gpio, S3C_GPIO_PULL_NONE); |
| 37 | } |
| 38 | |
| 39 | for (gpio = S5PC100_GPF2(0); gpio <= S5PC100_GPF2(7); gpio++) { |
| 40 | s3c_gpio_cfgpin(gpio, S3C_GPIO_SFN(2)); |
| 41 | s3c_gpio_setpull(gpio, S3C_GPIO_PULL_NONE); |
| 42 | } |
| 43 | |
| 44 | for (gpio = S5PC100_GPF3(0); gpio <= S5PC100_GPF3(3); gpio++) { |
| 45 | s3c_gpio_cfgpin(gpio, S3C_GPIO_SFN(2)); |
| 46 | s3c_gpio_setpull(gpio, S3C_GPIO_PULL_NONE); |
| 47 | } |
| 48 | } |