msm: mdss: Add scalar data structure to enable scalar programming

mdp_scale_data is a data structure added to mdp_overlay structure
to receive scalar factors for the QSEED filter such as
initial phase, phase step and pixel extension from the userland.
This data is need to achieve image clarity when using the scalar.

Signed-off-by: Sree Sesha Aravind Vadrevu <svadrevu@codeaurora.org>
Change-Id: I88e5e0cc9f4e604f38fa7c35a6a93378d3b55050

Conflicts:

	include/uapi/linux/msm_mdp.h

Signed-off-by: Pawan Kumar <pavaku@codeaurora.org>
diff --git a/include/linux/msm_mdp.h b/include/linux/msm_mdp.h
index 94b2fa4..e6b7f69 100644
--- a/include/linux/msm_mdp.h
+++ b/include/linux/msm_mdp.h
@@ -443,6 +443,33 @@
 	BLEND_OP_MAX,
 };
 
+#define MAX_PLANES	4
+struct mdp_scale_data {
+	uint8_t enable_pxl_ext;
+
+	int init_phase_x[MAX_PLANES];
+	int phase_step_x[MAX_PLANES];
+	int init_phase_y[MAX_PLANES];
+	int phase_step_y[MAX_PLANES];
+
+	int num_ext_pxls_left[MAX_PLANES];
+	int num_ext_pxls_right[MAX_PLANES];
+	int num_ext_pxls_top[MAX_PLANES];
+	int num_ext_pxls_btm[MAX_PLANES];
+
+	int left_ftch[MAX_PLANES];
+	int left_rpt[MAX_PLANES];
+	int right_ftch[MAX_PLANES];
+	int right_rpt[MAX_PLANES];
+
+	int top_rpt[MAX_PLANES];
+	int btm_rpt[MAX_PLANES];
+	int top_ftch[MAX_PLANES];
+	int btm_ftch[MAX_PLANES];
+
+	uint32_t roi_w[MAX_PLANES];
+};
+
 struct mdp_overlay {
 	struct msmfb_img src;
 	struct mdp_rect src_rect;
@@ -458,6 +485,7 @@
 	uint8_t horz_deci;
 	uint8_t vert_deci;
 	struct mdp_overlay_pp_params overlay_pp_cfg;
+	struct mdp_scale_data scale;
 };
 
 struct msmfb_overlay_3d {