From patchwork Fri Mar 4 16:15:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexandre Bailon X-Patchwork-Id: 12769446 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C1F71C433EF for ; Fri, 4 Mar 2022 16:30:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=XDatAo43LfwoqcYbQsJkfS9ffYSgWUmOan3lBCgw/qc=; b=cJZ0RV9DIK2VN2 Z4cwNTI8YyOC87yPkrp57WRVxTKdQYTGvahZKBpDuqEppMDH+m1vk89P9WVvmMQJtbSAmSMkneDNe mZTgozSX623AG4UmVCBaK8phL3yYfmI5GqgyAnkmonl6G2mj9/TXA92Fr/UUIP47y5dOb5FlGEsG9 ZZxQNPviwIyIJb9124l+9l4FmeL0X2t7W4RQyMD8I1pOsUtuk79eGrDjjgNVen9ICr2Lc8QlfqiXk f/h/Q/3MOEIyy+A3iEDw3vlR1R3OzpiugyS5Gc7r+FQie26Gzr90wsT71c5vBFQMAS2n2hvjo/YS9 VxN9cmk6SibKrTFE7jbA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nQAnc-00B2u9-Ei; Fri, 04 Mar 2022 16:29:01 +0000 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nQAab-00Axqx-WA for linux-arm-kernel@lists.infradead.org; Fri, 04 Mar 2022 16:15:38 +0000 Received: by mail-wr1-x432.google.com with SMTP id p9so13394834wra.12 for ; Fri, 04 Mar 2022 08:15:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=16aGvyY6fmPhhVYfQXbNCxfZJxOVo7nnrPOm+3Luipg=; b=kN8p92NuWAbYqs8bwZlnLzwcZDbsVEWD4vm0t5XrNfLzL7aH0vHtHEcRtcG0C/1Uu7 9hdsGCdU1rbTrLacXL/Ft91zYh/W1JDQIBszrzrit1TsPj5F50AHGLBhangCud91sOb+ 0xmv5DAhd0EuvQ6glDl85z8F4M80x30xSzPfnpcNAC1bot0hw0gQVwnEHiXptu+KFEVT KtTKvHh8xyMPof3zdp+DP48Co+7DZGEpI3DZVEPQvWJu+Y5HaN7E9H5vK0HfJYoUpwXb uu+Xszyy+It68nNjX8tuaNzrkWGn+hyALM66vu0FpOGsNNU/MyaZYPtYRPeDWog4idkA Hajw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=16aGvyY6fmPhhVYfQXbNCxfZJxOVo7nnrPOm+3Luipg=; b=xHI0/UIFsl3JkPwDAhM1clO7TZdnttvwfEZSrgmZ+UQXe3xP1J84pRyTH1b7J35hX2 ADJva9sEHnUHZR/lyiAfH15aZuv9ePJJucWTPx/lm0sXyf6tiWtitnTkqfhwQ7ryMo16 ia33x6XlOJA+pjtFi4DnCjsgX6l4XqMX4Wzpb8LDwKKyiGcqTIROzObxrJJXE2YjcKBj AW7VROBi5xYzgiSf451tXt7Xb5LdnDI56Tmlr/yQxh/1/z1QZzajZAZYuIqJOZoWO/Dm i+U7y2b8K83Aq7u+5NtHvlB8LYmRFIUrRYmZn9lxRth+F0tn9XRPIl8rfuzrqZyNFuAw Livw== X-Gm-Message-State: AOAM532sQLU2SyLR9eAujCLx+m007En7bhRPy7mChzIE7VBmCls4Dij6 FWRz2QNVRc2I6/JPWymVJ3P2iA== X-Google-Smtp-Source: ABdhPJwD4uW+a+b6q8YWzK9KzYjz7dwuWWKnSwI9jSPWBcToFrXnKiJsKNXtvqLT5eUBLCFLIqBmsg== X-Received: by 2002:adf:ed0c:0:b0:1f0:63a5:36aa with SMTP id a12-20020adfed0c000000b001f063a536aamr4767846wro.588.1646410532349; Fri, 04 Mar 2022 08:15:32 -0800 (PST) Received: from xps-9300.baylibre (laubervilliers-658-1-213-31.w90-63.abo.wanadoo.fr. [90.63.244.31]) by smtp.gmail.com with ESMTPSA id g6-20020a5d5406000000b001f049726044sm4937307wrv.79.2022.03.04.08.15.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 04 Mar 2022 08:15:31 -0800 (PST) From: Alexandre Bailon To: ohad@wizery.com, bjorn.andersson@linaro.org, mathieu.poirier@linaro.org, robh+dt@kernel.or Cc: matthias.bgg@gmail.com, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, stephane.leprovost@mediatek.com, khilman@baylibre.com, Julien STEPHAN , Alexandre Bailon Subject: [PATCH v4 6/7] remoteproc: mtk-apu: Add support of MT8365 Date: Fri, 4 Mar 2022 17:15:13 +0100 Message-Id: <20220304161514.994128-7-abailon@baylibre.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220304161514.994128-1-abailon@baylibre.com> References: <20220304161514.994128-1-abailon@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220304_081534_098215_2B405B90 X-CRM114-Status: GOOD ( 13.10 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Julien STEPHAN This adds support of APU available in the MT8365. Signed-off-by: Julien STEPHAN Signed-off-by: Alexandre Bailon --- drivers/remoteproc/mtk_apu.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/drivers/remoteproc/mtk_apu.c b/drivers/remoteproc/mtk_apu.c index deec51b86ba5..57dd73c63d3f 100644 --- a/drivers/remoteproc/mtk_apu.c +++ b/drivers/remoteproc/mtk_apu.c @@ -96,6 +96,24 @@ static const struct mtk_apu_conf mt8183_conf = { .clk_names = mt8183_clk_names }; +static const char * const mt8365_clk_names[] = { + "if_ck", + "edma", + "ahb", + "axi", + "ipu", + "jtag", + "smi_cam", + "ifr_apu_axi", +}; + +static const struct mtk_apu_conf mt8365_conf = { + .core_default0 = BIT(26) | BIT(20), + .core_default1 = BIT(3) | BIT(7), + .num_clks = ARRAY_SIZE(mt8365_clk_names), + .clk_names = mt8365_clk_names +}; + static int mtk_apu_iommu_map(struct rproc *rproc, struct rproc_mem_entry *entry) { struct mtk_apu_rproc *apu_rproc = rproc->priv; @@ -633,6 +651,7 @@ static int mtk_apu_rproc_remove(struct platform_device *pdev) static const struct of_device_id mtk_apu_rproc_of_match[] = { { .compatible = "mediatek,mt8183-apu", .data = &mt8183_conf }, + { .compatible = "mediatek,mt8365-apu", .data = &mt8365_conf }, { /* sentinel */ }, }; MODULE_DEVICE_TABLE(of, mtk_apu_rproc_of_match);