Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp2450367rdb; Wed, 21 Feb 2024 08:03:24 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWQEMhx9KTujDW5ApTqnCnYYZEMggJT125wqTl92jV68fbOZ1IPlKmr4LHL0rWXgJJpXE6cKXO6IHDeyP+Hjnnd4DcC2OmrfBGze/o7wg== X-Google-Smtp-Source: AGHT+IFknlU4ozGVvnMgeaLJ+0oCq3HPP9d3DpWMCLvbaTDUeJbRBffgodsRAz+ptBF5EjkPvE3g X-Received: by 2002:a37:e20d:0:b0:787:272a:e298 with SMTP id g13-20020a37e20d000000b00787272ae298mr19323544qki.62.1708531403732; Wed, 21 Feb 2024 08:03:23 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708531403; cv=pass; d=google.com; s=arc-20160816; b=MFk7FE2Wx0p06yw2od8EpnZGZ3oAgnpCP5bfQ5XfTAqXbVQsX7RaJNun528oINO5Bm Cvbrzq8OZ0tXFdWxFExXWZ8c0VDNUxy2AF2szziOODXW/TOKXfZRJchMlW29r7Mabru7 svGE4OTVadNmkYmd/CvQwwv1EcWzdKZLdh3FLwMADZNuPLFLy6dUps1a9YdHPxDwjohS RSmirXXiGTTTlWJlyaQSUYIyfMit3DUqwL8JltbCNuh+MiwGzAflCdp52QSNwkbDc9Ra Ay/h1ToYEJpeWcRa8jf3dsn31QcpERru7Rrk1TDF+JwTW5VHsUADhGuSPsw+1prugXNf Ag+Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:from:subject:message-id :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :date:dkim-signature; bh=FJVga6C02gm8F+WILMx3neboftdensw7Cuuwer2cEQA=; fh=9tpwbF+Ggsz3TRUR/fEl95gEkV0d6ch0WV7wrQZnV5A=; b=kpOs8U4zblWw3z4hzoE3QV3YhPq7uuAAJj9HLPCOCHSUyKkxcp1h+88NeDSYzbcmh1 UBuL8aiscNH4SwOG4eRtRwwORCHvkYWwa8NlNXpvxeDHC9IpggWi/OSP2w5G2a751RmX NmoLue5mcg3AE3yt24dS4TJ1QHXYOoFQitu9riKCmDcsI4/BE826eZP+RHyXBfkQu1tC LYLx0EONjqa1R4jA1tT3MLM24PfTlxCBH/NwphgJYGeLL4GLrOQjgRZytzhL3JJhie0p /pvzTVzM8lRyt4YjF140ufW4Nt3lHF5Gi9aYub9AZDyYC6JT1MAZveS8p77aH69MMQtp DZ4g==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=aHeBsY2A; arc=pass (i=1 spf=pass spfdomain=flex--panikiel.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-75062-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-75062-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id f7-20020a05620a12e700b00787820448b3si2207596qkl.565.2024.02.21.08.03.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Feb 2024 08:03:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-75062-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=aHeBsY2A; arc=pass (i=1 spf=pass spfdomain=flex--panikiel.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-75062-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-75062-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id E6BE81C245F6 for ; Wed, 21 Feb 2024 16:03:21 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7EC9181AC3; Wed, 21 Feb 2024 16:02:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="aHeBsY2A" Received: from mail-wr1-f74.google.com (mail-wr1-f74.google.com [209.85.221.74]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CD03881AA5 for ; Wed, 21 Feb 2024 16:02:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.74 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708531353; cv=none; b=Rwv5ywoSPmp0FWQrUnEAdrA7vxZ2uetj2OsAiYRQChjK3zrijdT1+TAJywXqt2unbg+b2e084LznUlc4Mu40Ski0iGI/yB8sqj1z6l0Ttclt78KKaq4Fcar+Dm0S1HtqJXOS1s63d0NII65i6me/8zmOKvjQ/prjSSA7rBbOlBg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708531353; c=relaxed/simple; bh=+H6rvSd1RmIYXLWsmSKmwveEp9WRJgJ4LAtwMlLEhJw=; h=Date:Mime-Version:Message-ID:Subject:From:To:Cc:Content-Type; b=PER6IZPnOacHZsgVRpkQf7vyUxwYj6XtbfNJvs6biPHMw1CYPKYVSQQQrpF9wJa4of5yTOuKr4AhKiDfMBybB48DHFzIRrZ7ZAaxSpRUXgddJ6Vn9n3/O20hqWElQaz05Is82Ypnt3m5lT8t3WPOg2n2l0pY8yFGeXRRUxcs6rs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--panikiel.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=aHeBsY2A; arc=none smtp.client-ip=209.85.221.74 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--panikiel.bounces.google.com Received: by mail-wr1-f74.google.com with SMTP id ffacd0b85a97d-33d308b0c76so1881423f8f.0 for ; Wed, 21 Feb 2024 08:02:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1708531350; x=1709136150; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:from:subject:message-id :mime-version:date:from:to:cc:subject:date:message-id:reply-to; bh=FJVga6C02gm8F+WILMx3neboftdensw7Cuuwer2cEQA=; b=aHeBsY2A1d5dLni4sszxx1Kfw4UTKs8Dcae5lAqXWLgldgh0ewWtnEaVs8Cfw77Oso wqFt6NUS4r3WPt0otOow0bklN7Cu7gCg7znY37sDDy/wgn/R/0cJPG3ZlgUOUAdPtQnO 7E75bgnQfzXQ7iOQUKg45UqnnzUU2XgFIGc/4O6I5tkSVL+MlnlEX0V42gTkz3c6JGoD D3oELuDLAVMzyMXV0TOBWVBXz2gql9khbPt80WU3M2zkml4nm3AiMlRodYL5okSeUCuJ pEmqbD52NK6aii0xSZnX3RMcULbBZ8hlyZyx8FZ6eCSjhJQX2/E1a/hClzgddelN3sqx XvIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708531350; x=1709136150; h=content-transfer-encoding:cc:to:from:subject:message-id :mime-version:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=FJVga6C02gm8F+WILMx3neboftdensw7Cuuwer2cEQA=; b=QSWOm4y5g8oUbph3voimhKoPg1dAW9f8DIXX8WnlJMN9myu1jdckeyxOAvbPYUpNuJ s8CJEv9jlXhAP3OYavRkxC9hR2inEhInsIl2hdvRm0gotCEcms6C4OEesT/O1eElEXQJ pFZuqY6QFV60HxB/ihPwPNSkJVei2184ejFZLDeUFSlxx6XrjdDE7EaLa8qCxw6xWTbW ZeJD+7flcrlAW7NJsH2HLOcQkPNnbESqPNg3Ss5ZIofXB5zsQEuFPW8qVYSZdseQHKSI OyVNQG7CKDwGToYiQU6OpA1t4/dE1SfYadV7sAPBJN4qeRm/UvDaG8t2pcBWmxcDbKiG kj6w== X-Forwarded-Encrypted: i=1; AJvYcCXh1On8FwplIZcBi4YsyacwTJAaL166E6nhnlQJBKCsoaWvtxcFpldY18KLhAK0wIKzp21jClxcWVqwdQe4a1zwq+abORw5wGZ9ys97 X-Gm-Message-State: AOJu0YyXT0gwfBz+ezAtmEG4AFLhMJbHwycvOXXEG21qBdYyNdqVfd2+ YFwnaJjDsNxAw7hX1pXwzRt/ohGFzK2sf3bGuy0Pp0seOMN/ZDgaNx8KOtv/EbW8Tf0Wf8mIIRT 9nx2+P2evzQ== X-Received: from szatan.c.googlers.com ([fda3:e722:ac3:cc00:28:9cb1:c0a8:2d83]) (user=panikiel job=sendgmr) by 2002:adf:ce90:0:b0:33d:87e6:c960 with SMTP id r16-20020adfce90000000b0033d87e6c960mr89wrn.6.1708531350183; Wed, 21 Feb 2024 08:02:30 -0800 (PST) Date: Wed, 21 Feb 2024 16:02:06 +0000 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 X-Mailer: git-send-email 2.44.0.rc0.258.g7320e95886-goog Message-ID: <20240221160215.484151-1-panikiel@google.com> Subject: [PATCH v2 0/9] Add Chameleon v3 video support From: "=?UTF-8?q?Pawe=C5=82=20Anikiel?=" To: airlied@gmail.com, akpm@linux-foundation.org, conor+dt@kernel.org, daniel@ffwll.ch, dinguyen@kernel.org, hverkuil-cisco@xs4all.nl, krzysztof.kozlowski+dt@linaro.org, maarten.lankhorst@linux.intel.com, mchehab@kernel.org, mripard@kernel.org, robh+dt@kernel.org, tzimmermann@suse.de Cc: devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, chromeos-krk-upstreaming@google.com, ribalda@chromium.org, "=?UTF-8?q?Pawe=C5=82=20Anikiel?=" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Google Chameleon v3 is a testing device capable of emulating multiple DisplayPort monitors, used for testing purposes. It is based on an Arria 10 SoCFPGA. This patchset adds V4L2 drivers for two IP blocks used in the device's FPGA: the Chameleon v3 framebuffer, and the Intel DisplayPort RX IP. The former is a video capture device that takes video signal and writes frames into memory, which can be later processed by userspace. The latter is a DisplayPort receiver IP from Intel, its datasheet can be found at: https://www.intel.com/programmable/technical-pdfs/683273.pdf The framebuffer driver is a regular v4l2 capture device driver, while the DP RX driver is a v4l2 subdevice driver. In order to avoid code duplication, some parts of the DisplayPort code from the DRM subsystem were put into headers usable by the DP RX driver. Apart from that, the patchset adds a new callback to the internal v4l2 subdevice API to allow querying the dv timings of individual video streams of the DP receiver. v2 changes: - Add missing includes in dt binding examples - Add version number to intel,dprx compatible - Use generic node names in dts - Add and document IP configuration parameters - Remove IRQ registers from intel-dprx (they're not a part of the IP) - Remove no-endpoint property and check for "port" node instead Pawe=C5=82 Anikiel (9): media: v4l2-subdev: Add a pad variant of .query_dv_timings() media: Add Chameleon v3 framebuffer driver drm/dp_mst: Move DRM-independent structures to separate header lib: Move DisplayPort CRC functions to common lib drm/display: Add mask definitions for DP_PAYLOAD_ALLOCATE_* registers media: intel: Add Displayport RX IP driver media: dt-bindings: Add Chameleon v3 framebuffer media: dt-bindings: Add Intel Displayport RX IP ARM: dts: chameleonv3: Add video device nodes .../bindings/media/google,chv3-fb.yaml | 67 + .../devicetree/bindings/media/intel,dprx.yaml | 160 ++ .../socfpga/socfpga_arria10_chameleonv3.dts | 152 ++ drivers/gpu/drm/display/Kconfig | 1 + drivers/gpu/drm/display/drm_dp_mst_topology.c | 76 +- drivers/media/platform/Kconfig | 1 + drivers/media/platform/Makefile | 1 + drivers/media/platform/google/Kconfig | 3 + drivers/media/platform/google/Makefile | 2 + .../media/platform/google/chameleonv3/Kconfig | 13 + .../platform/google/chameleonv3/Makefile | 3 + .../platform/google/chameleonv3/chv3-fb.c | 895 +++++++ drivers/media/platform/intel/Kconfig | 12 + drivers/media/platform/intel/Makefile | 1 + drivers/media/platform/intel/intel-dprx.c | 2176 +++++++++++++++++ drivers/media/v4l2-core/v4l2-subdev.c | 11 + include/drm/display/drm_dp.h | 9 +- include/drm/display/drm_dp_mst.h | 238 ++ include/drm/display/drm_dp_mst_helper.h | 232 +- include/linux/crc-dp.h | 10 + include/media/v4l2-subdev.h | 5 + lib/Kconfig | 8 + lib/Makefile | 1 + lib/crc-dp.c | 78 + 24 files changed, 3851 insertions(+), 304 deletions(-) create mode 100644 Documentation/devicetree/bindings/media/google,chv3-fb.= yaml create mode 100644 Documentation/devicetree/bindings/media/intel,dprx.yaml create mode 100644 drivers/media/platform/google/Kconfig create mode 100644 drivers/media/platform/google/Makefile create mode 100644 drivers/media/platform/google/chameleonv3/Kconfig create mode 100644 drivers/media/platform/google/chameleonv3/Makefile create mode 100644 drivers/media/platform/google/chameleonv3/chv3-fb.c create mode 100644 drivers/media/platform/intel/intel-dprx.c create mode 100644 include/drm/display/drm_dp_mst.h create mode 100644 include/linux/crc-dp.h create mode 100644 lib/crc-dp.c --=20 2.44.0.rc0.258.g7320e95886-goog