Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp843864rdb; Wed, 6 Dec 2023 01:12:27 -0800 (PST) X-Google-Smtp-Source: AGHT+IGXqF8jjb9qiFM0uxDQ/oSTDvjEaJNdLfW+sTtfVq5kmMDGLDHOSsX0/5tRGlJKhumvP2mc X-Received: by 2002:a92:d80c:0:b0:35d:59a2:3326 with SMTP id y12-20020a92d80c000000b0035d59a23326mr788695ilm.42.1701853947283; Wed, 06 Dec 2023 01:12:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701853947; cv=none; d=google.com; s=arc-20160816; b=ym5hp9MoJbysubPPsZiY0UQn7kAN++Fl2Jh5cFwQ0zcFF1gnRiMMBcLSF9Cr4LGGm+ pSwreTYoAEg88mQMp85obncUziaL+feghY4fzV56JVLhTtkBhZ1zaqBn3+6DqLMydhpK K0sKmYYGcrZKVf9gFdaNEiah8zWvyfsYH5e1PpGsH5JQWF2mY3bcuMyyZjwhX44dt5Jp vxQ5LNQkDuQaqE0wdfjhZR2U42smaGe84a2tSDn5EuQr9gXQg9GxaOVaPsZQ4mCUkgFf ErH1A1j2yHgcH+ozGTUVOMDhvfyYSjfnxBT+c19MPDrAPJNFnDF1gZI4jt/pN8cpzwK8 hbvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=YqJKf6k3LqdMOajnfjgr4qlTOkc+4XpnvbfWlmqLEqw=; fh=mzOQNX9OJ+XctUrCEyUp2AUmwh7cUaCt/mXE26Pa5Zk=; b=foTIhzLC3kdWeaH/bg21pgvKHJ/0NF0Gr/qqHdEcgZhehytpiDmI+oETl4cA2l8Eic mW4G6S3QxOqLljJ9iZpIxVlhRzn5m2eyZftOhDHL2+mV54Gc/sY5qKVmJUb7Zt120BRI BH8eJP7zMFuAu8Y8tPZ81dkYpB/7Sq1rFatDqCzDkZ075MayN8x4QRCdNyMHom2mDEtl wjHyePlq8eU0Hk1iqbdnY9fX1GCpdtrd7QJKL1EExFKvJW6GPxQcXnzC1oTI4pJIVSh7 2MsnPlQ41Fnhe8CwJDsLC9PMAzT4p8hLs//Mfos0DYEzmtUGpOGKeE04flt1Kj4TAxaW dthg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=yYhIoaaF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id a14-20020a63d40e000000b005c623037c10si11520485pgh.96.2023.12.06.01.12.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Dec 2023 01:12:27 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=yYhIoaaF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 7589780BB1C7; Wed, 6 Dec 2023 01:12:24 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231537AbjLFJME (ORCPT + 99 others); Wed, 6 Dec 2023 04:12:04 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37680 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229459AbjLFJLw (ORCPT ); Wed, 6 Dec 2023 04:11:52 -0500 Received: from mail-yb1-xb2c.google.com (mail-yb1-xb2c.google.com [IPv6:2607:f8b0:4864:20::b2c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 77B821BE8 for ; Wed, 6 Dec 2023 01:11:56 -0800 (PST) Received: by mail-yb1-xb2c.google.com with SMTP id 3f1490d57ef6-daf4f0e3a0fso4911930276.1 for ; Wed, 06 Dec 2023 01:11:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1701853915; x=1702458715; darn=vger.kernel.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=YqJKf6k3LqdMOajnfjgr4qlTOkc+4XpnvbfWlmqLEqw=; b=yYhIoaaFP2pDyV/7WCE+SVYkzAmn9WDSKN3A1MgJg2wsDBBB6Nhhr/hScFBA4xnm9c iEkEXQvLfqpEy6KSHUo/V4p1bHCiYjL2VYJj+gKnQBVSiVwTAAz7SMk+g+2babMZHUzb Dwwex06NZt3mrLQbsB2aLVek2QRPCMDubiLODaxQ0UqmKsdrFBndfE+4FdcNT1O2678K xZ+9hKEsNvatBy68E7EK5W4aTVUjmT+N9JGWLKCBlpKaZf/ycy3/KCpwGbv1URbx6uWv QQgCu0nmd4D3AraOOascALi9dIxjms4JAjPnT1EQaF5qd2nO0TSc+qpFEOdecq+Sj5IB 27rw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701853915; x=1702458715; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=YqJKf6k3LqdMOajnfjgr4qlTOkc+4XpnvbfWlmqLEqw=; b=eH36OlWNOg9b3YV6jD0Xxj+XEsxLq9+/sesShGbqif1hU5D4FXpXDQJ2HhH/vPxqBX g5+cDHnlY2+6ZQL+VAoP45FakSQ3R72XwVenI3PcbAoTu/Fso4ztOPWJwqnWY134AVDW fBYYMzeqap/FLTY+2WRYvfQ5sPW5chVdFLn28UIwq+EYlJxgmzlV4GgQv5co7VRpyL6G WQO6wQ7ggvRyNZd1jgKc/Fd1VVE20CPJD1fTW54u/EtOO0ePLFjqkcAyrQdVsepdk/2u FhUUALbyqkhAKABDPDMLKr8gaCmQ7xwVXylb6hrXArpD6UlRj/AZN3UeGW0t+Oc9c7gp iwkA== X-Gm-Message-State: AOJu0Yzue+DTDXxUSLdeYmbx8Nw2tAI12QrlIJB4A51U0OTNKeCB2PRw MgcJM4dqjL1Rrxtff3IloJk6RMXaguvz1x0KC76oPg== X-Received: by 2002:a25:3497:0:b0:db7:dacf:622a with SMTP id b145-20020a253497000000b00db7dacf622amr375926yba.124.1701853915593; Wed, 06 Dec 2023 01:11:55 -0800 (PST) MIME-Version: 1.0 References: <20231205220526.417719-1-robdclark@gmail.com> <20231205220526.417719-3-robdclark@gmail.com> In-Reply-To: <20231205220526.417719-3-robdclark@gmail.com> From: Dmitry Baryshkov Date: Wed, 6 Dec 2023 11:11:44 +0200 Message-ID: Subject: Re: [PATCH 2/5] drm/msm/adreno: Split catalog into separate files To: Rob Clark Cc: dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org, linux-arm-msm@vger.kernel.org, Rob Clark , Abhinav Kumar , Sean Paul , Marijn Suijten , David Airlie , Daniel Vetter , Konrad Dybcio , Johan Hovold , Bjorn Andersson , open list Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Wed, 06 Dec 2023 01:12:24 -0800 (PST) On Wed, 6 Dec 2023 at 00:06, Rob Clark wrote: > > From: Rob Clark > > Split each gen's gpu table into it's own file. Only code-motion, no > functional change. > > Signed-off-by: Rob Clark > --- > drivers/gpu/drm/msm/Makefile | 5 + > drivers/gpu/drm/msm/adreno/a2xx_catalog.c | 53 ++ > drivers/gpu/drm/msm/adreno/a3xx_catalog.c | 75 +++ > drivers/gpu/drm/msm/adreno/a4xx_catalog.c | 51 ++ > drivers/gpu/drm/msm/adreno/a5xx_catalog.c | 145 ++++++ > drivers/gpu/drm/msm/adreno/a6xx_catalog.c | 285 +++++++++++ > drivers/gpu/drm/msm/adreno/adreno_device.c | 570 +-------------------- > 7 files changed, 620 insertions(+), 564 deletions(-) > create mode 100644 drivers/gpu/drm/msm/adreno/a2xx_catalog.c > create mode 100644 drivers/gpu/drm/msm/adreno/a3xx_catalog.c > create mode 100644 drivers/gpu/drm/msm/adreno/a4xx_catalog.c > create mode 100644 drivers/gpu/drm/msm/adreno/a5xx_catalog.c > create mode 100644 drivers/gpu/drm/msm/adreno/a6xx_catalog.c Reviewed-by: Dmitry Baryshkov > > diff --git a/drivers/gpu/drm/msm/Makefile b/drivers/gpu/drm/msm/Makefile > index 49671364fdcf..32f2fd980452 100644 > --- a/drivers/gpu/drm/msm/Makefile > +++ b/drivers/gpu/drm/msm/Makefile > @@ -7,12 +7,17 @@ ccflags-$(CONFIG_DRM_MSM_DP) += -I $(srctree)/$(src)/dp > msm-y := \ > adreno/adreno_device.o \ > adreno/adreno_gpu.o \ > + adreno/a2xx_catalog.o \ > adreno/a2xx_gpu.o \ > + adreno/a3xx_catalog.o \ > adreno/a3xx_gpu.o \ > + adreno/a4xx_catalog.o \ > adreno/a4xx_gpu.o \ > + adreno/a5xx_catalog.o \ > adreno/a5xx_gpu.o \ > adreno/a5xx_power.o \ > adreno/a5xx_preempt.o \ > + adreno/a6xx_catalog.o \ > adreno/a6xx_gpu.o \ > adreno/a6xx_gmu.o \ > adreno/a6xx_hfi.o \ > diff --git a/drivers/gpu/drm/msm/adreno/a2xx_catalog.c b/drivers/gpu/drm/msm/adreno/a2xx_catalog.c > new file mode 100644 > index 000000000000..1a4d182279fc > --- /dev/null > +++ b/drivers/gpu/drm/msm/adreno/a2xx_catalog.c > @@ -0,0 +1,53 @@ > +// SPDX-License-Identifier: GPL-2.0-only > +/* > + * Copyright (C) 2013-2014 Red Hat > + * Author: Rob Clark > + * > + * Copyright (c) 2014,2017 The Linux Foundation. All rights reserved. > + */ > + > +#include "adreno_gpu.h" > + > +const struct adreno_info a2xx_gpus[] = { > + { > + .chip_ids = ADRENO_CHIP_IDS(0x02000000), > + .family = ADRENO_2XX_GEN1, > + .revn = 200, > + .fw = { > + [ADRENO_FW_PM4] = "yamato_pm4.fw", > + [ADRENO_FW_PFP] = "yamato_pfp.fw", > + }, > + .gmem = SZ_256K, > + .inactive_period = DRM_MSM_INACTIVE_PERIOD, > + .init = a2xx_gpu_init, > + }, { /* a200 on i.mx51 has only 128kib gmem */ > + .chip_ids = ADRENO_CHIP_IDS(0x02000001), > + .family = ADRENO_2XX_GEN1, > + .revn = 201, > + .fw = { > + [ADRENO_FW_PM4] = "yamato_pm4.fw", > + [ADRENO_FW_PFP] = "yamato_pfp.fw", > + }, > + .gmem = SZ_128K, > + .inactive_period = DRM_MSM_INACTIVE_PERIOD, > + .init = a2xx_gpu_init, > + }, { > + .chip_ids = ADRENO_CHIP_IDS(0x02020000), > + .family = ADRENO_2XX_GEN2, > + .revn = 220, > + .fw = { > + [ADRENO_FW_PM4] = "leia_pm4_470.fw", > + [ADRENO_FW_PFP] = "leia_pfp_470.fw", > + }, > + .gmem = SZ_512K, > + .inactive_period = DRM_MSM_INACTIVE_PERIOD, > + .init = a2xx_gpu_init, > + }, { > + /* sentinal */ > + } > +}; > + > +MODULE_FIRMWARE("qcom/leia_pfp_470.fw"); > +MODULE_FIRMWARE("qcom/leia_pm4_470.fw"); > +MODULE_FIRMWARE("qcom/yamato_pfp.fw"); > +MODULE_FIRMWARE("qcom/yamato_pm4.fw"); > \ No newline at end of file Nit: you might want to fix newlines (here and in other catalog files). -- With best wishes Dmitry