msm: display: add board id detection for a lvds s/w fix
If lvds is on 8064 SOC 1.0, a sw workaround that remaps pixels on lvds
lanes is needed to fix lvds phy hw timing bug.
Change-Id: I4be96f0faa7334bd400cdca3d5c81a563f2efb86
Signed-off-by: Huaibin Yang <huaibiny@codeaurora.org>
diff --git a/arch/arm/mach-msm/board-8064-display.c b/arch/arm/mach-msm/board-8064-display.c
index 62e5dda..a5376e3 100644
--- a/arch/arm/mach-msm/board-8064-display.c
+++ b/arch/arm/mach-msm/board-8064-display.c
@@ -23,6 +23,7 @@
#include <mach/gpiomux.h>
#include <mach/ion.h>
#include <mach/msm_bus_board.h>
+#include <mach/socinfo.h>
#include "devices.h"
#include "board-8064.h"
@@ -527,8 +528,21 @@
return 0;
}
+static int lvds_pixel_remap(void)
+{
+ if (machine_is_apq8064_cdp() ||
+ machine_is_apq8064_liquid()) {
+ u32 ver = socinfo_get_platform_version();
+ if ((SOCINFO_VERSION_MAJOR(ver) == 1) &&
+ (SOCINFO_VERSION_MINOR(ver) == 0))
+ return 1;
+ }
+ return 0;
+}
+
static struct lcdc_platform_data lvds_pdata = {
.lcdc_power_save = lvds_panel_power,
+ .lvds_pixel_remap = lvds_pixel_remap
};
#define LPM_CHANNEL 2