Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp6806924imm; Tue, 28 Aug 2018 01:05:06 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbkYYRR3n2iAxEnCkdKKg3wT+EF19OY1cy8t6udwKDM75uIMPKTVQr6cZ7o+ycJECgBoEo4 X-Received: by 2002:a62:cfc6:: with SMTP id b189-v6mr395931pfg.224.1535443506916; Tue, 28 Aug 2018 01:05:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535443506; cv=none; d=google.com; s=arc-20160816; b=F4GqJ0sOax55piDnivAMd5vJfW2KsPjLIqckuP0r3y/Al46x1KSXomAKkPIOtCeDcm kskC8pn4YtTb01ASN8Q3jswHkt/gTE+TB/j0FWQ0/HBI3xuau9cvPndCG3g3wTZav/aC j2FbOLKucaMhEKkqgbJBp8+Hi95SayZkECjSJhOjEzN1AF61x4rHCP748Z4V/UmOocSH iX9rtTd9CH/khCLIFa5vjc5tQ5KTThcP+eNNkf3JeAaavtVKA7Q0abw6hrbv4FAfkYzh 99MO5li0nk2Cz0Iwks7NHKeYhsJWjWDwdZed0NGhmGq7mLsjQzwXUZKr7SdIJVDJOF1M mqtA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=Qzn2UJpVLp8G/wegFry8RCTDZ6whk7hMDpR5SYi2Njg=; b=is9NHV6Sa4TbCWr+Jqevt4Qy7P7JOoQEq/pYDCR1twuguCj6X6xa/9GW9jKRA+OybI WWeT0IZBuRS9t1BDEer1cV9bAf4sizM/dN1x5hzJQkWORtr7PpEhMZ/P2UonTgCAdf2U V0FEx212kkqOb+6g45Hh92sw3Ap2E0XrcN04Sb5L0ni3vvCDbilB//B2g2AUBpuWmCOW 2syIo3gdPx203D+whrkUYVW9EgjyxdBkL69+BAD32Tod2i3/CiDedGIb3MaoPofhDvcS HbLyQ3opAVgnEu9W4K0wVmAeZMmqbPAfyKVZ8IfS6ueyzNCRei/+gKEKpVWAvxn34MIl u3dQ== 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 u10-v6si413696plr.58.2018.08.28.01.04.51; Tue, 28 Aug 2018 01:05:06 -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 S1727302AbeH1LxU (ORCPT + 99 others); Tue, 28 Aug 2018 07:53:20 -0400 Received: from mail.bootlin.com ([62.4.15.54]:34771 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726997AbeH1LxU (ORCPT ); Tue, 28 Aug 2018 07:53:20 -0400 Received: by mail.bootlin.com (Postfix, from userid 110) id 3805A207EB; Tue, 28 Aug 2018 10:02:53 +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 shortcircuit=ham autolearn=disabled version=3.4.0 Received: from localhost.localdomain (AAubervilliers-681-1-53-19.w90-88.abo.wanadoo.fr [90.88.170.19]) by mail.bootlin.com (Postfix) with ESMTPSA id C316620618; Tue, 28 Aug 2018 10:02:52 +0200 (CEST) From: Paul Kocialkowski To: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, devel@driverdev.osuosl.org, linux-arm-kernel@lists.infradead.org Cc: Mauro Carvalho Chehab , Maxime Ripard , Paul Kocialkowski , Greg Kroah-Hartman , Chen-Yu Tsai , Thomas Petazzoni , linux-sunxi@googlegroups.com, Randy Li , Hans Verkuil , Ezequiel Garcia , Tomasz Figa , Alexandre Courbot , Philipp Zabel , Laurent Pinchart , Sakari Ailus Subject: [PATCH 0/2] HEVC/H.265 stateless support for V4L2 and Cedrus Date: Tue, 28 Aug 2018 10:02:38 +0200 Message-Id: <20180828080240.10982-1-paul.kocialkowski@bootlin.com> X-Mailer: git-send-email 2.18.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This introduces the required bits for supporting HEVC/H.265 both in the V4L2 framework and the Cedrus VPU driver that concerns Allwinner devices. A specific pixel format is introduced for the HEVC slice format and controls are provided to pass the bitstream metadata to the decoder. Some bitstream extensions are knowingly not supported at this point. Since this is the first proposal for stateless HEVC/H.265 support in V4L2, reviews and comments about the controls definitions are particularly welcome. On the Cedrus side, the H.265 implementation covers frame pictures with both uni-directional and bi-direction prediction modes (P/B slices). Field pictures (interleaved), scaling lists and 10-bit output are not supported at this point. This series is based upon the following series: * Cedrus driver for the Allwinner Video Engine, using media requests * media: cedrus: Add H264 decoding support Cheers! Paul Kocialkowski (2): media: v4l: Add definitions for the HEVC slice format and controls media: cedrus: Add HEVC/H.265 decoding support .../media/uapi/v4l/extended-controls.rst | 416 ++++++++++++++ .../media/uapi/v4l/pixfmt-compressed.rst | 15 + .../media/uapi/v4l/vidioc-queryctrl.rst | 18 + .../media/videodev2.h.rst.exceptions | 3 + drivers/media/v4l2-core/v4l2-ctrls.c | 26 + drivers/media/v4l2-core/v4l2-ioctl.c | 1 + drivers/staging/media/sunxi/cedrus/Makefile | 2 +- drivers/staging/media/sunxi/cedrus/cedrus.c | 19 + drivers/staging/media/sunxi/cedrus/cedrus.h | 20 +- .../staging/media/sunxi/cedrus/cedrus_dec.c | 9 + .../staging/media/sunxi/cedrus/cedrus_h265.c | 540 ++++++++++++++++++ .../staging/media/sunxi/cedrus/cedrus_hw.c | 4 + .../staging/media/sunxi/cedrus/cedrus_regs.h | 290 ++++++++++ .../staging/media/sunxi/cedrus/cedrus_video.c | 13 + include/media/v4l2-ctrls.h | 6 + include/uapi/linux/v4l2-controls.h | 155 +++++ include/uapi/linux/videodev2.h | 7 + 17 files changed, 1542 insertions(+), 2 deletions(-) create mode 100644 drivers/staging/media/sunxi/cedrus/cedrus_h265.c -- 2.18.0