Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp4429573imm; Tue, 7 Aug 2018 01:06:55 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcNcQMZm9KSIHE3z8cSW+TNQq9WmyKWx7Wv3NSXo74Mwc7YPDOq1KUanFscMXnjEYaP+0Zj X-Received: by 2002:a63:d74f:: with SMTP id w15-v6mr17797370pgi.306.1533629215894; Tue, 07 Aug 2018 01:06:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533629215; cv=none; d=google.com; s=arc-20160816; b=PA/OpgHwT0XZ/SJeBLyP5GPkTPkViKLsrWLbkNgRsftez6N53FDw8vrKYZYLHI/6yY t3h4GR00ozZUbojL42ki99y7EVZxje/EymUxob4x1/1p1EExUf48U2SSumw03gUWTTHr 1/OTOs48PYzaIEbdjtpjO8IdlPN/id4RWZtXdUpcu5mzMb3a9lSC6e7IWM6yjaqTe4H4 XSDh6oqwNMrGpOt1+bXyd4rzXDfUYNwjR93trb4QzCF43u2zez11YrMwqFI9XVxXaaOF nu+8oYEwZ0l6hfPQeM++wk9Dm+ycMZTh41xgx3HlMePQoG0/34xy0Cczd6vd65M76dCM 9zTw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:organization:references :in-reply-to:date:cc:to:from:subject:message-id :arc-authentication-results; bh=oT1VcqKdwaf1+uNo937zFEk4ZXOZ2IzJAVf9Wtfr3W4=; b=HPLakXl1k6/nsAUPlwgbMKVLhImmTnb4MC8D+xXnOSJfAqDCL8LTvmGv73ALifoYhU jbOIOAfg9tfniBS0tZ+0krYqttIEwRVp/S9dAv0QP3aHg6faeE3LNmdC6RoX5yv2Uz0t JD+6zqlJDmqMs29Nyyi2fc1u9Bav9IhmRYmAZG5DKmFCbQ33hYnJ1lDGeBvTPJrV8sCK iyvfpd+kqaT4fLnQYHMwHtkS2+ttW8LT+mfOeWRTB5n83XVEFdNisAcU+i9qafAvk9hS B+EC1YUI5W3rBgGxInn/yUaBJn4DoKJHqTMzBQvJtyvF+zR+pYNjW1ehz0xR3gtjJR1+ Nk8Q== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t16-v6si768325pgi.457.2018.08.07.01.06.41; Tue, 07 Aug 2018 01:06:55 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388841AbeHGJdG (ORCPT + 99 others); Tue, 7 Aug 2018 05:33:06 -0400 Received: from mail.bootlin.com ([62.4.15.54]:50900 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727360AbeHGJdG (ORCPT ); Tue, 7 Aug 2018 05:33:06 -0400 Received: by mail.bootlin.com (Postfix, from userid 110) id 0752320908; Tue, 7 Aug 2018 09:20:04 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.bootlin.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.0 Received: from aptenodytes (AAubervilliers-681-1-99-143.w90-88.abo.wanadoo.fr [90.88.4.143]) by mail.bootlin.com (Postfix) with ESMTPSA id 368572069C; Tue, 7 Aug 2018 09:19:53 +0200 (CEST) Message-ID: <94e3eaf26ed7d6859d74abad0a0dbc94a3308a2e.camel@bootlin.com> Subject: Re: [PATCH v6 4/8] media: platform: Add Cedrus VPU decoder driver From: Paul Kocialkowski To: Tomasz Figa , Maxime Ripard , Alexandre Courbot Cc: Hans Verkuil , Linux Media Mailing List , devicetree@vger.kernel.org, Linux Kernel Mailing List , "list@263.net:IOMMU DRIVERS , Joerg " "Roedel ," , devel@driverdev.osuosl.org, Mauro Carvalho Chehab , Rob Herring , Mark Rutland , Chen-Yu Tsai , Greg KH , thomas.petazzoni@bootlin.com, linux-sunxi@googlegroups.com, Hugues FRUCHET , ayaka , Ezequiel Garcia , Philipp Zabel , Laurent Pinchart , Sakari Ailus Date: Tue, 07 Aug 2018 09:19:54 +0200 In-Reply-To: References: <20180725100256.22833-1-paul.kocialkowski@bootlin.com> <20180725100256.22833-5-paul.kocialkowski@bootlin.com> Organization: Bootlin Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="=-ZkudRXiEFCPQyFqeie9D" X-Mailer: Evolution 3.28.4 Mime-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-ZkudRXiEFCPQyFqeie9D Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi, On Mon, 2018-08-06 at 23:10 +0900, Tomasz Figa wrote: > Hi Paul, >=20 > On Mon, Aug 6, 2018 at 10:50 PM Paul Kocialkowski > wrote: > >=20 > > Hi Hans and thanks for the review! > >=20 > > On Sat, 2018-08-04 at 14:18 +0200, Hans Verkuil wrote: > > > Hi Paul, > > >=20 > > > See below for my review comments. Mostly small fry, the main issue I = found is > > > that there is no support for VIDIOC_DECODER_CMD. That's the proper wa= y of > > > stopping a decoder. Don't rely on the deprecated allow_zero_bytesused= field. > >=20 > > Mhh, it looks like this was kept around by negligence, but we do expect > > that streamoff stops the decoder, not a zero bytesused field. > >=20 > > Is it still required to implement the V4L2_DEC_CMD_STOP > > VIDIOC_DECODER_CMD in that case? I read in the doc that this ioctl > > should be optional. >=20 > If I understand correctly that this decoder is stateless, there should > be no need for any special flush sequence, since a 1:1 relation > between OUTPUT and CAPTURE buffers is expected, which means that > userspace can just stop queuing new OUTPUT buffers and keep dequeuing > CAPTURE buffers until it matches all OUTPUT buffers queued before. This is indeed a stateless decoder and I don't have any particular need for a particular stop command indeed, since flushing remaining buffers when stopping is already implemented at streamoff time. > By the way, I guess we will also need some documentation for the > stateless codec interface. Do you or Maxime (who sent the H264 part) > have any plans to work on it? We have some internal documents, which > should be convertible to rst using pandoc, but we might need some help > with updating to latest request API and further editing. Alexandre > (moved from Cc to To) is going to be looking into this. As far as I'm concerned, I am interested in contributing to this documentation although our priorities for the Allwinner VPU effort are currently focused on H265 support. This might mean that my contributions to this documentation will be made on a best-effort basis (as opposed to during the workday). Either way, if someone was to come up with an initial draft, I'd be happy to review it! Cheers, Paul --=20 Paul Kocialkowski, Bootlin (formerly Free Electrons) Embedded Linux and kernel engineering https://bootlin.com --=-ZkudRXiEFCPQyFqeie9D Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iQEzBAABCAAdFiEEJZpWjZeIetVBefti3cLmz3+fv9EFAltpSBoACgkQ3cLmz3+f v9FlHQgAif+K3qb4JnoZLXyOrb1AKLTQ2nfVxhYw2FmEAQ7QVRf0syn4vF/2nJpa +b5Qe70Mhw8oz7ZmoRaHrFSu3h4y43+rrsE4h0BfBE9in407DM0w95S+0khDSXKl Sxyo2uKVxAMoNqkT+/JW02KzkLJECajsigHzHuTPLQSNBY1GnngXLFMez70b4dKU fpSn51oGBW8UY0/t5lU7oagLUajMCP0kRlw3Cm7X+dShk4gD/jOMbQj4Iv/Ol7PY mBzX54Gq4v4OqM1K8gdT2oyO7U9gxXv/jk+QAvDt3hSClBxVag/glhNjLqmjWGfi /idCyK30fT7MO9GqdlvyQ9fiv56N2Q== =nmMH -----END PGP SIGNATURE----- --=-ZkudRXiEFCPQyFqeie9D--