From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lj1-f178.google.com (mail-lj1-f178.google.com [209.85.208.178]) (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 4C1CC38C2C2 for ; Tue, 3 Mar 2026 08:42:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.178 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772527383; cv=none; b=g2HSwOwMIyJWDP7tlTnX9j76WBkiayxZWsuCztXlHwDFJexYgMUOb2yOu1Jn7lNbj8YCb6sqVOZVumvEAxj9/yqVZssi2XTSDrV7bl9gq3ANnF71xiAyVmyX2OFmwmPkN40Z1KtG0Vq0ELwKOXhF9NqPqyUcF0OSVa/tKGFvFio= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772527383; c=relaxed/simple; bh=bwwvWXJ41lySPW4U+2fiYxqsXRKDlDWopfEyohTTtfg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=kP7wABz3t6spivgIcXpMW3T0NtNp861ycFm+V9DbFQ3D9YeXkbgyzR2BgItNz3EKonV5iyncMxTZ5+N/hN5WyLdqK5KNggaARLoX/+zzUnm1XbdXhZpaW8h0JwXePBimGayNApObSqHIi4nHWIkKSiW3Hg4KJCiQSh1+2ZJHgoA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=P4dEd0h0; arc=none smtp.client-ip=209.85.208.178 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="P4dEd0h0" Received: by mail-lj1-f178.google.com with SMTP id 38308e7fff4ca-3870902760cso88667181fa.3 for ; Tue, 03 Mar 2026 00:42:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1772527377; x=1773132177; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=dHYmVbbfQfaP2yj99KiW+/UkO3tcLecvvnP/w5d/X6U=; b=P4dEd0h0oSaTnk/BSYyDQNQjGzJpUww0XDD/jIJrHwdcamxsz1/i+Pwit7QcmllHzQ PlQyLE1Riik+MENxkEvTdNyy6bXa2XMmV2eyvnob7nMXraHFiZys//++m2ZOo+QeGW8V +e9396e1VOWeb8gT0kbOECmXJ/68HJTW9u/VNHixnl100jPuUN0PBQnPXWwFkbvtig0a Djxm2kzFlfNwGeGnpbHb+RBeIIqfh9KxOwQQHbrNcuQXYQoAJDHmMth3kx3kDLx5nrRs o4dwqpwgBhRcEkXnaE5H1ril5BfXLiAXfkxBBK6FhU0cZfR34jhPGRmvQgZBJvGbRBBG 7Fsw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772527377; x=1773132177; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=dHYmVbbfQfaP2yj99KiW+/UkO3tcLecvvnP/w5d/X6U=; b=ON+O1U3hxsTgd81AEgBCiKgKn9cT/8cMCQX6V5V7BGixlusyjmB/8++D78FHq1wCbb fT+s+/DcNLoxn/eEd43+HQEMSUyZOM/LsAA+evM/wvThsw7o2d+lFlq8Ciyaz8gIvSyc XR+pCMgKtp2aGXXlt2PK8/CPXuDk7lpkIxuTajVpJd5rArZ8pQfRhz7PIPamdq2MuPjv 1uU+CHdtsuOBUZ9NoHigryCNnw3+MigsYd3FIsa1OzbZtLMF7FdHdo8bg+zjiTpYjHfY TDT5crmJNr7Uw3Ce0+Usxba3izg6Jvmg6+nQdm/4fUX2x+6Gp2PQ5XX0wxMrWrAxJ5SD hqug== X-Forwarded-Encrypted: i=1; AJvYcCWEX9eDyij542nAfmMuljq1MARuscahQtfEyTggaXeoUZLYLMjJFMVGkSDQ3FLY/ix2YlUHlZLumJhGcg==@vger.kernel.org X-Gm-Message-State: AOJu0Yxg0mwzaqWzLM/yfKTOKJsoPE1oU+dcERE/LKYM8I/rjKclBSsU 2DWOKJ9U7uWR4cIfzhP1FQ5ckT2Xe/n8jP3VpyBsXextLyJ+/qPV9MbG X-Gm-Gg: ATEYQzyRTUQsi2z0GGpiz6+S6Q+38Su8vR4uONCc0wzEAFyNU9CuZLiv1flCLbE5g/6 7qHYv/Bdwbt4wtbStmm993iEzsjjZ6gMXng6sdn9FUvb7c7dnlZv1qSEFKT1iaPtbqUwSsVb+Hx wfEsNYgy0aZ08XsZdxdfDiNp4DMTYJhpgp/BX0DI5XjLD1SAMnOm0KsLxup+9yA0/OciSdL7mOQ KIe3YNrRtWIW3hZ5tQEVfYraS73foMmf4a+tYvXH+u3Vn4oRWxohySFjBnJNQpKBRVBgPFmaraZ E5UNkf/aVd/wBgw+PNbBUUIuXSH6JeHgc6hnV/Da9mVX8+/9EKv3RLUN89Ep4YMvgs2lmxY0R7J UPegu3eL+/VBvew3BQ5/RjTB6vjSlrQ3p+GgVHMPbyFcD62Uf7cyibxSBsq3Olsah7mOnzGbXXF ger9oEZHook+ti X-Received: by 2002:a2e:a106:0:b0:389:fb7f:3e0c with SMTP id 38308e7fff4ca-389ff15f371mr102458851fa.21.1772527377130; Tue, 03 Mar 2026 00:42:57 -0800 (PST) Received: from xeon ([188.163.112.72]) by smtp.gmail.com with ESMTPSA id 38308e7fff4ca-389f30227a9sm32599471fa.42.2026.03.03.00.42.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Mar 2026 00:42:56 -0800 (PST) From: Svyatoslav Ryhel To: Thierry Reding , Thierry Reding , Mikko Perttunen , David Airlie , Simona Vetter , Jonathan Hunter , Sowjanya Komatineni , Luca Ceresoli , Mauro Carvalho Chehab , Greg Kroah-Hartman , Hans Verkuil , Svyatoslav Ryhel Cc: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-tegra@vger.kernel.org, linux-media@vger.kernel.org, linux-staging@lists.linux.dev Subject: [PATCH v7 05/15] gpu: host1x: convert MIPI to use operation function pointers Date: Tue, 3 Mar 2026 10:42:28 +0200 Message-ID: <20260303084239.15007-6-clamor95@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260303084239.15007-1-clamor95@gmail.com> References: <20260303084239.15007-1-clamor95@gmail.com> Precedence: bulk X-Mailing-List: linux-media@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Convert existing MIPI code to use operation function pointers, a necessary step for supporting Tegra20/Tegra30 SoCs. All common MIPI configuration that is SoC-independent remains in mipi.c, while all SoC-specific code is moved to tegra114-mipi.c (The naming matches the first SoC generation with a dedicated calibration block). Shared structures and function calls are placed into tegra-mipi-cal.h. Tested-by: Luca Ceresoli # tegra20, parallel camera Signed-off-by: Svyatoslav Ryhel Acked-by: Mikko Perttunen --- drivers/gpu/drm/tegra/dsi.c | 1 + drivers/gpu/host1x/Makefile | 1 + drivers/gpu/host1x/mipi.c | 592 +++++------------------- drivers/gpu/host1x/tegra114-mipi.c | 483 +++++++++++++++++++ drivers/staging/media/tegra-video/csi.c | 1 + include/linux/host1x.h | 10 - include/linux/tegra-mipi-cal.h | 57 +++ 7 files changed, 666 insertions(+), 479 deletions(-) create mode 100644 drivers/gpu/host1x/tegra114-mipi.c create mode 100644 include/linux/tegra-mipi-cal.h diff --git a/drivers/gpu/drm/tegra/dsi.c b/drivers/gpu/drm/tegra/dsi.c index 2c5aefe9621a..7f25c50621c9 100644 --- a/drivers/gpu/drm/tegra/dsi.c +++ b/drivers/gpu/drm/tegra/dsi.c @@ -14,6 +14,7 @@ #include #include #include +#include #include