From patchwork Tue Feb 28 10:27:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 62403 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp2933619wrd; Tue, 28 Feb 2023 02:30:41 -0800 (PST) X-Google-Smtp-Source: AK7set/OGEYeXFt/f6g9LlT27f7iChzZc1pdsHfdXG7A/qGSlF52MrpwVXH6KIAzkY3/fJhto5HY X-Received: by 2002:a17:906:1c81:b0:882:ed4a:f23 with SMTP id g1-20020a1709061c8100b00882ed4a0f23mr2172943ejh.49.1677580241193; Tue, 28 Feb 2023 02:30:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1677580241; cv=none; d=google.com; s=arc-20160816; b=GIsXOwWZg+Iv8hQ0wqBGetLTO43Qw6l4XslFRHtYpQ1j1/QM85Ep11q89xNbL7Z6Zp KuJcBQ+TRMgglz45w7/AEVdfgewR6Cubwi5zc3/ms/RPccNAdi8intzp/MgpMACm2TEC 3YVrlR9KYInWMYnU8DPM/OAQ2UV54VW1r6SoaywpfUmd9ymqYf8zF/FXmszZdluxePpQ 1kMfX4of1Gk7bBLNFJA07Q0IXCqs5phiJuxMEpV2yrhEMvme1n4HAbUfZ+Ddl1c8qC/x h6LfLvhs6ceoP8A6jWliG4vQ9/zgEPYcAqFFE5CnOqHEcagZ2/24J6vnNoqP4tfhZfSJ VHgw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=/rRZquBeL2jOnSPHoHCrDfUkL4Y+iXOG/ZqD2+1dOXQ=; b=wlHZwBa94z9DLcFlm6CmrvPgnWwJIJ/h7AMgoLdS4Eq5vlYJVkEwHK3E13Unxu/wpo UQYeIdXw/jMfzSX9liJPal90HorvBIWfl+mxJH8JxlShca0VTNv6h9zMNN9rGzX8es5C 7aSN9c+tj8waTQqtEXSZIrQNmL/pcjq8aIYpVGi1nMKJc6PQzppjesdwA8wlwYxcD6iD WY5JQ0DpRSM0Ck/M+JixReESzwdEm9oR59CU6qy9WFYg1XNHpQ2op7DWH3uNhdxNv0iR 7t5ku6Z8rMCMdriYPDCb7TnvhV/QkDz51o27rp3MWCKNtvsNUPhXK5mgl1wUPTRt1qm8 joNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=kNjEiIpU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=collabora.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e17-20020a170906045100b008b79a5e743esi10901373eja.253.2023.02.28.02.30.18; Tue, 28 Feb 2023 02:30:41 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=kNjEiIpU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231215AbjB1K1q (ORCPT + 99 others); Tue, 28 Feb 2023 05:27:46 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39926 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231222AbjB1K1V (ORCPT ); Tue, 28 Feb 2023 05:27:21 -0500 Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4E4892CFEF; Tue, 28 Feb 2023 02:27:19 -0800 (PST) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id 406306602FE0; Tue, 28 Feb 2023 10:27:17 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1677580037; bh=XOBRNDDFJGfYsIgxMZ/xxG6T/bqER3TGwYBPNyV4tY8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kNjEiIpU5LEKmdXFZ7CYc4ekqBOdxQYUdJ+y+fQEMFo66ksXXaAmFsXx4O/ZZtDu1 f5C2oBTaUqBeok3t/Mnte9PYCUSqmJQvQjp+eiHCGmpv0Sev3Rgz76NJix7iQxryQG jG2EUENslJdW+bRPooV/a6CGLVBb66/+r/qt5xxsHPjU/icT9x+hOaRRFGoPnVyqzY AaDJEvCHtOd49J88gIJWlDvFisxpso75d0v3syCjuqB4KHzPoEWxfv4rDv01ilY4YN 2OjTMrv/gqK57qMOefQSzkzeBUA7brmNlQEEWGA/fdkE1kJaSk4/1n3Gw30qrasLKf 8NVwljvUhO0zA== From: AngeloGioacchino Del Regno To: airlied@gmail.com Cc: daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, steven.price@arm.com, alyssa.rosenzweig@collabora.com, matthias.bgg@gmail.com, robh@kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, AngeloGioacchino Del Regno Subject: [PATCH v4 10/12] drm/panfrost: Add mediatek,mt8192-mali compatible Date: Tue, 28 Feb 2023 11:27:02 +0100 Message-Id: <20230228102704.708150-10-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230228102704.708150-1-angelogioacchino.delregno@collabora.com> References: <20230228102704.708150-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1759070378886411219?= X-GMAIL-MSGID: =?utf-8?q?1759070378886411219?= From: Alyssa Rosenzweig Required for Mali-G57 on the Mediatek MT8192 and MT8195, which uses even more power domains than the MT8183 before it. Signed-off-by: Alyssa Rosenzweig [Angelo: Removed unneeded "sram" supply, added mt8195 to commit description] Co-developed-by: AngeloGioacchino Del Regno Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Steven Price Reviewed-by: Chen-Yu Tsai Tested-by: Chen-Yu Tsai --- drivers/gpu/drm/panfrost/panfrost_drv.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c index abb0dadd8f63..5d25e77e1037 100644 --- a/drivers/gpu/drm/panfrost/panfrost_drv.c +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c @@ -663,6 +663,16 @@ static const struct panfrost_compatible mediatek_mt8183_data = { .pm_domain_names = mediatek_mt8183_pm_domains, }; +static const char * const mediatek_mt8192_supplies[] = { "mali", NULL }; +static const char * const mediatek_mt8192_pm_domains[] = { "core0", "core1", "core2", + "core3", "core4" }; +static const struct panfrost_compatible mediatek_mt8192_data = { + .num_supplies = ARRAY_SIZE(mediatek_mt8192_supplies) - 1, + .supply_names = mediatek_mt8192_supplies, + .num_pm_domains = ARRAY_SIZE(mediatek_mt8192_pm_domains), + .pm_domain_names = mediatek_mt8192_pm_domains, +}; + static const struct of_device_id dt_match[] = { /* Set first to probe before the generic compatibles */ { .compatible = "amlogic,meson-gxm-mali", @@ -681,6 +691,7 @@ static const struct of_device_id dt_match[] = { { .compatible = "arm,mali-bifrost", .data = &default_data, }, { .compatible = "arm,mali-valhall-jm", .data = &default_data, }, { .compatible = "mediatek,mt8183-mali", .data = &mediatek_mt8183_data }, + { .compatible = "mediatek,mt8192-mali", .data = &mediatek_mt8192_data }, {} }; MODULE_DEVICE_TABLE(of, dt_match);