From patchwork Thu Feb 23 13:34:37 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: 13150351 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 55770C61DA4 for ; Thu, 23 Feb 2023 13:38:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=oRRbmSQ3Rq/4N4LJOPHJPIMC9cy1PqF0Em/E+4AfhBU=; b=DL3gqfr+JS1DPSQQ+/tgIwDCwW n0601Hj6xNGm6RngXD3vqeMx5Umoalcr9gH8O0rk5XUQSzv7mW6Rxd+9T96exVLSYfIxoyDRrsR0G 6vc7jMsqBZBVEnpXrzoEch/hFIIxOzwGJe0nRPduj6pcWdkXrKF3oafDi/4ynBahGNFoP62+ER6ns 4k+P9AmMCNjXLevKNWRnAwRcl7IMpYF7eLwZbhlR4avHpNYkvPq2xKvpY2M5YIakuB+EVSXk3Ouu0 J9MbuONcqmDOwsPIPojyRBAR71t57ebYSIHdO9T4Ff5ng+sVMB0BT1dE3tRJKbhNwkv2+FTIUA1G+ 86I5aFag==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pVBnM-00GUtJ-DR; Thu, 23 Feb 2023 13:38:00 +0000 Received: from madras.collabora.co.uk ([2a00:1098:0:82:1000:25:2eeb:e5ab]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pVBkT-00GT0o-TV; Thu, 23 Feb 2023 13:35:03 +0000 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 DA46F660220C; Thu, 23 Feb 2023 13:34:59 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1677159300; bh=HedQD3Ilc5pEnx8vhQO81s7TTNK+oqpJPvaglDZ6DvY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ObJ4LF5X4PZNlRDmnrWekg9i9g2IizcQbV6DRR2GJSeASIpU55TnttDCZPkW9wK7F oUEhnbgnMZuYUxMivnVUUIu78obGY9N+2hbQebVBpSrL3J6iNUE6QPtN9zMLJMWQJn oYow2HNSSLAkeGQdcye85zzh8jm6DWR4dmTDrthfu/YItt4/N5dG6E+KqNS9UP+yMV qoYDuBiX0DSgSIFDYBkJBs8gi/y70dnXLP19Ie7af1tGWI9HxOGWpd0b6tXFKbNwk8 7h8/l2kY1WGogawQoutk9u6HwFXujUyvGsY/9rXodKqZdIzAtYqf+iLsW6PNZc0xAn rl6X23v6rdpwA== 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 v3 08/11] drm/panfrost: Add the MT8192 GPU ID Date: Thu, 23 Feb 2023 14:34:37 +0100 Message-Id: <20230223133440.80941-9-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230223133440.80941-1-angelogioacchino.delregno@collabora.com> References: <20230223133440.80941-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230223_053502_159070_F0BD01E7 X-CRM114-Status: GOOD ( 10.95 ) X-BeenThere: linux-mediatek@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-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org From: Alyssa Rosenzweig MediaTek MT8192 has a Mali-G57 with a special GPU ID. Add its GPU ID, but treat it as otherwise identical to a standard Mali-G57. We do _not_ fix up the GPU ID here -- userspace needs to be aware of the special GPU ID, in case we find functional differences between MediaTek's implementation and the standard Mali-G57 down the line. Signed-off-by: Alyssa Rosenzweig Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Steven Price Reviewed-by: Chen-Yu Tsai --- drivers/gpu/drm/panfrost/panfrost_gpu.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/gpu/drm/panfrost/panfrost_gpu.c b/drivers/gpu/drm/panfrost/panfrost_gpu.c index 6452e4e900dd..d28b99732dde 100644 --- a/drivers/gpu/drm/panfrost/panfrost_gpu.c +++ b/drivers/gpu/drm/panfrost/panfrost_gpu.c @@ -204,6 +204,14 @@ static const struct panfrost_model gpu_models[] = { GPU_MODEL(g57, 0x9001, GPU_REV(g57, 0, 0)), + + /* MediaTek MT8192 has a Mali-G57 with a different GPU ID from the + * standard. Arm's driver does not appear to handle this model. + * ChromeOS has a hack downstream for it. Treat it as equivalent to + * standard Mali-G57 for now. + */ + GPU_MODEL(g57, 0x9003, + GPU_REV(g57, 0, 0)), }; static void panfrost_gpu_init_features(struct panfrost_device *pfdev)