From patchwork Fri Oct 11 10:17:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "G.N. Zhou \(OSS\)" X-Patchwork-Id: 834821 Received: from EUR03-VI1-obe.outbound.protection.outlook.com (mail-vi1eur03on2076.outbound.protection.outlook.com [40.107.103.76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B5EA820B20E; Fri, 11 Oct 2024 10:17:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.103.76 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728641836; cv=fail; b=ty8D4PKt6GRzV25eGOjcLWG5mU/AHO1aMrnLO6C2WJwyFgcAZYFJcFTfYObvR6DKJK6oo/yPc+XDfyV6bGOD5zq9Fzi1LWXJD2rYoYEx/+tSmb3TNEZZwaDxgZNfZbRwW34xFhnRaXUEtfASpz3guxHekTHbpVb2obcJgAILeqU= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728641836; c=relaxed/simple; bh=oN5mFu9o8KpzLDabdrO3gph7t+OKJP/d5E0tZaBBu18=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=MwMT4Tt+D31ICHbIndBU3a9g+i6Ag116oPk9fNBgW4cR1SbqMpZ906Q0ay8Rugp0FG35zh7ye/Cs6y7JATuIZmgMNKN/jKcCkb7Vd2B0X9vTUpIwhhv/v1vsn6rMARza+85LiIS2xDpr6neBnzOZuybTgT6/U/dP97Dac0he6uE= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oss.nxp.com; spf=pass smtp.mailfrom=oss.nxp.com; dkim=pass (2048-bit key) header.d=NXP1.onmicrosoft.com header.i=@NXP1.onmicrosoft.com header.b=jlrKm41I; arc=fail smtp.client-ip=40.107.103.76 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oss.nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=NXP1.onmicrosoft.com header.i=@NXP1.onmicrosoft.com header.b="jlrKm41I" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=C3wNbi9Rn3fuW0SPgvmd8yz2al3HM54IsQB44SST+a2p7S8ZqFhUzwmkIA08V+6XjoyfYMQzsn3SvxUyyEmbcSoDEL8Njplok/8/YH4JYjvC1y/69xUkmrzN4DONb9iYh5ZNIYDXw6OuXQibGwJorr/Lrj7I3+vcA45iVSLnLApd6WwdjLeb0ncPsyJtMjKMw5rPIl00IJIsYh4YSWnzLSUh5HzhFm866VghkM+R1T/RWaVfFsQT/xcRTLfrDo0aTlIBMDht1T5Qr4wIAG+bbR/XzFQEf0vYjNNIHgPSaMfh1J9dHCpY6JO3QqS+jsaV/IdVi78bMnSWp3maKYZI3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=i3DD74N0aDT/Zn+7smF/wnfhSjcLvgLlw6FInG+HZQ0=; b=OPESD+vNJO/cPeMnkGx1gI/oUps/g1abMSWrs53bEeV0pZPH+HqbFxx2xGeComcHhT5s9wPZUqy/4qu3BQvOHvfBpQ/N3yJekvBpyfOwKKta3KTaFwTAJVpYsdb0GpkzA5ptqZItSkTaRX7k5uLY0nxy3ewPNz3UfMzcKW4pJqEgjCtxd8bI5bFCz8uyDNrpqLvmjrtiNpPf5TuzaB36kk767UoPnUE/CM5Ls7Z5BQmuTURI1OHCadV2QElDOLQG8Sbmafy+gDhKlI16WWugNfgTbIR/KUIgaGxHfDkVxxN8avVT73NnzT+LFKKojS25CCmPKqpaObY+fm8fvuWu5w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector1-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=i3DD74N0aDT/Zn+7smF/wnfhSjcLvgLlw6FInG+HZQ0=; b=jlrKm41IBlXl47xDCpe/0vuOY9/PNiY17csxXoy/xWcYFv4zjHcOdH1w8czwCCyi7nTPaT3ti/ajF9Db56rrCqUu519xref7DjfDcHSXqcj6MHAeEwN8rJ0pgtCtx6BvUyVzOC2Q0QfLjS1CcowysGaJKAWnTwYx58FMDD+RnBu20S1G7b9J9XgsUk/KvaLQVNfMhLUXBu+q0jY08CFriW/mlPdQMSCDhS7vKdlyZ2xYDdo1MSq/jW2VNVaROXODC+6GloRp6/R0Vf5ESQnrFbISqVyArQa6Bj9lwC9amEzzK7TFh/EpWIDmRUl44lO5tlDPllzJt1DInasJZmCG+w== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=oss.nxp.com; Received: from AS8PR04MB9080.eurprd04.prod.outlook.com (2603:10a6:20b:447::16) by AS8PR04MB8852.eurprd04.prod.outlook.com (2603:10a6:20b:42f::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8048.18; Fri, 11 Oct 2024 10:17:10 +0000 Received: from AS8PR04MB9080.eurprd04.prod.outlook.com ([fe80::93bd:316b:682f:5e59]) by AS8PR04MB9080.eurprd04.prod.outlook.com ([fe80::93bd:316b:682f:5e59%6]) with mapi id 15.20.8048.018; Fri, 11 Oct 2024 10:17:10 +0000 From: guoniu.zhou@oss.nxp.com To: linux-media@vger.kernel.org Cc: laurent.pinchart@ideasonboard.com, jacopo@jmondi.org, mchehab@kernel.org, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, shawnguo@kernel.org, s.hauer@pengutronix.de, kernel@pengutronix.d, festevam@gmail.com, devicetree@vger.kernel.org, imx@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH 1/2] media: nxp: imx8-isi: Add i.MX8ULP support Date: Fri, 11 Oct 2024 18:17:12 +0800 Message-Id: <20241011101711.704226-2-guoniu.zhou@oss.nxp.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241011101711.704226-1-guoniu.zhou@oss.nxp.com> References: <20241011101711.704226-1-guoniu.zhou@oss.nxp.com> X-ClientProxiedBy: SG2PR02CA0070.apcprd02.prod.outlook.com (2603:1096:4:54::34) To AS8PR04MB9080.eurprd04.prod.outlook.com (2603:10a6:20b:447::16) Precedence: bulk X-Mailing-List: linux-media@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AS8PR04MB9080:EE_|AS8PR04MB8852:EE_ X-MS-Office365-Filtering-Correlation-Id: 5d8ffece-4684-47a3-4ea6-08dce9ddddfb X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-LD-Processed: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635,ExtAddr X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|7416014|366016|376014|1800799024|52116014|38350700014; X-Microsoft-Antispam-Message-Info: =?utf-8?q?ZtDgUjofcEhpV4w520VpGO30868jHj5?= =?utf-8?q?sMVT6lXw0xOSBFh64RpzC/iwpeWt045BeE9LNNI9y37yfYXDIPc0X3Jqpn/70SWHd?= =?utf-8?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C7YV/DGmXpRbYJ0c/YcgM5A6ItXsCby2Eyvj2YHbZF8snuVD7X34Jeg?= =?utf-8?q?hLWsfjwyOspa5dhrv/dQlsXUtYhSFDtjORmVMgU25iEb8472/YhxfbVG6mF/TjZSB?= =?utf-8?q?eLtQdNdpDlKJtSNigoI5BaY7FwajIhfBm2PL0yYt7LK8sNtZx3GrChpAzQaeKpqEl?= =?utf-8?q?tqUEFcNkghiSP0OvoCaXoGtfMFzGUJbR9Pff7oqh5SFVuVrjqEj17EMcq9qtazo+S?= =?utf-8?q?wohYxfJoIy9YFogojuHruEByfr5DePXbnp9MDyHQ2ZD+8v7f3T2S64eRqApb79aH8?= =?utf-8?q?ANCSD1r5u2pWnziPEnhVZ9M67BIYgHAKxxQ=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AS8PR04MB9080.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(7416014)(366016)(376014)(1800799024)(52116014)(38350700014); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?LL4Q7mb0Po5oemKu1guukEUnenCh?= =?utf-8?q?lPNQVvi5A6oqyKfDXYUs0SN4dwRNNJ6oEejCFdSr2A7dJ/e7tE4bBnYuJqwFrVqPx?= =?utf-8?q?iOS18mx0/3hPndtpR3PO8uNSnPUCwnY316CchKcq/d9xJPdd/TzXtnY4WW9wxk47C?= =?utf-8?q?3Cb3xqI+oQ0UFvITSYm4Ytz7aPzYh6NFTQco46NnZd96ei12nIdZaiTcK4MTZlMmk?= =?utf-8?q?Vpngyf3zTfqr3zzccBK8HSxGGE+wYMgC439ED/MoFnJugcZBcMasJKdELNCUvI7Cn?= =?utf-8?q?YQP2A91Ro7zmFkVA8lqdbCJkAV521kTxM3+/3BkLzaovbujyoPCenYy4lRmGdC9i1?= =?utf-8?q?Jzk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q?+xsnAZhKTymRCTqTgKTCpOyRBzRyloJGh+zVD8NRgD3EhakE5CmCrqcCtmR69Niwc?= =?utf-8?q?F+fle2tWFS7q2FLWGkkZYKo48+swwqOoyai6fbB/dB/26HPJ51Epoiv+4S2CnVjOR?= =?utf-8?q?/JzbZkdGje0cIhKaUzDFwEZv0EajC5UQusHytttPJadl9ZLvVrvgHMq8cbQVdGBkv?= =?utf-8?q?PpG2Hw8KMHLZIUrYscrh2GO7caFaKPJxL6EbhHLH6YxhXc2Ytxjumx9GCEca4M8xv?= =?utf-8?q?676unOYoCBW73BZzdErINI0/SAu+D1m5IQK1AmOplDrZ7ImKGvVMYulvnt1a5KIrU?= =?utf-8?q?FCEkPjyH/cDZ?= X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5d8ffece-4684-47a3-4ea6-08dce9ddddfb X-MS-Exchange-CrossTenant-AuthSource: AS8PR04MB9080.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Oct 2024 10:17:10.3681 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: +PmPVXLNMha71unFPIaPzzr1t58fvn1Yw61NRN5X5O6KGiJ0d+dWUjud3E05+YVxCi20Gh0H+SJjorGWhPnr1w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR04MB8852 From: "Guoniu.zhou" Add ISI support for i.MX8ULP. Signed-off-by: Guoniu.zhou --- .../platform/nxp/imx8-isi/imx8-isi-core.c | 18 ++++++++++++++++++ .../platform/nxp/imx8-isi/imx8-isi-core.h | 1 + 2 files changed, 19 insertions(+) diff --git a/drivers/media/platform/nxp/imx8-isi/imx8-isi-core.c b/drivers/media/platform/nxp/imx8-isi/imx8-isi-core.c index c2013995049c..f5d076d7f50b 100644 --- a/drivers/media/platform/nxp/imx8-isi/imx8-isi-core.c +++ b/drivers/media/platform/nxp/imx8-isi/imx8-isi-core.c @@ -279,6 +279,10 @@ static const struct clk_bulk_data mxc_imx8mn_clks[] = { { .id = "apb" }, }; +static const struct clk_bulk_data mxc_imx8ulp_clks[] = { + { .id = "per" }, +}; + static const struct mxc_isi_plat_data mxc_imx8mn_data = { .model = MXC_ISI_IMX8MN, .num_ports = 1, @@ -307,6 +311,19 @@ static const struct mxc_isi_plat_data mxc_imx8mp_data = { .has_36bit_dma = true, }; +static const struct mxc_isi_plat_data mxc_imx8ulp_data = { + .model = MXC_ISI_IMX8ULP, + .num_ports = 1, + .num_channels = 1, + .reg_offset = 0x0, + .ier_reg = &mxc_imx8_isi_ier_v2, + .set_thd = &mxc_imx8_isi_thd_v1, + .clks = mxc_imx8ulp_clks, + .num_clks = ARRAY_SIZE(mxc_imx8ulp_clks), + .buf_active_reverse = true, + .has_36bit_dma = false, +}; + static const struct mxc_isi_plat_data mxc_imx93_data = { .model = MXC_ISI_IMX93, .num_ports = 1, @@ -528,6 +545,7 @@ static void mxc_isi_remove(struct platform_device *pdev) static const struct of_device_id mxc_isi_of_match[] = { { .compatible = "fsl,imx8mn-isi", .data = &mxc_imx8mn_data }, { .compatible = "fsl,imx8mp-isi", .data = &mxc_imx8mp_data }, + { .compatible = "fsl,imx8ulp-isi", .data = &mxc_imx8ulp_data }, { .compatible = "fsl,imx93-isi", .data = &mxc_imx93_data }, { /* sentinel */ }, }; diff --git a/drivers/media/platform/nxp/imx8-isi/imx8-isi-core.h b/drivers/media/platform/nxp/imx8-isi/imx8-isi-core.h index 2810ebe9b5f7..9c7fe9e5f941 100644 --- a/drivers/media/platform/nxp/imx8-isi/imx8-isi-core.h +++ b/drivers/media/platform/nxp/imx8-isi/imx8-isi-core.h @@ -158,6 +158,7 @@ struct mxc_gasket_ops { enum model { MXC_ISI_IMX8MN, MXC_ISI_IMX8MP, + MXC_ISI_IMX8ULP, MXC_ISI_IMX93, };