linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Nicolas Dufresne <nicolas.dufresne@collabora.com>
To: LMML <linux-media@vger.kernel.org>
Cc: s.nawrocki@samsung.com
Subject: [PATCH 5/5] s5p-fimc: Reuse calculated sizes
Date: Tue, 25 Mar 2014 16:53:32 -0400	[thread overview]
Message-ID: <1395780812.11851.20.camel@nicolas-tpx230> (raw)
In-Reply-To: <1395780301.11851.14.camel@nicolas-tpx230>

[-- Attachment #1: Type: text/plain, Size: 958 bytes --]

This formula did not take into account the required tiled alignement for
NV12MT format. As this was already computed an stored in payload array
initially, reuse that value.

Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
---
 drivers/media/platform/exynos4-is/fimc-m2m.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/platform/exynos4-is/fimc-m2m.c b/drivers/media/platform/exynos4-is/fimc-m2m.c
index 07b8f97..c648e5f 100644
--- a/drivers/media/platform/exynos4-is/fimc-m2m.c
+++ b/drivers/media/platform/exynos4-is/fimc-m2m.c
@@ -197,7 +197,7 @@ static int fimc_queue_setup(struct vb2_queue *vq, const struct v4l2_format *fmt,
 
 	*num_planes = f->fmt->memplanes;
 	for (i = 0; i < f->fmt->memplanes; i++) {
-		sizes[i] = (f->f_width * f->f_height * f->fmt->depth[i]) / 8;
+		sizes[i] = f->payload[i];
 		allocators[i] = ctx->fimc_dev->alloc_ctx;
 	}
 	return 0;
-- 
1.8.5.3



[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

  parent reply	other threads:[~2014-03-25 20:53 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-25 20:45 [PATCH 0/5] s5p-fimc: Misc fixes Nicolas Dufresne
2014-03-25 20:50 ` [PATCH 2/5] s5p-fimc: Fix YUV422P depth Nicolas Dufresne
2014-03-25 20:51 ` [PATCH 3/5] s5p-fimc: Align imagesize to row size for tiled formats Nicolas Dufresne
2014-03-26 22:38   ` Nicolas Dufresne
2014-03-26 22:48     ` [PATCH 3/5] s5p-fimc: Roundup " Nicolas Dufresne
2014-03-25 20:52 ` [PATCH 4/5] s5p-fimc: Iterate for each memory plane Nicolas Dufresne
2014-03-25 20:53 ` Nicolas Dufresne [this message]
2014-03-25 20:55 ` [PATCH 1/5] s5p-fimc: Changed RGB32 to BGR32 Nicolas Dufresne
2014-04-01 14:34   ` Sylwester Nawrocki
2014-04-01 15:16     ` Nicolas Dufresne
2014-03-25 20:56 ` [PATCH 2/5] s5p-fimc: Fix YUV422P depth Nicolas Dufresne
2014-04-01 14:13 ` [PATCH 0/5] s5p-fimc: Misc fixes Nicolas Dufresne
2014-04-01 14:28   ` Sylwester Nawrocki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1395780812.11851.20.camel@nicolas-tpx230 \
    --to=nicolas.dufresne@collabora.com \
    --cc=linux-media@vger.kernel.org \
    --cc=s.nawrocki@samsung.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).