Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp4106166imj; Tue, 12 Feb 2019 09:52:33 -0800 (PST) X-Google-Smtp-Source: AHgI3IZyt31DsMUq0hIGPU+bY9Zaw0nXLLeIcyzQmj7S0lHhToXhOnL1TJG9PZkf2HmGqia3Qyku X-Received: by 2002:a63:9402:: with SMTP id m2mr4527641pge.93.1549993953116; Tue, 12 Feb 2019 09:52:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549993953; cv=none; d=google.com; s=arc-20160816; b=IgPa9Y3c+9cUw7boCTWdrRuJNFqxGf6Dn5JxFGOmQYPe2W9oeyqOPf939dYDz/f3Ov +RHFN1w4Qy8ZgVyKsW0uWPODo1/hei2BL5LvbCCXl7oxWzNKpajuN0Xs+Ffu6g8ydTwR 7DawGAbyt+6uYh+tRlP6bQQAofUPgxrx/OeASzfIwAM7ghKRK1D5e9M5HO5DWwCdpYaR 1ibb5DTZ7OA9a3T/pvgD6jHXs5zKeXvZcHIel2uFEyHENXzoCoe4k5yijriasx4cx1WT 6tWAYvP7tWM6ZugeLs2eJvu4LZbEjOC1fyw2sZaoAbP0Yy13EcOXYjvx6QN3N+JscazD q8yw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=w4gEFxIxyax5TlhbyybnDHgnUurqHD/qF92buHHcIR8=; b=F40MVMPjwmJYXAqH9G6GNnyASHViCcq0eyyMIDOKOBbfxk0v4UHQw6BeUe2n50CVaZ 6yJQlV5pRwckNWY0CZAtNue++tXWt6T0XRyYAz/0c8dbSvg2SSXajcSHLkcUPKm7nv86 sw4UYjn6PY3XIZd/kII6NRV6ae36giZxlRDQCL8p4aPxLEoiYzLDw4rLu+P/UuxlEl1u njiYiE3CvY6xOfcOus05sqnlAYuqqEBgD7P184h8ZNyFRZj91Py23et6IxodbAGcToG4 OsjTTZKF15SBihorylAEEImgecHwUsHgsCxrY25K2OuZazoN70uGKzqXr9m6pRnzykR2 Z9Dw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=qgKoLKFm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d25si12998757pgd.88.2019.02.12.09.52.16; Tue, 12 Feb 2019 09:52:33 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=qgKoLKFm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731360AbfBLRqn (ORCPT + 99 others); Tue, 12 Feb 2019 12:46:43 -0500 Received: from mail-wm1-f68.google.com ([209.85.128.68]:40152 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727548AbfBLRqm (ORCPT ); Tue, 12 Feb 2019 12:46:42 -0500 Received: by mail-wm1-f68.google.com with SMTP id q21so3967877wmc.5; Tue, 12 Feb 2019 09:46:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=w4gEFxIxyax5TlhbyybnDHgnUurqHD/qF92buHHcIR8=; b=qgKoLKFmkAuxh1Ar6DdvgYrww1WOQersJ5ep5UCiUi0J+9yhwEkFpUCCy8yfQmKs0F O7B2p6q6/iq8xSEYfuJ9SJhl04BwUhPNSCVqmEr314+Ig1yj83cG1TfXkNst80XutOIO n7t9JWJS9XIJ/ZWr3kpfo3/Vv8XuhMUgXopwcOD4Wh9PMgI93mxVtXzZL7DrGjYZtH4+ bM0uXg6iSpjZRPDC14l9NsVSZDYB3O/6vyny+N9pGx9VUWCGPrxevcUNZWO/Iqh5C3x2 xb1WqgwKxQ7vVRK6zYMmr5wcMsMOhQrKdBYl4VJ6btXG/C9iO7iamMf3Og/asoc4uVUr d+2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=w4gEFxIxyax5TlhbyybnDHgnUurqHD/qF92buHHcIR8=; b=PeQxv5PwrrPsWjnrE2sTXseFb8iGifO3/J1apWoreRwy08iFawfFyf7lxqI63GcVp8 LHzXSUMEjVUpN4j1y5LyyRWX+FV2M+2zUf7p5/tq4b0sPSBuwf0IeeVOQ7mHmK/2zAXP b5NE+0fH+rIDuUHFVFVI6JjwvB+coqcg5IUtzNEjspq6Jip0idBwMp5V6NLFwpg/s47L SUPlgusvMnS94r504Uv2OjUaZgWv9wqEA3IUnT8S69/+pA5FSvjP0aLJvj5polYT6ltw PGnLOnMNCMfTiSyX9ysm0VOUMKCwBb420rBpKP/kmZKx4pQ1ZcDPfjOucwu8+IhHnvmP 2C7g== X-Gm-Message-State: AHQUAuaQr5Kk1Gg/ZRndyv6/z3+ZB53aR/jsiz3DrARC0FGup11yw/+k cEwcdkqYu4PKxO6SDl1Tdzo= X-Received: by 2002:a1c:e10a:: with SMTP id y10mr9289wmg.73.1549993601070; Tue, 12 Feb 2019 09:46:41 -0800 (PST) Received: from jernej-laptop.localnet (APN-123-243-40-gprs.simobil.net. [46.123.243.40]) by smtp.gmail.com with ESMTPSA id q9sm9102303wrv.26.2019.02.12.09.46.38 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 12 Feb 2019 09:46:40 -0800 (PST) From: Jernej =?utf-8?B?xaBrcmFiZWM=?= To: linux-sunxi@googlegroups.com, maxime.ripard@bootlin.com Cc: hans.verkuil@cisco.com, acourbot@chromium.org, sakari.ailus@linux.intel.com, Laurent Pinchart , tfiga@chromium.org, posciak@chromium.org, Paul Kocialkowski , Chen-Yu Tsai , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-media@vger.kernel.org, nicolas.dufresne@collabora.com, jenskuske@gmail.com, jonas@kwiboo.se, ezequiel@collabora.com, Thomas Petazzoni Subject: Re: [linux-sunxi] [PATCH v3 2/2] media: cedrus: Add H264 decoding support Date: Tue, 12 Feb 2019 18:46:38 +0100 Message-ID: <3572175.7W1cnfb8sa@jernej-laptop> In-Reply-To: <20190212104314.slytpbufwhf5ujv7@flea> References: <12916702.RFRCeC2GgE@jernej-laptop> <20190212104314.slytpbufwhf5ujv7@flea> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Dne torek, 12. februar 2019 ob 11:43:14 CET je Maxime Ripard napisal(a): > Hi, >=20 > On Mon, Feb 11, 2019 at 08:21:31PM +0100, Jernej =C5=A0krabec wrote: > > > + reg =3D 0; > > > + /* > > > + * FIXME: This bit tells the video engine to use the default > > > + * quantization matrices. This will obviously need to be > > > + * changed to support the profiles supporting custom > > > + * quantization matrices. > > > + */ > > > + reg |=3D VE_H264_SHS_QP_SCALING_MATRIX_DEFAULT; > >=20 > > This flag should not be needed anymore. From what I see, you correctly = set > > scaling matrix every time. >=20 > The scaling matrix control is optional, so I guess we should protect > that by a check on whether that control has been set or not. What do > you think? Is it? Consider following snippet from your patch: { .id =3D V4L2_CID_MPEG_VIDEO_H264_SCALING_MATRIX, .elem_size =3D sizeof(struct v4l2_ctrl_h264_scaling_matrix), .codec =3D CEDRUS_CODEC_H264, .required =3D true, }, Doesn't "required =3D true" mean that it's mandatory? But yes, if it's opti= onal,=20 then you should add a check. Best regards, Jernej