summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Chen <b02280@freescale.com>2011-03-28 13:26:16 +0800
committerJason Chen <b02280@freescale.com>2011-03-28 13:28:33 +0800
commit155aa684d64070ad2a3599547bb3eac3c23f598f (patch)
treed27a71941145c6b6488f9da7bbad5fffbeb32688
parenta93506107d4638455283ea472235496c37560eae (diff)
ENGR00141152-5 sii902x: make default display option
sii902x driver change. Signed-off-by: Jason Chen <b02280@freescale.com>
-rw-r--r--drivers/video/mxc/mxcfb_sii902x.c21
1 files changed, 17 insertions, 4 deletions
diff --git a/drivers/video/mxc/mxcfb_sii902x.c b/drivers/video/mxc/mxcfb_sii902x.c
index ab143a62133e..a1c748e63cfd 100644
--- a/drivers/video/mxc/mxcfb_sii902x.c
+++ b/drivers/video/mxc/mxcfb_sii902x.c
@@ -52,7 +52,9 @@
#define IPU_DISP_PORT 0
#define SII_EDID_LEN 256
-static bool g_enable_hdmi;
+#define MXC_ENABLE 1
+#define MXC_DISABLE 2
+static int g_enable_hdmi;
struct sii902x_data {
struct platform_device *pdev;
@@ -324,8 +326,16 @@ static int __devinit sii902x_probe(struct i2c_client *client,
struct mxc_lcd_platform_data *plat = client->dev.platform_data;
struct fb_info edid_fbi;
- if (g_enable_hdmi == false)
- return -EPERM;
+ if (plat->boot_enable &&
+ !g_enable_hdmi)
+ g_enable_hdmi = MXC_ENABLE;
+ if (!g_enable_hdmi)
+ g_enable_hdmi = MXC_DISABLE;
+
+ if (g_enable_hdmi == MXC_DISABLE) {
+ printk(KERN_WARNING "By setting, SII driver will not be enabled\n");
+ return 0;
+ }
sii902x.client = client;
@@ -497,7 +507,10 @@ static void __exit sii902x_exit(void)
static int __init enable_hdmi_setup(char *options)
{
- g_enable_hdmi = true;
+ if (!strcmp(options, "=off"))
+ g_enable_hdmi = MXC_DISABLE;
+ else
+ g_enable_hdmi = MXC_ENABLE;
return 1;
}