From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=205.220.168.131 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796083227; b=AND/9AaLWzCp5h7Op/A/U6boIr2hvYKc1Vq9aoURW2JVKIhNK/0CLuIMykYwgfFRRll5 Dd4Ku+z6j5xU8DETRJAEuqlpRVezgEPdwfiMHJ4jpK2cIjCHMhKPil6XiNGUxCGRsV/RV 8GvGVdHQu932iIMF83+2EFt/vlHViwVa1QOg1oywdARAGDP4FcUnrT6hUjrPsdcKhPJkE uuxnIDCbQwsOOQR36T4w18T8EqBUGNxVjQ7T5rmLuV/1vsKnKqN5NLhs6eP4uk28xTI54 Fw4sYD7Bjjojx+QimtSg86QCR6e4zqEX49Szo8XrWZVHrzJaSnx+0Lm0DeOTalHar9w== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796083227; h=DMARC-Filter:Received:DKIM-Signature:Received:Received: DKIM-Signature:X-Google-DKIM-Signature:X-Forwarded-Encrypted: X-Gm-Message-State:X-Gm-Gg:X-Received:X-Received:Received:From:Date: Subject:MIME-Version:Content-Type:Content-Transfer-Encoding: Message-Id:References:In-Reply-To:To:Cc:X-Mailer: X-Developer-Signature:X-Developer-Key:X-Proofpoint-Spam-Info: X-Authority-Analysis:X-Proofpoint-Spam-Details-Enc:X-Proofpoint-GUID: X-Proofpoint-ORIG-GUID:X-Proofpoint-Virus-Version: X-Proofpoint-Spam-Details; bh=esDncjNWNQL+FUEGTzl1ho/mJLypwVnQf99TVPdkyYo=; b=FGkIZDNUkMX256A6qtRlZd6+a9LpMlkENDhH4OnQzWqYDfN48t2D9FK/SmsbRIbG/n6p v0K9IKWvFcuAXG4KRIm5Vu00KFLZi0YlX6HmpzMWOk11s7OqBXS+LsiGpfX90v68vyrw7 iM1Id1/UDc6EZJc5Y9tFEb1DD7vZBAzG5txAXYOKHPZmqVqsIRlJtIB75SRvC6feP/2g2 VkPLk9Lp1kuET1s08JcUM+EkytDAGvh1iVr7y5yi8SnbseDk/UW/1XZx/BsFG8utKmh4t iGHlgHGgpuxO4saHvY8vJqKb5eqzCUOj0aUX1SFJoSokRlqn0xbcfxCIN98fpV9pNZQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass header.d=qualcomm.com header.i=@qualcomm.com header.a=rsa-sha256 header.s=qcppdkim1 header.b=RTy4nXcC; dkim=pass header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.a=rsa-sha256 header.s=google header.b=DfPKnbZw; arc=none smtp.remote-ip=205.220.168.131 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8FFE0606A337 for ; Tue, 1 Dec 2026 00:00:26 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 8FFE0606A337 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.a=rsa-sha256 header.s=qcppdkim1 header.b=RTy4nXcC; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.a=rsa-sha256 header.s=google header.b=DfPKnbZw Received: from pps.filterd (m0279865.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 6AUKQATW4082888 for ; Tue, 1 Dec 2026 00:00:26 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= esDncjNWNQL+FUEGTzl1ho/mJLypwVnQf99TVPdkyYo=; b=RTy4nXcCm4vjFV5i HxgjUOQqCj3HsVJraWCk5o23kPmYc7PKYOtaB0r4S4OTV99PdtosbbUSZ5n5aPI7 5gqLeLE6a4IVPMSJHWD5hkBdu2VDjzplq8jwei1qdxWafg7ZqO52KG4N258BymO1 to8Z5La+U1petDPc+1XSEhROhDW1UhGDpwQnR71ZB2yXQeyVPTkodFs1bejhPZiZ 5Hx0+GRXqPyfnuVDG4Hktu+f4F0cTKn/gdfVdzPY6Rbc0/EAV0ovafVhQwd8i7UA wwIm4QFvovI7dIOq2i8FEnF1i0e7f9Oh7LXusJotKQkSKcfWrqQStR4JErm03D5P mehvXw== Received: from mail-dy1-f198.google.com (mail-dy1-f198.google.com [74.125.82.198]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4j98udar8d-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Tue, 01 Dec 2026 00:00:25 +0000 (GMT) Received: by mail-dy1-f198.google.com with SMTP id 5a478bee46e88-38711d03e80so192477eec.2 for ; Mon, 30 Nov 2026 16:00:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1796083225; x=1796688025; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=esDncjNWNQL+FUEGTzl1ho/mJLypwVnQf99TVPdkyYo=; b=DfPKnbZwMf4I5Qmt2EiacbjVuiE9UWyQveaFDeXbU49553zG4FAuBTgRRH9cqYfcX8 I1JjQsg0IioDuVQfBP8rLL2YRWUUeWa2GUQdIHQpYl/DYBWNKB2Hc/2LE0xtgnyHNC3q esMIsNrbFJs1Upko6ZR8yOIcSHyDCBYF8hEg7U5VP17pW4tig8Zk0/ENsVIaSshhFx/0 tcTAKwJicg9jFSBteO8dwDI1ZmRxrNyw8g0yZeB2xreVmFee720tOMJLN42l2oiokbCZ YVKS8wvWsnhSLmFs+3uxQogtm8favgx8X/cncFThZrMzdPkhUQVRI5gabRfn/c4fg+5f f+Tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796083225; x=1796688025; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=esDncjNWNQL+FUEGTzl1ho/mJLypwVnQf99TVPdkyYo=; b=he/AwA7D+ah2deI975QFnfvZT1Dk1vxfO5zh4AmxcxA65678QFUmhSMMTGO12h2Hdx IJps7i6P624UCq93ZcNIilX7z0/EIZfmc2wGP81dIbEbclnhkHMsLGsjIMRBTei2fN3S jes34OGWdRbwU6s9X81Fuyt3Vny0H1o7aZn96tczA3D631EFNAzSR+CWydqkJWpOWPYr oRFIrMJXXbrFpJYfpga8a5/qqqtzMrVVt/FjvqMhXAp5yYi37RBCbDldki5Y7aeBd2Rk mBLUMKxjdrUCkQr+dwkrv/pQiqpcJv8jkmxhb/JHoJzmYhZSvceI9Sj6e5z21fgraloE yKLA== X-Forwarded-Encrypted: i=1; AL+hErGDazkR0puGF36o2LJy1WHzvjlr8Du7wdJtGR6GpoSVyt1f7bn8INkzo1RWx0MK1wsKk4TK9Et7tXR65pM=@vger.kernel.org X-Gm-Message-State: APuU4Z+8wuaF8jig9pdXo4lNm70r/PlZQ7khyugjZDooRiNNOf/JDSMp qNRI1u9pfnGjRm0b/yX1kq5NcoPgjSI05drH0fcGy7iujRXvr/LHQ+Xqsz1h5S5/UwBv6hGW3qn wNTaudd5LZGra9Z+LYi/75Ww+rCkSirwu08wBJgwLBRk1zZFYMjUM/MaGy0dFfzxMPXk= X-Gm-Gg: AZFdTZenZy9GpEXvHhV/I6KQld2fNFbU1GABmUyXLhcFQSgHfV4K7EBwwEW/ENZJuhZ VLQsjPzyKjdeaZbUtECuIIU3WAWfHApfMsnxPdkO8EgNRiS0YzIq6vQthistorYC5641fp+LekZ UjM5vulHPfKHArttkt9mrOdDtMdIJwqqJ8FvC7h7GsBaRUNXXWwn2NDv1GxhHZ28XiKtw8sG7lo dfKtfHmvNtZ0UKnnkntoW+yMxz7FXbJWQObSYBGaSlgQWdnPJd5ONqD6db1VfC++qWDCT8tlNpW PKbidB49xrcsGxd72xl4zMtzixhrFaqsN68Wq4XKr1L3+1rqi0C/AaxhZaUasqDODC4IMEPageX vurL9mdaCGTneVuFu90PFrvGRR0sUyjKKLbJLTSlMLCcTB6iybRnMwItB73hiJElXRWORIJGqU1 MCnpvfiAy6HNPnak9wnuFHAyv3J7nkHJV6QA== X-Received: by 2002:a05:7301:18a6:b0:36d:cd5d:d809 with SMTP id 5a478bee46e88-3856e84e391mr54189143eec.1.1796083223180; Mon, 30 Nov 2026 16:00:23 -0800 (PST) X-Received: by 2002:a05:7301:18a6:b0:36d:cd5d:d809 with SMTP id 5a478bee46e88-3856e84e391mr54189058eec.1.1796083222313; Mon, 30 Nov 2026 16:00:22 -0800 (PST) Received: from gu-dmadival-lv.qualcomm.com (Global_NAT1.qualcomm.com. [129.46.96.20]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-385c6830815sm94064373eec.20.2026.11.30.16.00.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Nov 2026 16:00:21 -0800 (PST) From: Deepa Guthyappa Madivalara Date: Mon, 30 Nov 2026 16:00:17 -0800 Subject: [PATCH v3 2/3] media: iris: add mahua platform data and enable qcom,mahua-iris X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20261130-mahua_iris_enable-v3-2-311fdb15a11e@oss.qualcomm.com> References: <20261130-mahua_iris_enable-v3-0-311fdb15a11e@oss.qualcomm.com> In-Reply-To: <20261130-mahua_iris_enable-v3-0-311fdb15a11e@oss.qualcomm.com> To: Vikash Garodia , Dikshita Agarwal , Abhinav Kumar , Bryan O'Donoghue , Mauro Carvalho Chehab , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Abel Vesa Cc: linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Deepa Guthyappa Madivalara X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1796083218; l=7954; i=deepa.madivalara@oss.qualcomm.com; s=20250814; h=from:subject:message-id; bh=m73ySzdA9FnzAjPI5jh0sJ9CpBEKNdD01Z41v/VEBWc=; b=JPd0KbFEZrc7qnrBSN/rdcP7Hq9RpXSQ7NNYeEeveH2FK4+hP8dUBBNXhvNmjD5OmHQKbpOLY z/CI/uzKl1cB+9ARgdrklF6ZXAySWsai3HuT2CyNSYWz6VlPLsuyZww X-Developer-Key: i=deepa.madivalara@oss.qualcomm.com; a=ed25519; pk=MOEXgyokievn+bgpHdS6Ixh/KQYyS90z2mqIbQ822FQ= X-Proofpoint-Spam-Info: AW1haW4tMjYxMTMwMDA5NSBTYWx0ZWRfXwhfYjTPNcFxl Swt4lAF9IemXcxIMKJzDzldRpNzJRF3GRSjdZYhjdDDCHMW36IL9cgCyL2w4nBpZ+Tsr4TavZ96 AhwKSjsDJwG+1bG2Knpx/BfU4+JJu2A= X-Authority-Analysis: v=2.4 cv=edqo7LEH c=1 sm=1 tr=0 ts=6b0e0e19 cx=c_pps a=wEP8DlPgTf/vqF+yE6f9lg==:117 a=ouPCqIW2jiPt+lZRy3xVPw==:17 a=IkcTkHD0fZMA:10 a=pUM-KoujPXoA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=Um2Pa8k9VHT-vaBCBUpS:22 a=EUspDBNiAAAA:8 a=qMmPMGTIe4Jfwz3yK_QA:9 a=QEXdDO2ut3YA:10 a=bBxd6f-gb0O0v-kibOvt:22 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYxMTMwMDA5NSBTYWx0ZWRfX0ZF1aFmsewts +9e0F67OkAUt7izRWd2JsQTDCZTwTpVi6zSk4Hp8ViYuAoUhoqJqdcALtFyUrRwnD9rNhNc6DSj PAHTYXqxWMIlP9qiDNkhD8FQ/0zqhrwJuUT53+knibDZIctTaHxwToY7CyKA2rcwgpG2AQLrhja hOMGFC1WcICezJT9j8bBUY3DfPsdVJ+Y61bgls8HUgQrFefrj+MQYYQAK1Ra4qXo+yCoSAEC15U grHDNfXzirS9J60ewgP+90Iq29lgJnL5/kFlB+CkhZxCbRzcnFuVhaJ9mfPrxeNMjpf9Bp37jRN Whph7g7WYoUsixEnADbKeyOM5ozmTGvNaVwXq58Ldc7Qsj7x8Ktyi23wnKrkTkfyiSleDCzmHsq kLXWgvFWPg04gd9ltP5KdCqERDCXeIGIBODjukh+S3bAH/fqLa85MJV95tRO7FHMOslFq4/IoUq 4HdcRhrMN2Rg4dlJNeA== X-Proofpoint-GUID: 79L12YxPwNGQFUEOwqa--0yg3L5rPHPL X-Proofpoint-ORIG-GUID: 79L12YxPwNGQFUEOwqa--0yg3L5rPHPL X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1176,Hydra:6.1.138,FMLib:17.12.100.49 definitions=2026-11-30_05,2026-11-30_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 impostorscore=0 bulkscore=0 lowpriorityscore=0 malwarescore=0 phishscore=0 spamscore=0 adultscore=0 suspectscore=0 priorityscore=1501 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2611040001 definitions=main-2611300095 Add qcom,mahua-iris compatible to initialize the hardware and necessary Mahua platform data describing the needed clock resets and powerdomain tables only for one core, vcodec0. Most of the data is leveraged from Glymur as they are the same Iris variant. Firmware, vpu ops, buffer sizes are the same as for Glymur. Signed-off-by: Deepa Guthyappa Madivalara --- drivers/media/platform/qcom/iris/Makefile | 1 + .../platform/qcom/iris/iris_platform_common.h | 1 + .../media/platform/qcom/iris/iris_platform_mahua.c | 44 ++++++++++++++++++++++ .../media/platform/qcom/iris/iris_platform_mahua.h | 14 +++++++ .../media/platform/qcom/iris/iris_platform_vpu3x.c | 33 ++++++++++++++++ drivers/media/platform/qcom/iris/iris_probe.c | 4 ++ drivers/media/platform/qcom/iris/iris_vpu3x.c | 10 +++++ 7 files changed, 107 insertions(+) diff --git a/drivers/media/platform/qcom/iris/Makefile b/drivers/media/platform/qcom/iris/Makefile index 4a70e124e75f6ea3f46cd33021dcc1f3cd7bee99..e9dbc0c94a1b4797b56917917cb6bc5c43c670ad 100644 --- a/drivers/media/platform/qcom/iris/Makefile +++ b/drivers/media/platform/qcom/iris/Makefile @@ -13,6 +13,7 @@ qcom-iris-objs += iris_buffer.o \ iris_hfi_gen2_response.o \ iris_hfi_queue.o \ iris_platform_glymur.o \ + iris_platform_mahua.o \ iris_platform_vpu2.o \ iris_platform_vpu3x.o \ iris_platform_vpu_ar50lt.o \ diff --git a/drivers/media/platform/qcom/iris/iris_platform_common.h b/drivers/media/platform/qcom/iris/iris_platform_common.h index 1eb8f33a7564f9cbcab6d2eaf80afb50af597e2e..a68f49ed59feb802eac6be115991db834f2c81b9 100644 --- a/drivers/media/platform/qcom/iris/iris_platform_common.h +++ b/drivers/media/platform/qcom/iris/iris_platform_common.h @@ -67,6 +67,7 @@ extern const struct platform_inst_slice_caps iris_vpu2_vpu3x_slice_caps; extern const struct platform_inst_slice_caps iris_ar50lt_slice_caps; extern const struct iris_platform_data glymur_data; +extern const struct iris_platform_data mahua_data; extern const struct iris_platform_data milos_data; extern const struct iris_platform_data qcm2290_data; extern const struct iris_platform_data qcs8300_data; diff --git a/drivers/media/platform/qcom/iris/iris_platform_mahua.c b/drivers/media/platform/qcom/iris/iris_platform_mahua.c new file mode 100644 index 0000000000000000000000000000000000000000..14b085426ac29cf69824d1d0da142c026266a0bb --- /dev/null +++ b/drivers/media/platform/qcom/iris/iris_platform_mahua.c @@ -0,0 +1,44 @@ +// SPDX-License-Identifier: GPL-2.0-only +/* + * Copyright (c) Qualcomm Innovation Center, Inc. All rights reserved. + */ + +#include "iris_core.h" +#include "iris_platform_common.h" + +const struct iris_power_domain_data iris_mahua_ctrl_data = { + .pd_names = (const char *[]) { + "venus", + }, + .pd_cnt = 1, + .clk_names = (const char *[]) { + "core_iface", "core_freerun", "core", + }, + .clk_cnt = 3, +}; + +const struct iris_power_domain_data iris_mahua_vcodec_data[] = { + { + .pd_names = (const char *[]) { + "vcodec0", + }, + .pd_cnt = 1, + .clk_names = (const char *[]) { + "vcodec0_iface", "vcodec0_core_freerun", "vcodec0_core", + }, + .clk_cnt = 3, + }, +}; + +const char * const iris_mahua_clk_reset_table[] = { + "core_bus", + "vcodec0_bus", + "core", + "vcodec0_core", +}; + +const char * const iris_mahua_opp_clk_table[] = { + "vcodec0_core", + "core", + NULL, +}; diff --git a/drivers/media/platform/qcom/iris/iris_platform_mahua.h b/drivers/media/platform/qcom/iris/iris_platform_mahua.h new file mode 100644 index 0000000000000000000000000000000000000000..fa30f33c5b03b515fa57e52a1b7413406cf5823e --- /dev/null +++ b/drivers/media/platform/qcom/iris/iris_platform_mahua.h @@ -0,0 +1,14 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +/* + * Copyright (c) Qualcomm Innovation Center, Inc. All rights reserved. + */ + +#ifndef __IRIS_PLATFORM_MAHUA_H__ +#define __IRIS_PLATFORM_MAHUA_H__ + +extern const struct iris_power_domain_data iris_mahua_ctrl_data; +extern const struct iris_power_domain_data iris_mahua_vcodec_data[1]; +extern const char * const iris_mahua_clk_reset_table[4]; +extern const char * const iris_mahua_opp_clk_table[2]; + +#endif /* __IRIS_PLATFORM_MAHUA_H__ */ diff --git a/drivers/media/platform/qcom/iris/iris_platform_vpu3x.c b/drivers/media/platform/qcom/iris/iris_platform_vpu3x.c index 6ed4de2d15ceca24d018628ec55b2cb3c42b3168..1962d27c181404998c4f31fbb7626bc9f0cc74bc 100644 --- a/drivers/media/platform/qcom/iris/iris_platform_vpu3x.c +++ b/drivers/media/platform/qcom/iris/iris_platform_vpu3x.c @@ -13,6 +13,7 @@ #include "iris_vpu_common.h" #include "iris_platform_glymur.h" +#include "iris_platform_mahua.h" #include "iris_platform_qcs8300.h" #include "iris_platform_sm8550.h" #include "iris_platform_sm8650.h" @@ -120,6 +121,38 @@ const struct iris_platform_data glymur_data = { .max_core_mbps = ((8192 * 4320) / 256) * 60, }; +/* + * Shares most of Glymur data except, num_cores + */ +const struct iris_platform_data mahua_data = { + .firmware_desc_gen2 = &iris_vpu36_p4_s7_gen2_desc, + .vpu_ops = &iris_vpu36_ops, + .icc_tbl = iris_icc_info_vpu3x, + .icc_tbl_size = ARRAY_SIZE(iris_icc_info_vpu3x), + .clk_rst_tbl = iris_mahua_clk_reset_table, + .clk_rst_tbl_size = ARRAY_SIZE(iris_mahua_clk_reset_table), + .bw_tbl_dec = iris_bw_table_dec_vpu3x, + .bw_tbl_dec_size = ARRAY_SIZE(iris_bw_table_dec_vpu3x), + .ctrl_data = &iris_mahua_ctrl_data, + .vcodec_data = iris_mahua_vcodec_data, + .opp_pd_tbl = iris_opp_pd_table_vpu3x, + .opp_pd_tbl_size = ARRAY_SIZE(iris_opp_pd_table_vpu3x), + .opp_clk_tbl = iris_mahua_opp_clk_table, + /* Upper bound of DMA address range */ + .dma_mask = 0xffe00000 - 1, + .inst_iris_fmts = iris_fmts_vpu3x_dec, + .inst_iris_fmts_size = ARRAY_SIZE(iris_fmts_vpu3x_dec), + .inst_caps = &platform_inst_cap_sm8550, + .slice_caps = &iris_vpu2_vpu3x_slice_caps, + .tz_cp_config_data = iris_glymur_tz_cp_config, + .tz_cp_config_data_size = ARRAY_SIZE(iris_glymur_tz_cp_config), + .num_vpp_pipe = 4, + .max_session_count = 16, + .num_cores = 1, + .max_core_mbpf = NUM_MBS_8K * 2, + .max_core_mbps = ((7680 * 4320) / 256) * 60, +}; + /* * Shares most of SM8550 data except: * - inst_caps to platform_inst_cap_qcs8300 diff --git a/drivers/media/platform/qcom/iris/iris_probe.c b/drivers/media/platform/qcom/iris/iris_probe.c index f5e5044ec3be01c23eb9fdcf54d144b91b03fc28..e784e3e5c2b6309450d0e899d1e46b8e301c7055 100644 --- a/drivers/media/platform/qcom/iris/iris_probe.c +++ b/drivers/media/platform/qcom/iris/iris_probe.c @@ -643,6 +643,10 @@ static const struct of_device_id iris_dt_match[] = { .compatible = "qcom,glymur-iris", .data = &glymur_data, }, + { + .compatible = "qcom,mahua-iris", + .data = &mahua_data, + }, { .compatible = "qcom,milos-iris", .data = &milos_data, diff --git a/drivers/media/platform/qcom/iris/iris_vpu3x.c b/drivers/media/platform/qcom/iris/iris_vpu3x.c index f7260eda7f459ed371b5579a3e8582c1691e4190..93bc222629d4aa6a809fd2785d82098a50b48b05 100644 --- a/drivers/media/platform/qcom/iris/iris_vpu3x.c +++ b/drivers/media/platform/qcom/iris/iris_vpu3x.c @@ -365,6 +365,16 @@ static int iris_vpu36_check_core_load(struct iris_inst *inst, bool mbpf) new_load = mbpf ? iris_get_mbpf(inst) : iris_get_mbps(inst); select_core0 = core0_load + new_load <= max_load && core0_session_cnt < max_session_cnt; + + if (platform_data->num_cores == 1) { + if (select_core0) { + inst->core_id = IRIS_VCODEC0; + return 0; + } + + return -ENOMEM; + } + select_core1 = core1_load + new_load <= max_load && core1_session_cnt < max_session_cnt; if (select_core0 && select_core1) -- 2.34.1