1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
From 64d9ed38c8e6c71ffdbc4640ae38cca3dbcbe782 Mon Sep 17 00:00:00 2001
From: Carsten V. Munk <carsten.munk@gmail.com>
Date: Thu, 6 Aug 2009 09:31:09 +0000
Subject: [PATCH 05/13] backlight parameter and fixes
---
drivers/video/s3c/s3cfb.c | 14 +++++++++++++-
1 files changed, 13 insertions(+), 1 deletions(-)
diff --git a/drivers/video/s3c/s3cfb.c b/drivers/video/s3c/s3cfb.c
index 19ab25f..b854645 100644
--- a/drivers/video/s3c/s3cfb.c
+++ b/drivers/video/s3c/s3cfb.c
@@ -14,6 +14,7 @@
*/
#include <linux/module.h>
+#include <linux/moduleparam.h>
#include <linux/kernel.h>
#include <linux/errno.h>
#include <linux/string.h>
@@ -40,8 +41,10 @@
#include "s3cfb.h"
-//#define CONFIG_FB_COLORBAR 1
+/*
+#define CONFIG_FB_COLORBAR 1
#include "colorbar.c"
+*/
/*
* Globals
@@ -270,7 +273,10 @@ static int s3cfb_blank(int blank_mode, struct fb_info *info)
switch (blank_mode) {
case VESA_NO_BLANKING: /* lcd on, backlight on */
if(!backlight_power)
+ {
s3cfb_set_backlight_power(1);
+ s3cfb_set_lcd_power(1);
+ }
break;
case VESA_VSYNC_SUSPEND: /* lcd on, backlight off */
@@ -923,6 +929,10 @@ static int __init s3cfb_probe(struct platform_device *pdev)
s3cfb_set_par(&(s3c_fb_info[0].fb));
mdelay(10);
+
+ if(backlight_level != S3C_FB_MIN_BACKLIGHT_LEVEL)
+ s3cfb_set_backlight_level(backlight_level);
+
//draw_colorbar(&(s3c_fb_info[0].fb));
return 0;
@@ -1004,6 +1014,8 @@ static void __exit s3cfb_cleanup(void)
module_init(s3cfb_init);
module_exit(s3cfb_cleanup);
+module_param_named(backlight, backlight_level, int, 0);
+
MODULE_AUTHOR("Jinsung Yang");
MODULE_DESCRIPTION("S3C Framebuffer Driver");
MODULE_LICENSE("GPL");
--
1.6.2.4
|