From patchwork Fri Jan 21 13:14:05 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eugen Hristev X-Patchwork-Id: 12719683 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 69E14C433EF for ; Fri, 21 Jan 2022 13:16:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:To :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=oGePdBCq1I4pTFnLkmCJSZ0HklUqtt/zllwBJ2/gHtg=; b=Ty6xQaUcZgqDvv dVlRXxBvopKgzxjXlYUA+HU/Da1ckB7kabvmUX21MfRAviD4AHmnfikTiI+0MkVkLrBgaWbatG69S e84W6iNjpOCkx16Z7m3kJvCgLV5t9hh2UHtMNsZEzfemLO08GR1QiyQAYZh70tp+2VZGpiOjtNOoX Jg6CzymbQZfKI6mKIOgYvbxgJajdlp8b6i7b+E5cTFgAWzM2ftpNDlKvfpDe4H/i45IJmFHRYnJgE SbDqOQxwUEOzgC8OXslx87knLKcLM07kF2scUYdTiYgInxLRT0d9Mmvv5r0cY5Qfngv5SSMHQIjFd KEoZl1ZEPrYMNewmFHJA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nAtkg-00F3ok-2v; Fri, 21 Jan 2022 13:14:50 +0000 Received: from esa.microchip.iphmx.com ([68.232.153.233]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nAtka-00F3l6-E2 for linux-arm-kernel@lists.infradead.org; Fri, 21 Jan 2022 13:14:46 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1642770884; x=1674306884; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=ReEeyKlw3Br3MVtTng1dDKMNcyqh3/EtMacl1TY/yr0=; b=ynzQWeW6VTHFrdQ+xFL5iEc67cit4WF+WU6rnDoRYZqQWJGD9oBvEuAE y6P2XFg/8JvlH3+hzEnmnv3FpP48UZ6nZmdHajl6GjlvFwOfvLNd9veS8 /582SH/Cab8kgaSBL02t2Ok1zYQWZdNHoJ7PYDSM1hOlEx6cubUv5zRgM v3WAhY7If971qtMXCUGiPm3XOfPmVqdhFMQTrmo0CM0CJvoxrmc2Wr1ko yh/y1+hiwF6NEDdAvdritElnqLYLLM6Eig8Vef4eNNE3zupFlo7ZUr7OB MaoUf+DD4OwivHIM4Tay/DW8PxuMvK4OQtUSmbHYSzRzZvFYcj/A3VIAo A==; IronPort-SDR: OxQNeC6cb/ggLpPj4XDjUiAHEqfNXLQNKYBnGmntA4sME/6DZmiZu9o/pKT+XtXa8/cHqHP5NC m0UIW4r7owRGOONHM2SwRatgOrFn2o9nZBGRKj7ToN9q1fqpqZcN0IPS1Ygc8kwF5iCcYBJnC2 KnZ5QeBL2UAsVLlzUmUfHDKL4sNgz0jqVhEEo7wiqXTX4ffbvKGMyvIgYDQa8ryqqxLT2fGs6c y7ILWo4Y/GFgQefkcckvbCIt1DR3h3z9/3khQsUQUZdyJLF1neUoH3t4i+XAb4N3xTkJicwPC9 PsW2Y0rTN92QI7lIbZgPgL+S X-IronPort-AV: E=Sophos;i="5.88,304,1635231600"; d="scan'208";a="150454000" Received: from smtpout.microchip.com (HELO email.microchip.com) ([198.175.253.82]) by esa5.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 21 Jan 2022 06:14:42 -0700 Received: from chn-vm-ex04.mchp-main.com (10.10.85.152) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.17; Fri, 21 Jan 2022 06:14:41 -0700 Received: from ROB-ULT-M18282.microchip.com (10.10.115.15) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server id 15.1.2375.17 via Frontend Transport; Fri, 21 Jan 2022 06:14:25 -0700 From: Eugen Hristev To: , , , , , , Subject: [PATCH v4 00/11] media: atmel: atmel-isc: implement media controller Date: Fri, 21 Jan 2022 15:14:05 +0200 Message-ID: <20220121131416.603972-1-eugen.hristev@microchip.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220121_051444_528982_69EAF160 X-CRM114-Status: GOOD ( 15.70 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Eugen Hristev , sakari.ailus@iki.fi, laurent.pinchart@ideasonboard.com Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This series is the v4 series that attempts to support media controller in the atmel ISC and XISC drivers. The CSI2DC driver was accepted thus removed from the patch series, together with other patches. Important note: this series applies on top of current media_staging tree, as it relies on previous patches in the series which were accepted. Changes in v4: -> as reviewed by Hans, added new patch to remove the 'stop' variable and reworked one patch that was using it -> as reviewed by Jacopo, reworked some parts of the media controller implementation Thanks to everyone who reviewed my work ! Eugen Previous cover letter from v3: This series is the v3 of the series that attempts to support media controller in the atmel ISC and XISC drivers. This series also includes the csi2dc driver which was previously sent in a separate series: https://www.spinics.net/lists/linux-media/msg181042.html https://www.spinics.net/lists/linux-media/msg181044.html The driver now addresses comments received in latest v5 series from last year. The series includes some minor changes and fixes that improve the isc common code base, like removing the enum frameintervals VIDIOC, fixing bytesperline for planar formats, etc. Many thanks to folks from libcamera who helped a lot with understanding how a media controller driver should behave. Feedback is welcome ! Changes in v3: - change in bindings, small fixes in csi2dc driver and conversion to mc for the isc-base. - removed some MAINTAINERS patches and used patterns in MAINTAINERS Changes in v2: - integrated many changes suggested by Jacopo in the review of the v1 series. - add a few new patches Eugen Hristev (11): media: atmel: atmel-isc: replace 'stop' variable with vb2 calls media: atmel: atmel-isc-base: use streaming status when queueing buffers media: atmel: atmel-isc: implement media controller media: atmel: atmel-sama5d2-isc: fix wrong mask in YUYV format check media: atmel: atmel-isc-base: use mutex to lock awb workqueue from streaming media: atmel: atmel-isc: compact the controller formats list media: atmel: atmel-isc: change format propagation to subdev into only verification dt-bindings: media: microchip,xisc: add bus-width of 14 ARM: dts: at91: sama7g5: add nodes for video capture ARM: configs: at91: sama7: add xisc and csi2dc ARM: multi_v7_defconfig: add atmel video pipeline modules .../bindings/media/microchip,xisc.yaml | 2 +- arch/arm/boot/dts/sama7g5.dtsi | 49 ++ arch/arm/configs/multi_v7_defconfig | 3 + arch/arm/configs/sama7_defconfig | 2 + drivers/media/platform/atmel/Makefile | 2 +- drivers/media/platform/atmel/atmel-isc-base.c | 455 +++++++++++------- .../media/platform/atmel/atmel-isc-scaler.c | 250 ++++++++++ drivers/media/platform/atmel/atmel-isc.h | 43 +- .../media/platform/atmel/atmel-sama5d2-isc.c | 67 ++- .../media/platform/atmel/atmel-sama7g5-isc.c | 72 ++- 10 files changed, 694 insertions(+), 251 deletions(-) create mode 100644 drivers/media/platform/atmel/atmel-isc-scaler.c