From: Andrzej Pietrasiewicz <andrzej.p@samsung.com>
To: Thierry Escande <thierry.escande@collabora.com>,
Jacek Anaszewski <jacek.anaszewski@gmail.com>,
Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 2/8] [media] s5p-jpeg: Correct WARN_ON statement for checking subsampling
Date: Thu, 29 Jun 2017 14:03:44 +0200 [thread overview]
Message-ID: <22da9d2c-a56b-9d57-33a6-79eb42923041@samsung.com> (raw)
In-Reply-To: <1498579734-1594-3-git-send-email-thierry.escande@collabora.com>
W dniu 27.06.2017 o 18:08, Thierry Escande pisze:
> From: Tony K Nadackal <tony.kn@samsung.com>
>
> Corrects the WARN_ON statement for subsampling based on the
> JPEG Hardware version.
>
> Signed-off-by: Tony K Nadackal <tony.kn@samsung.com>
> Signed-off-by: Thierry Escande <thierry.escande@collabora.com>
Acked-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com>
> ---
> drivers/media/platform/s5p-jpeg/jpeg-core.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/media/platform/s5p-jpeg/jpeg-core.c b/drivers/media/platform/s5p-jpeg/jpeg-core.c
> index 623508d..0d935f5 100644
> --- a/drivers/media/platform/s5p-jpeg/jpeg-core.c
> +++ b/drivers/media/platform/s5p-jpeg/jpeg-core.c
> @@ -614,24 +614,26 @@ static inline struct s5p_jpeg_ctx *fh_to_ctx(struct v4l2_fh *fh)
>
> static int s5p_jpeg_to_user_subsampling(struct s5p_jpeg_ctx *ctx)
> {
> - WARN_ON(ctx->subsampling > 3);
> -
> switch (ctx->jpeg->variant->version) {
> case SJPEG_S5P:
> + WARN_ON(ctx->subsampling > 3);
> if (ctx->subsampling > 2)
> return V4L2_JPEG_CHROMA_SUBSAMPLING_GRAY;
> return ctx->subsampling;
> case SJPEG_EXYNOS3250:
> case SJPEG_EXYNOS5420:
> + WARN_ON(ctx->subsampling > 6);
> if (ctx->subsampling > 3)
> return V4L2_JPEG_CHROMA_SUBSAMPLING_411;
> return exynos3250_decoded_subsampling[ctx->subsampling];
> case SJPEG_EXYNOS4:
> case SJPEG_EXYNOS5433:
> + WARN_ON(ctx->subsampling > 3);
> if (ctx->subsampling > 2)
> return V4L2_JPEG_CHROMA_SUBSAMPLING_420;
> return exynos4x12_decoded_subsampling[ctx->subsampling];
> default:
> + WARN_ON(ctx->subsampling > 3);
> return V4L2_JPEG_CHROMA_SUBSAMPLING_GRAY;
> }
> }
>
next prev parent reply other threads:[~2017-06-29 12:03 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20170627160906epcas4p369a67fdb1b8f6898a1f1b4ddb7927995@epcas4p3.samsung.com>
2017-06-27 16:08 ` [PATCH v3 0/8] [media] s5p-jpeg: Various fixes and improvements Thierry Escande
2017-06-27 16:08 ` [PATCH v3 1/8] [media] s5p-jpeg: Call jpeg_bound_align_image after qbuf Thierry Escande
2017-06-29 12:03 ` Andrzej Pietrasiewicz
2017-06-27 16:08 ` [PATCH v3 2/8] [media] s5p-jpeg: Correct WARN_ON statement for checking subsampling Thierry Escande
2017-06-29 12:03 ` Andrzej Pietrasiewicz [this message]
2017-06-27 16:08 ` [PATCH v3 3/8] [media] s5p-jpeg: Handle parsing error in s5p_jpeg_parse_hdr() Thierry Escande
2017-06-29 12:04 ` Andrzej Pietrasiewicz
2017-06-27 16:08 ` [PATCH v3 4/8] [media] s5p-jpeg: Don't use temporary structure in s5p_jpeg_buf_queue Thierry Escande
2017-06-29 12:04 ` Andrzej Pietrasiewicz
2017-06-29 20:12 ` Jacek Anaszewski
2017-06-27 16:08 ` [PATCH v3 5/8] [media] s5p-jpeg: Split s5p_jpeg_parse_hdr() Thierry Escande
2017-06-29 12:04 ` Andrzej Pietrasiewicz
2017-06-27 16:08 ` [PATCH v3 6/8] [media] s5p-jpeg: Decode 4:1:1 chroma subsampling format Thierry Escande
2017-06-29 12:04 ` Andrzej Pietrasiewicz
2017-06-27 16:08 ` [PATCH v3 7/8] [media] s5p-jpeg: Add support for resolution change event Thierry Escande
2017-06-29 12:04 ` Andrzej Pietrasiewicz
2017-06-27 16:08 ` [PATCH v3 8/8] [media] s5p-jpeg: Add stream error handling for Exynos5420 Thierry Escande
2017-06-29 12:05 ` Andrzej Pietrasiewicz
2017-06-29 12:02 ` [PATCH v3 0/8] [media] s5p-jpeg: Various fixes and improvements Andrzej Pietrasiewicz
2017-06-29 20:13 ` Jacek Anaszewski
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=22da9d2c-a56b-9d57-33a6-79eb42923041@samsung.com \
--to=andrzej.p@samsung.com \
--cc=jacek.anaszewski@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=thierry.escande@collabora.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
all inboxes | Powered by JetHome®