diff options
| author | Linux Build Service Account <lnxbuild@quicinc.com> | 2017-11-19 07:45:13 -0800 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2017-11-19 07:45:13 -0800 |
| commit | d7ad9cc3e5e9fe67cef592c93cb9a4a0600db6b2 (patch) | |
| tree | fe24b7e8463c249e3bac561dc81c343a43f3cdc4 | |
| parent | 72c7a91cb3e5009788bda00a6fd72396fd7fd44c (diff) | |
| parent | 9b0c877cd12412f2d04d5ebd46bc49e7acd6ce97 (diff) | |
Merge "msm: mdss: adjust mdss_mdp_get_plane_sizes parameters init order"
| -rw-r--r-- | drivers/video/fbdev/msm/mdss_mdp_util.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/video/fbdev/msm/mdss_mdp_util.c b/drivers/video/fbdev/msm/mdss_mdp_util.c index 1ae3d0ba4ec6..6015ed20fe56 100644 --- a/drivers/video/fbdev/msm/mdss_mdp_util.c +++ b/drivers/video/fbdev/msm/mdss_mdp_util.c @@ -524,11 +524,12 @@ int mdss_mdp_get_plane_sizes(struct mdss_mdp_format_params *fmt, u32 w, u32 h, if (ps == NULL) return -EINVAL; + memset(ps, 0, sizeof(struct mdss_mdp_plane_sizes)); + if ((w > MAX_IMG_WIDTH) || (h > MAX_IMG_HEIGHT)) return -ERANGE; bpp = fmt->bpp; - memset(ps, 0, sizeof(struct mdss_mdp_plane_sizes)); if (mdss_mdp_is_ubwc_format(fmt)) { rc = mdss_mdp_get_ubwc_plane_size(fmt, w, h, ps); |
