summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBenjamin Gaignard <benjamin.gaignard@linaro.org>2018-01-31 09:05:08 +0100
committerBenjamin Gaignard <benjamin.gaignard@linaro.org>2018-02-23 09:37:12 +0100
commit879659bb87a87a7a23b190e211d33bdd6763c746 (patch)
treec3745562ffb73f02b6e05113a1b220f4b79b8b76
parentfd9b503dec9b533afa49ac105ce65f87419b5528 (diff)
downloadlinux-879659bb87a87a7a23b190e211d33bdd6763c746.tar.bz2
drm/stm: check pitch and size calculations even if !CONFIG_MMU
In all cases we have to check pitch and size calculations to speed up data transfer. Fixes: 21f815bf773c ("drm/stm: drv: Improve data transfers") Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org> Tested-by: Philippe Cornu <philippe.cornu@st.com> Reviewed-by: Philippe Cornu <philippe.cornu@st.com> Link: https://patchwork.freedesktop.org/patch/msgid/20180131080508.14356-1-benjamin.gaignard@linaro.org
-rw-r--r--drivers/gpu/drm/stm/drv.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/gpu/drm/stm/drv.c b/drivers/gpu/drm/stm/drv.c
index 8bc7e8418b8d..9ab00a87f7cc 100644
--- a/drivers/gpu/drm/stm/drv.c
+++ b/drivers/gpu/drm/stm/drv.c
@@ -35,7 +35,6 @@ static int stm_gem_cma_dumb_create(struct drm_file *file,
struct drm_device *dev,
struct drm_mode_create_dumb *args)
{
-#ifdef CONFIG_MMU
unsigned int min_pitch = DIV_ROUND_UP(args->width * args->bpp, 8);
/*
@@ -44,7 +43,6 @@ static int stm_gem_cma_dumb_create(struct drm_file *file,
*/
args->pitch = roundup(min_pitch, 128);
args->height = roundup(args->height, 4);
-#endif
return drm_gem_cma_dumb_create_internal(file, dev, args);
}