From patchwork Tue Apr 30 15:30:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marc Gonzalez X-Patchwork-Id: 13649550 Received: from mail-wm1-f43.google.com (mail-wm1-f43.google.com [209.85.128.43]) (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 5D5F9143755 for ; Tue, 30 Apr 2024 15:35:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.43 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714491317; cv=none; b=P7kh0+2hVcixGBW7lr5F0qESWlp/gBL0g3kKdFEwh8IAUDJY5lrXvJR9CAH11ZA+Ze6g8SLVKXyhBGW0AoPzao611pmo+ZFj0mBqGLRg/9JYlba/b63z1ZbICU7o9S7L3yGqRbwghgAHLqsGfyKjRBTc1WhHlN18pvL7ZGEqLcE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714491317; c=relaxed/simple; bh=mwnvfTHxI+WM3M5fTYL+QVR5JSOESE1VGRRnr4BsCxU=; h=Message-ID:Date:MIME-Version:Subject:From:To:Cc:References: In-Reply-To:Content-Type; b=uH/vL5kD/4rKkHVJ83yZ34J2gvvc0I5a3jpC0wqCTmqAZXZQaAgDujpE7rVfyzVZNxjydVKBOTo1Y+Pqky5+R8JzKx8blz2jSdXIJDDHJXaYcG7B4Id5RHA9Onw1Kl42GC5XCKxjIj1YpT+313uSFBWMsBb9nhC5f8VZV/FGbEk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=freebox.fr; spf=pass smtp.mailfrom=freebox.fr; dkim=pass (2048-bit key) header.d=freebox-fr.20230601.gappssmtp.com header.i=@freebox-fr.20230601.gappssmtp.com header.b=A34xbSPz; arc=none smtp.client-ip=209.85.128.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=freebox.fr Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=freebox.fr Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=freebox-fr.20230601.gappssmtp.com header.i=@freebox-fr.20230601.gappssmtp.com header.b="A34xbSPz" Received: by mail-wm1-f43.google.com with SMTP id 5b1f17b1804b1-41bab13ca80so29415355e9.0 for ; Tue, 30 Apr 2024 08:35:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebox-fr.20230601.gappssmtp.com; s=20230601; t=1714491313; x=1715096113; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:from:subject:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=/hovZS8BlASlfNj4coZ1dMwGGp6FnU0h8KsE6yg3+Ow=; b=A34xbSPzyhC3ekLZQ/OnDkSUYjCDB0x4XUgBW5sSvyOL+rW8UJ5qU4bFcb5VcI2cLj WJEm0MoHKctCLFVZysJWsY6jRvj4c1WNaw6TswVBhYCM8FIcWQjD9LoYf/4dRoP3ljKu itrV6teltRmXoPx6jZrBM0jggFZpbcuIDRIVOmW306k4ut0SYZBVXfj//JQ0XMPYFgFX /YyhWfMDUPgtfwCRYvR9kN5ixEGXZ0P3+ZjaqLgwEWdEKPHc7Op4YnjebrdDbUBUJlJU K77rVaMycjvlNhJ0XIUaIHr4ZPFSALkhLiRXYjaNiOAGy20P4P3y/hlVg/0jigb4VUUw Td/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714491313; x=1715096113; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:from:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=/hovZS8BlASlfNj4coZ1dMwGGp6FnU0h8KsE6yg3+Ow=; b=IfiTrAaaIIQI9Sw+k+pRY9MzFeEjqRA4kN5sCmR26odkTUtolA8bca7lhkhEP2hmwd dgfq5oToVVsNazfLkdMrS/qrkckZZqMQrnsKurUUdLCvD6FflnNxR1EK8n24jZ6QS9ww lLwZepcyX+62UjB9g7f4dxKG790me1IzLQgnKC3X97RfsGyz1h7aWQ3phf6i8WyoS66k TYpkftQMeiBMBih0oicqIiROfIwSzCBPRm4ITJAaaHL0KfPKQ7eoKjcw+/qiO6C/MS08 L/EikkxpUJq03C2Xy2IVsd87/XGGjZG4dVKOuQmg85/Dm5kysH8dhaTatbzQY/svWXAN OpIQ== X-Forwarded-Encrypted: i=1; AJvYcCU8Zl9zo1URjHVb8e0caTJxjH3Td/BZJ/aVrwP+v1rtGigKbZIKo5qc0daXBMPjhXFUB6nqMdc8u/fD6c8rlkxeQ+s2C2zJmcm9UXM= X-Gm-Message-State: AOJu0Yyx1sGTFYT5Ca+1XWE68GfbSTBM39FDVH3HRKTe+pnPGui1ZoK1 xQlacBPnSHNP5WSeGyWvtXGigc3Ge6SFyQgK6X+3PwM1KcLk3bKXnuxUiSR18kk= X-Google-Smtp-Source: AGHT+IF+tKSffkAZmeUiRinjn6rsXwKDIGTeuYhVOb04lxk3/+aDTHyFXmft2n3g/qbqEthfB7KQAQ== X-Received: by 2002:a05:600c:3b17:b0:41a:c592:64ff with SMTP id m23-20020a05600c3b1700b0041ac59264ffmr12659980wms.35.1714491313365; Tue, 30 Apr 2024 08:35:13 -0700 (PDT) Received: from [192.168.108.81] (freebox.vlq16.iliad.fr. [213.36.7.13]) by smtp.gmail.com with ESMTPSA id h13-20020a05600c314d00b0041ac4aafd3dsm27045674wmo.12.2024.04.30.08.35.13 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 30 Apr 2024 08:35:13 -0700 (PDT) Message-ID: <4f99f0a1-1fae-42cf-a8ea-0f859e9818b9@freebox.fr> Date: Tue, 30 Apr 2024 17:30:28 +0200 Precedence: bulk X-Mailing-List: linux-media@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: [PATCH v2 1/3] dt-bindings: media: add qcom,msm8998-venus From: Marc Gonzalez To: Bjorn Andersson , Jeffrey Hugo , Konrad Dybcio , Stanimir Varbanov , Vikash Garodia , Bryan O Donoghue Cc: MSM , linux-media , DT , Pierre-Hugues Husson , Arnaud Vrac , Rob Herring , Krzysztof Kozlowski , Conor Dooley References: Content-Language: en-US In-Reply-To: msm8998 has the same video encode/decode accelerator as msm8996. Signed-off-by: Marc Gonzalez Reviewed-by: Bryan O'Donoghue Reviewed-by: Krzysztof Kozlowski --- Documentation/devicetree/bindings/media/qcom,msm8996-venus.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/media/qcom,msm8996-venus.yaml b/Documentation/devicetree/bindings/media/qcom,msm8996-venus.yaml index 3a4d817e544e2..56c16458e3bb4 100644 --- a/Documentation/devicetree/bindings/media/qcom,msm8996-venus.yaml +++ b/Documentation/devicetree/bindings/media/qcom,msm8996-venus.yaml @@ -18,7 +18,9 @@ allOf: properties: compatible: - const: qcom,msm8996-venus + enum: + - qcom,msm8996-venus + - qcom,msm8998-venus power-domains: maxItems: 1 From patchwork Tue Apr 30 15:32:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marc Gonzalez X-Patchwork-Id: 13649551 Received: from mail-wm1-f53.google.com (mail-wm1-f53.google.com [209.85.128.53]) (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 C14AD16D9B6 for ; Tue, 30 Apr 2024 15:35:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.53 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714491317; cv=none; b=Ymisw5nOTOqUlr9ZaYN5kUbB1i1AnLoIdNDkNCHyNfoJXtYWCUFtFj2et8RrNS+biWFq1N6s8kb8rnqGcYthqanSmF83hmfpgJdDzWA7g2HvRXbNQ/k6OZctFxB5mkUTiaT3AyXXY3XeIY33xi5I6Yxc39av6gbrG0+I4zCWMgE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714491317; c=relaxed/simple; bh=MPXbvZewmO/D2DEHW1XiJWvSM8CPq85XDTvUbnZY4DQ=; h=Message-ID:Date:MIME-Version:Subject:From:To:Cc:References: In-Reply-To:Content-Type; b=catri2/0ctRI+QvDu2lJjybK2i3+b5SMSvPyW3SH0+nQ4Cs6OwV41Jbak8Tsfm2vgpgpZFeZW6usE10X/ZACjorY0HPOG/tIdREKYDnWdkbrDz9glhwKbaQooaJJSTACW7i7zUS1iSmGtfe6imXJS3SCbD3Q9yu1T8Oc7mFj85Y= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=freebox.fr; spf=pass smtp.mailfrom=freebox.fr; dkim=pass (2048-bit key) header.d=freebox-fr.20230601.gappssmtp.com header.i=@freebox-fr.20230601.gappssmtp.com header.b=OKv34VfG; arc=none smtp.client-ip=209.85.128.53 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=freebox.fr Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=freebox.fr Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=freebox-fr.20230601.gappssmtp.com header.i=@freebox-fr.20230601.gappssmtp.com header.b="OKv34VfG" Received: by mail-wm1-f53.google.com with SMTP id 5b1f17b1804b1-41ba1ba5591so30770095e9.1 for ; Tue, 30 Apr 2024 08:35:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebox-fr.20230601.gappssmtp.com; s=20230601; t=1714491314; x=1715096114; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:from:subject:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=QyXdN6gxvZfSyDlB/uI/J3a7zD0pJvSdTF4inS8BuAY=; b=OKv34VfGvM0gRFRCIxQ5jCqJI+5hUmKmQj8oSnVTtPdDp54APgW7c9APrsoMdNlbCA 73HQPruan54V0oGSfcl8ckotm/B7r2dZ4RIFlB9PMUiHQLsT9X6TvLLRkLTjqaufCI2D +mmbpn82uHfSj2PdRX1jWld7x12Ky9+OsMGpj5+mfgY2G0nSW3WVvWCheVfrzknIUbWM UweEDxX0VoCJKqZ0BkKw4wgKaw6sIEDHKnLp0WjtXO8pqzM9VLFASEldS6YT69ZMolGJ g/zCHsZ5FHYRSP/o6VZ0N1XWhcFzcekHwLI0WAL6USiTULVmV4yffjwMsz97egTeWeLH LWVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714491314; x=1715096114; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:from:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=QyXdN6gxvZfSyDlB/uI/J3a7zD0pJvSdTF4inS8BuAY=; b=lVfrd7j21OLm0CJPtU3qWDZ5Rgw6+85QqQrnEJKw5ZX6u+O7yFHvtWozs3iIBM02fL n86V5HU8IL2GZZXUxOpzvj4GFqfWOrxpjhVHvRyWPAZfC7e6fjZuixO1x3OIzyCw/bJd +JhVeFExEJqEl8WPKV4rgMAHIIZozQch4NkCmsGaJSPNw3DhaQrMmC7w+CBZ3WJzOne1 QnaKC6UwEcoFYpp2tRN4caQ64tRvuofjKrXlPCItXb89ATWQRkCQb+2RXrYuVlvkOIK5 RnhdRmdNCEkHf8+bKbnCo7OCR3L/5Giy7ykJVrij8+MvJFYVnJrEfst+1g2UYfXC/t8B vp4g== X-Forwarded-Encrypted: i=1; AJvYcCX/wRC9n40Xv+BNCDtuvqQOZMor0uQU6wFE2ucerHW8PNedrTVgzSWxb3rontQgTdo25LZIvyAHo8ghBMRXivw/uT5/SiQpRw7o8ko= X-Gm-Message-State: AOJu0YycW+65i4i+ymzUK3pfuvrkqZNXoDdjYHfehb8KRRXRmUM9TMo3 cpNIckGalWyz+CjEj4j7JkqwGpQ1X/OW4GScc1bDHSlqIsLE7elsUToNUgorHKo= X-Google-Smtp-Source: AGHT+IFrLbxNE44BvP21M6g2WJTpq0/K6uhfLusQ+1ISn3HGmLcIUnF43AaIXpJs1Os97gFG3XMenw== X-Received: by 2002:a05:600c:3d0b:b0:41b:6cf6:61f8 with SMTP id bh11-20020a05600c3d0b00b0041b6cf661f8mr8498967wmb.11.1714491314064; Tue, 30 Apr 2024 08:35:14 -0700 (PDT) Received: from [192.168.108.81] (freebox.vlq16.iliad.fr. [213.36.7.13]) by smtp.gmail.com with ESMTPSA id h13-20020a05600c314d00b0041ac4aafd3dsm27045674wmo.12.2024.04.30.08.35.13 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 30 Apr 2024 08:35:13 -0700 (PDT) Message-ID: Date: Tue, 30 Apr 2024 17:32:37 +0200 Precedence: bulk X-Mailing-List: linux-media@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: [PATCH v2 2/3] arm64: dts: qcom: msm8998: add venus node From: Marc Gonzalez To: Bjorn Andersson , Jeffrey Hugo , Konrad Dybcio , Stanimir Varbanov , Vikash Garodia , Bryan O Donoghue Cc: MSM , linux-media , DT , Pierre-Hugues Husson , Arnaud Vrac , Rob Herring , Krzysztof Kozlowski , Conor Dooley References: Content-Language: en-US In-Reply-To: From: Pierre-Hugues Husson Now that the venus clocks are fixed, we can add the DT node. Reviewed-by: Bryan O'Donoghue Signed-off-by: Pierre-Hugues Husson Signed-off-by: Marc Gonzalez --- arch/arm64/boot/dts/qcom/msm8998.dtsi | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/msm8998.dtsi b/arch/arm64/boot/dts/qcom/msm8998.dtsi index 5f5b90a6e2bf1..3d3b1f61c0690 100644 --- a/arch/arm64/boot/dts/qcom/msm8998.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8998.dtsi @@ -3010,6 +3010,54 @@ mdss_dsi1_phy: phy@c996400 { }; }; + venus: video-codec@cc00000 { + compatible = "qcom,msm8998-venus"; + reg = <0x0cc00000 0xff000>; + interrupts = ; + power-domains = <&mmcc VIDEO_TOP_GDSC>; + clocks = <&mmcc VIDEO_CORE_CLK>, + <&mmcc VIDEO_AHB_CLK>, + <&mmcc VIDEO_AXI_CLK>, + <&mmcc VIDEO_MAXI_CLK>; + clock-names = "core", "iface", "bus", "mbus"; + iommus = <&mmss_smmu 0x400>, + <&mmss_smmu 0x401>, + <&mmss_smmu 0x40a>, + <&mmss_smmu 0x407>, + <&mmss_smmu 0x40e>, + <&mmss_smmu 0x40f>, + <&mmss_smmu 0x408>, + <&mmss_smmu 0x409>, + <&mmss_smmu 0x40b>, + <&mmss_smmu 0x40c>, + <&mmss_smmu 0x40d>, + <&mmss_smmu 0x410>, + <&mmss_smmu 0x421>, + <&mmss_smmu 0x428>, + <&mmss_smmu 0x429>, + <&mmss_smmu 0x42b>, + <&mmss_smmu 0x42c>, + <&mmss_smmu 0x42d>, + <&mmss_smmu 0x411>, + <&mmss_smmu 0x431>; + memory-region = <&venus_mem>; + status = "disabled"; + + video-decoder { + compatible = "venus-decoder"; + clocks = <&mmcc VIDEO_SUBCORE0_CLK>; + clock-names = "core"; + power-domains = <&mmcc VIDEO_SUBCORE0_GDSC>; + }; + + video-encoder { + compatible = "venus-encoder"; + clocks = <&mmcc VIDEO_SUBCORE1_CLK>; + clock-names = "core"; + power-domains = <&mmcc VIDEO_SUBCORE1_GDSC>; + }; + }; + mmss_smmu: iommu@cd00000 { compatible = "qcom,msm8998-smmu-v2", "qcom,smmu-v2"; reg = <0x0cd00000 0x40000>; From patchwork Tue Apr 30 15:34:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marc Gonzalez X-Patchwork-Id: 13649552 Received: from mail-wm1-f54.google.com (mail-wm1-f54.google.com [209.85.128.54]) (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 58B56143759 for ; Tue, 30 Apr 2024 15:35:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.54 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714491318; cv=none; b=KGJTJ22jlk+6lq2b6+qePZAjSogFfQv7rJ+AEInQTpIBGbfoW0LFtfnk1qYf/dQiHJ1+SCZ2DvAK3tHenrBhiaaWVEjXfehY/S7br3xje4LQSZd8LM7J5tOokCDL+XRxzxZi5kj+z1q1DUWTYDZcTtKYFyB1ZgOFd+ViO5o+dk4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714491318; c=relaxed/simple; bh=Oo58CEMdtjetSnRagHS5J1GNGo1JKVIA0feYLcxotvM=; h=Message-ID:Date:MIME-Version:Subject:From:To:Cc:References: In-Reply-To:Content-Type; b=iJOEHUalBVGck/WecrMcE1VWnYorpwNlc5d1kfmcfLGMFaeqbM6b3iQkvYQiDYNRGwFY4tYSUUdaEO8OTvny1U1EN4vHIwD/++7uZ8vleXev6HCA6OiilSqvu/sY620QNkgvx5e+QYlb1uGTgKTQf6WL3MSCs/9jHtbzs275q/c= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=freebox.fr; spf=pass smtp.mailfrom=freebox.fr; dkim=pass (2048-bit key) header.d=freebox-fr.20230601.gappssmtp.com header.i=@freebox-fr.20230601.gappssmtp.com header.b=yVChQl8k; arc=none smtp.client-ip=209.85.128.54 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=freebox.fr Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=freebox.fr Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=freebox-fr.20230601.gappssmtp.com header.i=@freebox-fr.20230601.gappssmtp.com header.b="yVChQl8k" Received: by mail-wm1-f54.google.com with SMTP id 5b1f17b1804b1-41adf155cffso42603055e9.2 for ; Tue, 30 Apr 2024 08:35:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebox-fr.20230601.gappssmtp.com; s=20230601; t=1714491314; x=1715096114; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:from:subject:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=aPqZJAxEGjY0ShetcfKjBOSOoETPGEikwkHIAxvShII=; b=yVChQl8kQX5YhdbCbz58y4fql36/fZIZg3th4jhtmO3hCMW/IPT5qHHa+wyiXonvNT HPYvdK+pR4BhfGeH84iLQ6Yp/QgKJgFZTCHae1An0Bsf99M+LfeWOqv5DEj4s0OFnHWL 7X13bj6giaY1E7T/3PN/3egy6ZobpmR7jqyOGGCof25HqumyhaHvwOpq+MHQZcxO9aiE MjEixO/2QrpXracxuSPAdS3WBlp72nrulg2JY1C1dfk/QIels8NV4QhmbVX9d0m08kKJ ufOX1E6F+U31imputM+B7gAfA8cZjeEc4CpevyDEaAjsEOBc7tLfYJHeJMCpMbg5REn4 e0Xw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714491314; x=1715096114; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:from:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=aPqZJAxEGjY0ShetcfKjBOSOoETPGEikwkHIAxvShII=; b=kUO/pDSTrC6vYYU2mDs54r98H6WCUVyRmlMnhfmb5YOJQCv/tJzu1u1qLQexY0g6t6 MFJg6LUu4VDO/0PPU4Jslo+5Eh/0bqI7CaxJp5E82zec6Iu0RX+rKh3gOvIaKSrdv9bu BpwDJT03UJ3+bIPnRE6223/EgJnQMmfjkCM37qHTcOCsjFw+C6F8NDjNXbX0cziY4Krz YU9+mlHiEKKXY18KYgH/BJFBDLEDZiW1iOfS7yTaoVarwulqgCJ/eC3kiT4+eO1tfFR/ +agk4MFSScb7bS++OTjUL8nILriSe8o6tk66028PN+TvqH+lNXBIAuVvFzJKirx5gp02 CQtw== X-Forwarded-Encrypted: i=1; AJvYcCUpa1jEhS3wrhkg+L1nm4bLcr/k4STzgcYRVz1nSm5om+wQtzFxbvT9KLmwiNCCPVmtZg+yCgk4i7uDCBjOTDag1IxOZTKCy6rLAfQ= X-Gm-Message-State: AOJu0YyVwkohfB7wqSuvLK4fbEfTCMGbfMo+/cBeMY4kFkL0hicRV9cE m/DUKOUTkUC9Y5hrZFSLqjjfV8hE2oigq0BD8zsVaESk71QJpIqZYe7NAnN5PMY= X-Google-Smtp-Source: AGHT+IEdaQNPB55tn+0T4Z0bhsq7wMMGI/91idvS14Pc55qu5JeJj2jVjNfX8746ehWLCdzdHLUxaQ== X-Received: by 2002:a05:600c:35c4:b0:418:f5a9:b91c with SMTP id r4-20020a05600c35c400b00418f5a9b91cmr9667253wmq.33.1714491314716; Tue, 30 Apr 2024 08:35:14 -0700 (PDT) Received: from [192.168.108.81] (freebox.vlq16.iliad.fr. [213.36.7.13]) by smtp.gmail.com with ESMTPSA id h13-20020a05600c314d00b0041ac4aafd3dsm27045674wmo.12.2024.04.30.08.35.14 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 30 Apr 2024 08:35:14 -0700 (PDT) Message-ID: <9844c940-21b1-42af-9448-62a2d5ffadb7@freebox.fr> Date: Tue, 30 Apr 2024 17:34:06 +0200 Precedence: bulk X-Mailing-List: linux-media@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: [PATCH v2 3/3] media: venus: add msm8998 support From: Marc Gonzalez To: Bjorn Andersson , Jeffrey Hugo , Konrad Dybcio , Stanimir Varbanov , Vikash Garodia , Bryan O Donoghue Cc: MSM , linux-media , DT , Pierre-Hugues Husson , Arnaud Vrac , Rob Herring , Krzysztof Kozlowski , Conor Dooley References: Content-Language: en-US In-Reply-To: From: Pierre-Hugues Husson Add the missing bits for msm8998 support. Reviewed-by: Bryan O'Donoghue Signed-off-by: Pierre-Hugues Husson Signed-off-by: Marc Gonzalez --- drivers/media/platform/qcom/venus/core.c | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/drivers/media/platform/qcom/venus/core.c b/drivers/media/platform/qcom/venus/core.c index ce206b7097541..42e0c580e093d 100644 --- a/drivers/media/platform/qcom/venus/core.c +++ b/drivers/media/platform/qcom/venus/core.c @@ -587,6 +587,47 @@ static const struct venus_resources msm8996_res = { .fwname = "qcom/venus-4.2/venus.mbn", }; +static const struct freq_tbl msm8998_freq_table[] = { + { 1944000, 520000000 }, /* 4k UHD @ 60 (decode only) */ + { 972000, 520000000 }, /* 4k UHD @ 30 */ + { 489600, 346666667 }, /* 1080p @ 60 */ + { 244800, 150000000 }, /* 1080p @ 30 */ + { 108000, 75000000 }, /* 720p @ 30 */ +}; + +/* + * https://git.codelinaro.org/clo/la/kernel/msm-4.4/-/blob/caf_migration/kernel.lnx.4.4.r38-rel/arch/arm/boot/dts/qcom/msm8998-vidc.dtsi + */ +static const struct reg_val msm8998_reg_preset[] = { + { 0x80124, 0x00000003 }, + { 0x80550, 0x01111111 }, + { 0x80560, 0x01111111 }, + { 0x80568, 0x01111111 }, + { 0x80570, 0x01111111 }, + { 0x80580, 0x01111111 }, + { 0x80588, 0x01111111 }, + { 0xe2010, 0x00000000 }, +}; + +static const struct venus_resources msm8998_res = { + .freq_tbl = msm8998_freq_table, + .freq_tbl_size = ARRAY_SIZE(msm8998_freq_table), + .reg_tbl = msm8998_reg_preset, + .reg_tbl_size = ARRAY_SIZE(msm8998_reg_preset), + .clks = { "core", "iface", "bus", "mbus" }, + .clks_num = 4, + .vcodec0_clks = { "core" }, + .vcodec1_clks = { "core" }, + .vcodec_clks_num = 1, + .max_load = 2563200, + .hfi_version = HFI_VERSION_3XX, + .vmem_id = VIDC_RESOURCE_NONE, + .vmem_size = 0, + .vmem_addr = 0, + .dma_mask = 0xddc00000 - 1, + .fwname = "qcom/venus-4.4/venus.mbn", +}; + static const struct freq_tbl sdm660_freq_table[] = { { 979200, 518400000 }, { 489600, 441600000 }, @@ -893,6 +934,7 @@ static const struct venus_resources sc7280_res = { static const struct of_device_id venus_dt_match[] = { { .compatible = "qcom,msm8916-venus", .data = &msm8916_res, }, { .compatible = "qcom,msm8996-venus", .data = &msm8996_res, }, + { .compatible = "qcom,msm8998-venus", .data = &msm8998_res, }, { .compatible = "qcom,sdm660-venus", .data = &sdm660_res, }, { .compatible = "qcom,sdm845-venus", .data = &sdm845_res, }, { .compatible = "qcom,sdm845-venus-v2", .data = &sdm845_res_v2, },