Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp630056ybh; Wed, 18 Mar 2020 06:22:23 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsASlTOW5xtwpRRGJ63Sh8GM44fjYK7MItjDflxD7ZAnr0hg2WZkPxqsKwoyJDLnUUnkti4 X-Received: by 2002:a9d:7cd9:: with SMTP id r25mr1209563otn.296.1584537743668; Wed, 18 Mar 2020 06:22:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584537743; cv=none; d=google.com; s=arc-20160816; b=kZzoYJZaJKnSJMkREjdvBLkTg42nhH1Xvrku6f9kPw0+QcDjqkC89iQ+1p4gmiadR6 jEJyWNsPuKlrJjZO9uO9YJzdGkckL0CX6k2z+lOUAVb5tAi10qY6LP9rw7nKpaXrpL0e TdCB4gs2DypbAMqXpWiW9jfDt+nNvGm9ReYa94e7VmIxe3G/ieVO2W91kxjnefLFQyh1 dzy4ri5yW4ruA+aof3su3aZv8m1ZkphRBcj5ClfEPhyVqw9c50ISPIVurN/RoEjt1SCt BpNBL6C2o9hCueYozIXwUUygBvFe+TI2J9VdipU846gIVUqO8fW0Hguj4Chftnk413Jy 06LQ== 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 :message-id:date:subject:cc:to:from; bh=4QDytJ2CuDWOahSfcFj9cHoQy6eJeDt7b+DtYT3DwgM=; b=tuveot7aoy1rIiRje3vrdZJrUtp66bgy1LCP72bkLiuaiENbMSTgXRp4hCnjZ9EVuJ nzQic6d7yJ4jVC23wQkonq79ZV9vf4Se+Go2gGW336w6gTiIw/u7b4eTNhP/wbvbH+zW oOA58SmqI/jpN9UXn71oLIWYO0tA0zfKbdCqV6oymjlUnim3L7aWwseXZV2TNl9xZeKW THS+Mlkodh8U74/+lyG1LA19S2D1avRZ/wzghNh5eD0DZMzqc13CyoS+TDBLyFEZqEmu msFxBfZSWlSvKdiPYbQYscJ1LZCGz4mK7W3MyCa+/cUnoqCTI3ZsKX9PPsWjFLXD5u0m pefQ== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n5si3171408otk.178.2020.03.18.06.22.11; Wed, 18 Mar 2020 06:22:23 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727033AbgCRNVt (ORCPT + 99 others); Wed, 18 Mar 2020 09:21:49 -0400 Received: from bhuna.collabora.co.uk ([46.235.227.227]:44446 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726638AbgCRNVs (ORCPT ); Wed, 18 Mar 2020 09:21:48 -0400 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: ezequiel) with ESMTPSA id 60E0429661A From: Ezequiel Garcia To: linux-media@vger.kernel.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org Cc: Tomasz Figa , Nicolas Dufresne , kernel@collabora.com, Jonas Karlman , Heiko Stuebner , Hans Verkuil , Alexandre Courbot , Jeffrey Kardatzke , Rob Herring , Ezequiel Garcia Subject: [PATCH v2 0/8] hantro: set of small cleanups and fixes Date: Wed, 18 Mar 2020 10:21:00 -0300 Message-Id: <20200318132108.21873-1-ezequiel@collabora.com> X-Mailer: git-send-email 2.25.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi all, Cleanups and fixes, second iteration. The main idea here is to address two issues, and while at it, clean the driver a bit. The first issue can be found in Patch 1, when the Request API is used, the CAPTURE buffer should be returned _before_ the OUTPUT buffer, to avoid waking up userspace prematurely. I noticed this issue while working on the rkvdec driver, but this time I've decided to tackle it at the core, in v4l2_m2m_buf_done_and_job_finish(). The second issue is a simple compliance issue, which is solved by refactoring the driver, dealing with internal set format properly. Changes v2: * Fix compile warning introduced by patch 6. * I'm adding two additional patches this time. Patch 7 converts the binding to json-schema, and patch 8 puts linux-rockchip mailing list in MAINTAINERS. Thanks, Ezequiel Ezequiel Garcia (8): v4l2-mem2mem: return CAPTURE buffer first hantro: Set buffers' zeroth plane payload in .buf_prepare hantro: Use v4l2_m2m_buf_done_and_job_finish hantro: Remove unneeded hantro_dec_buf_finish hantro: Move H264 motion vector calculation to a helper hantro: Refactor for V4L2 API spec compliancy dt-bindings: rockchip-vpu: Convert bindings to json-schema hantro: Add linux-rockchip mailing list to MAINTAINERS .../bindings/media/rockchip-vpu.txt | 43 ------- .../bindings/media/rockchip-vpu.yaml | 82 +++++++++++++ MAINTAINERS | 3 +- drivers/media/v4l2-core/v4l2-mem2mem.c | 11 +- drivers/staging/media/hantro/hantro.h | 7 +- drivers/staging/media/hantro/hantro_drv.c | 37 ++---- drivers/staging/media/hantro/hantro_hw.h | 31 +++++ drivers/staging/media/hantro/hantro_v4l2.c | 111 +++++++++--------- 8 files changed, 194 insertions(+), 131 deletions(-) delete mode 100644 Documentation/devicetree/bindings/media/rockchip-vpu.txt create mode 100644 Documentation/devicetree/bindings/media/rockchip-vpu.yaml -- 2.25.0