| Bryan Huntsman | 3f2bc4d | 2011-08-16 17:27:22 -0700 | [diff] [blame] | 1 | /* Copyright (c) 2009-2010, Code Aurora Forum. All rights reserved. |
| 2 | * |
| 3 | * This program is free software; you can redistribute it and/or modify |
| 4 | * it under the terms of the GNU General Public License version 2 and |
| 5 | * only version 2 as published by the Free Software Foundation. |
| 6 | * |
| 7 | * This program is distributed in the hope that it will be useful, |
| 8 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 10 | * GNU General Public License for more details. |
| 11 | * |
| 12 | */ |
| 13 | |
| 14 | #include "msm_fb.h" |
| 15 | |
| 16 | static int __init lcdc_wxga_init(void) |
| 17 | { |
| 18 | int ret; |
| 19 | struct msm_panel_info pinfo; |
| 20 | |
| 21 | #ifdef CONFIG_FB_MSM_MDDI_AUTO_DETECT |
| 22 | if (msm_fb_detect_client("lcdc_wxga")) |
| 23 | return 0; |
| 24 | #endif |
| 25 | |
| 26 | pinfo.xres = 1280; |
| 27 | pinfo.yres = 720; |
| 28 | MSM_FB_SINGLE_MODE_PANEL(&pinfo); |
| 29 | pinfo.type = LCDC_PANEL; |
| 30 | pinfo.pdest = DISPLAY_1; |
| 31 | pinfo.wait_cycle = 0; |
| 32 | pinfo.bpp = 24; |
| 33 | pinfo.fb_num = 2; |
| 34 | pinfo.clk_rate = 74250000; |
| 35 | |
| 36 | pinfo.lcdc.h_back_porch = 124; |
| 37 | pinfo.lcdc.h_front_porch = 110; |
| 38 | pinfo.lcdc.h_pulse_width = 136; |
| 39 | pinfo.lcdc.v_back_porch = 19; |
| 40 | pinfo.lcdc.v_front_porch = 5; |
| 41 | pinfo.lcdc.v_pulse_width = 6; |
| 42 | pinfo.lcdc.border_clr = 0; /* blk */ |
| 43 | pinfo.lcdc.underflow_clr = 0xff; /* blue */ |
| 44 | pinfo.lcdc.hsync_skew = 0; |
| 45 | |
| 46 | ret = lcdc_device_register(&pinfo); |
| 47 | if (ret) |
| 48 | printk(KERN_ERR "%s: failed to register device!\n", __func__); |
| 49 | |
| 50 | return ret; |
| 51 | } |
| 52 | |
| 53 | module_init(lcdc_wxga_init); |