138 lines
3.1 KiB
Diff
138 lines
3.1 KiB
Diff
diff --git a/drivers/video/omap/Kconfig b/drivers/video/omap/Kconfig
|
|
index bdeb8fb..bf256f3 100644
|
|
--- a/drivers/video/omap/Kconfig
|
|
+++ b/drivers/video/omap/Kconfig
|
|
@@ -7,6 +7,27 @@ config FB_OMAP
|
|
help
|
|
Frame buffer driver for OMAP based boards.
|
|
|
|
+choice
|
|
+ depends on FB_OMAP && MACH_OMAP3_BEAGLE
|
|
+ prompt "Screen resolution"
|
|
+ default FB_OMAP_079M3R
|
|
+ help
|
|
+ Selected desired screen resolution
|
|
+
|
|
+config FB_OMAP_031M3R
|
|
+ boolean "640 x 480 @ 60 Hz Reduced blanking"
|
|
+
|
|
+config FB_OMAP_048M3R
|
|
+ boolean "800 x 600 @ 60 Hz Reduced blanking"
|
|
+
|
|
+config FB_OMAP_079M3R
|
|
+ boolean "1024 x 768 @ 60 Hz Reduced blanking"
|
|
+
|
|
+config FB_OMAP_092M9R
|
|
+ boolean "1280 x 720 @ 60 Hz Reduced blanking"
|
|
+
|
|
+endchoice
|
|
+
|
|
config FB_OMAP_LCDC_EXTERNAL
|
|
bool "External LCD controller support"
|
|
depends on FB_OMAP
|
|
diff --git a/drivers/video/omap/lcd_omap3beagle.c b/drivers/video/omap/lcd_omap3beagle.c
|
|
index 69d4e06..5e098c2 100644
|
|
--- a/drivers/video/omap/lcd_omap3beagle.c
|
|
+++ b/drivers/video/omap/lcd_omap3beagle.c
|
|
@@ -31,10 +31,6 @@
|
|
|
|
#define LCD_PANEL_ENABLE_GPIO 170
|
|
|
|
-#define LCD_XRES 1024
|
|
-#define LCD_YRES 768
|
|
-#define LCD_PIXCLOCK 64000 /* in kHz */
|
|
-
|
|
static int omap3beagle_panel_init(struct lcd_panel *panel,
|
|
struct omapfb_device *fbdev)
|
|
{
|
|
@@ -65,19 +61,76 @@ static unsigned long omap3beagle_panel_get_caps(struct lcd_panel *panel)
|
|
struct lcd_panel omap3beagle_panel = {
|
|
.name = "omap3beagle",
|
|
.config = OMAP_LCDC_PANEL_TFT,
|
|
-
|
|
- .bpp = 24,
|
|
+ .bpp = 16,
|
|
.data_lines = 24,
|
|
- .x_res = LCD_XRES,
|
|
- .y_res = LCD_YRES,
|
|
- .hsw = 3, /* hsync_len (4) - 1 */
|
|
- .hfp = 3, /* right_margin (4) - 1 */
|
|
- .hbp = 39, /* left_margin (40) - 1 */
|
|
- .vsw = 1, /* vsync_len (2) - 1 */
|
|
- .vfp = 2, /* lower_margin */
|
|
- .vbp = 7, /* upper_margin (8) - 1 */
|
|
-
|
|
- .pixel_clock = LCD_PIXCLOCK,
|
|
+
|
|
+#if defined CONFIG_FB_OMAP_031M3R
|
|
+
|
|
+ /* 640 x 480 @ 60 Hz Reduced blanking VESA CVT 0.31M3-R */
|
|
+ .x_res = 640,
|
|
+ .y_res = 480,
|
|
+ .hfp = 48,
|
|
+ .hsw = 32,
|
|
+ .hbp = 80,
|
|
+ .vfp = 3,
|
|
+ .vsw = 4,
|
|
+ .vbp = 7,
|
|
+ .pixel_clock = 23500,
|
|
+
|
|
+#elif defined CONFIG_FB_OMAP_048M3R
|
|
+
|
|
+ /* 800 x 600 @ 60 Hz Reduced blanking VESA CVT 0.48M3-R */
|
|
+ .x_res = 800,
|
|
+ .y_res = 600,
|
|
+ .hfp = 48,
|
|
+ .hsw = 32,
|
|
+ .hbp = 80,
|
|
+ .vfp = 3,
|
|
+ .vsw = 4,
|
|
+ .vbp = 11,
|
|
+ .pixel_clock = 35500,
|
|
+
|
|
+#elif defined CONFIG_FB_OMAP_079M3R
|
|
+
|
|
+ /* 1024 x 768 @ 60 Hz Reduced blanking VESA CVT 0.79M3-R */
|
|
+ .x_res = 1024,
|
|
+ .y_res = 768,
|
|
+ .hfp = 48,
|
|
+ .hsw = 32,
|
|
+ .hbp = 80,
|
|
+ .vfp = 3,
|
|
+ .vsw = 4,
|
|
+ .vbp = 15,
|
|
+ .pixel_clock = 56000,
|
|
+
|
|
+#elif defined CONFIG_FB_OMAP_092M9R
|
|
+
|
|
+ /* 1280 x 720 @ 60 Hz Reduced blanking VESA CVT 0.92M9-R */
|
|
+ .x_res = 1280,
|
|
+ .y_res = 720,
|
|
+ .hfp = 48,
|
|
+ .hsw = 32,
|
|
+ .hbp = 80,
|
|
+ .vfp = 3,
|
|
+ .vsw = 5,
|
|
+ .vbp = 13,
|
|
+ .pixel_clock = 64000,
|
|
+
|
|
+#else
|
|
+
|
|
+ /* use 640 x 480 if no config option */
|
|
+ /* 640 x 480 @ 60 Hz Reduced blanking VESA CVT 0.31M3-R */
|
|
+ .x_res = 640,
|
|
+ .y_res = 480,
|
|
+ .hfp = 48,
|
|
+ .hsw = 32,
|
|
+ .hbp = 80,
|
|
+ .vfp = 3,
|
|
+ .vsw = 4,
|
|
+ .vbp = 7,
|
|
+ .pixel_clock = 23500,
|
|
+
|
|
+#endif
|
|
|
|
.init = omap3beagle_panel_init,
|
|
.cleanup = omap3beagle_panel_cleanup,
|
|
|