target: msm8916: init adv7533 for all resolutions

Make default resolution as 1080p and move the initialization part to
a common place so that all the resolution are able to initialize the
dsi to hdmi bridge chip ADV7533.

Change-Id: I99a9ac14f90aa093c9cab2279df56d6efb7c90c5
diff --git a/target/msm8916/oem_panel.c b/target/msm8916/oem_panel.c
index 3d57f24..090a1b0 100644
--- a/target/msm8916/oem_panel.c
+++ b/target/msm8916/oem_panel.c
@@ -744,20 +744,8 @@
 		}
 		break;
 	case HW_PLATFORM_SBC:
-		if (platform_is_apq8016()) {
-			/* Set Switch GPIO to DSI2HDMI mode */
-			target_set_switch_gpio(1);
-			/* ADV7533 DSI to HDMI Bridge Chip Connected */
-			mipi_dsi_i2c_device_init();
-			/* Read ADV Chip ID */
-			if (!mipi_dsi_i2c_read_byte(ADV7533_MAIN, 0x00, &rev)) {
-				dprintf(INFO, "ADV7533 Rev ID: 0x%x\n",rev);
-			} else {
-				dprintf(CRITICAL, "error reading Rev ID from bridge chip\n");
-				return PANEL_TYPE_UNKNOWN;
-			}
-			panel_id = ADV7533_720P_VIDEO_PANEL;
-		}
+		if (platform_is_apq8016())
+			panel_id = ADV7533_1080P_VIDEO_PANEL;
 		break;
 	default:
 		dprintf(CRITICAL, "Display not enabled for %d HW type\n",
@@ -766,6 +754,20 @@
 	}
 
 panel_init:
+	if (platform_is_apq8016() && (hw_id == HW_PLATFORM_SBC)) {
+		/* Set Switch GPIO to DSI2HDMI mode */
+		target_set_switch_gpio(1);
+		/* ADV7533 DSI to HDMI Bridge Chip Connected */
+		mipi_dsi_i2c_device_init();
+		/* Read ADV Chip ID */
+		if (!mipi_dsi_i2c_read_byte(ADV7533_MAIN, 0x00, &rev)) {
+			dprintf(INFO, "ADV7533 Rev ID: 0x%x\n",rev);
+		} else {
+			dprintf(CRITICAL, "error reading Rev ID from bridge chip\n");
+			return PANEL_TYPE_UNKNOWN;
+		}
+	}
+
 	/*
 	 * Update all data structures after 'panel_init' label. Only panel
 	 * selection is supposed to happen before that.