<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Ping...</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Review <font size="2"><span style="font-size:11pt">2. [PATCH] drm: add drm device name (Jiang, Sonny), please.
<br>
</span></font></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<font size="2"><span style="font-size:11pt"><br>
</span></font></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<font size="2"><span style="font-size:11pt">Thanks,<br>
</span></font></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<font size="2"><span style="font-size:11pt">Sonny</span></font><br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> amd-gfx <amd-gfx-bounces@lists.freedesktop.org> on behalf of amd-gfx-request@lists.freedesktop.org <amd-gfx-request@lists.freedesktop.org><br>
<b>Sent:</b> Tuesday, September 3, 2019 9:17 PM<br>
<b>To:</b> amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org><br>
<b>Subject:</b> amd-gfx Digest, Vol 40, Issue 37</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">Send amd-gfx mailing list submissions to<br>
amd-gfx@lists.freedesktop.org<br>
<br>
To subscribe or unsubscribe via the World Wide Web, visit<br>
<a href="https://lists.freedesktop.org/mailman/listinfo/amd-gfx">https://lists.freedesktop.org/mailman/listinfo/amd-gfx</a><br>
or, via email, send a message with subject or body 'help' to<br>
amd-gfx-request@lists.freedesktop.org<br>
<br>
You can reach the person managing the list at<br>
amd-gfx-owner@lists.freedesktop.org<br>
<br>
When replying, please edit your Subject line so it is more specific<br>
than "Re: Contents of amd-gfx digest..."<br>
<br>
<br>
Today's Topics:<br>
<br>
1. Re: [PATCH v2 06/27] drm/dp_mst: Combine redundant cases in<br>
drm_dp_encode_sideband_req() (Dave Airlie)<br>
2. [PATCH] drm: add drm device name (Jiang, Sonny)<br>
3. Re: [PATCH v2 11/27] drm/dp_mst: Constify guid in<br>
drm_dp_get_mst_branch_by_guid() (Dave Airlie)<br>
4. Re: [PATCH v2 15/27] drm/dp_mst: Cleanup<br>
drm_dp_send_link_address() a bit (Dave Airlie)<br>
5. RE: [PATCH] drm/amd/powerplay: replace smu->table_count with<br>
SMU_TABLE_COUNT in smu (Quan, Evan)<br>
<br>
<br>
----------------------------------------------------------------------<br>
<br>
Message: 1<br>
Date: Wed, 4 Sep 2019 07:35:59 +1000<br>
From: Dave Airlie <airlied@gmail.com><br>
To: Lyude Paul <lyude@redhat.com><br>
Cc: dri-devel <dri-devel@lists.freedesktop.org>, nouveau<br>
<nouveau@lists.freedesktop.org>, amd-gfx mailing list<br>
<amd-gfx@lists.freedesktop.org>, Sean Paul <sean@poorly.run>, David<br>
Airlie <airlied@linux.ie>, Daniel Vetter <daniel.vetter@ffwll.ch>,<br>
Imre Deak <imre.deak@intel.com>, Maarten Lankhorst<br>
<maarten.lankhorst@linux.intel.com>, LKML<br>
<linux-kernel@vger.kernel.org>, Maxime Ripard <mripard@kernel.org>,<br>
Juston Li <juston.li@intel.com>, Daniel Vetter <daniel@ffwll.ch>,<br>
Harry Wentland <hwentlan@amd.com>, Ville Syrjälä<br>
<ville.syrjala@linux.intel.com><br>
Subject: Re: [PATCH v2 06/27] drm/dp_mst: Combine redundant cases in<br>
drm_dp_encode_sideband_req()<br>
Message-ID:<br>
<CAPM=9tx1vQMEsw4VjDVCbDYFUiaeHNCfP09aiSxnPnucQuB1JQ@mail.gmail.com><br>
Content-Type: text/plain; charset="UTF-8"<br>
<br>
On Wed, 4 Sep 2019 at 06:48, Lyude Paul <lyude@redhat.com> wrote:<br>
><br>
> Noticed this while working on adding a drm_dp_decode_sideband_req().<br>
> DP_POWER_DOWN_PHY/DP_POWER_UP_PHY both use the same struct, so we can<br>
> just combine their cases.<br>
<br>
both use the same struct as enum path resources?<br>
<br>
Since otherwise the patch doesn't make sense.<br>
<br>
With that fixed:<br>
Reviewed-by: Dave Airlie <airlied@redhat.com><br>
<br>
<br>
------------------------------<br>
<br>
Message: 2<br>
Date: Tue, 3 Sep 2019 21:41:10 +0000<br>
From: "Jiang, Sonny" <Sonny.Jiang@amd.com><br>
To: "amd-gfx@lists.freedesktop.org" <amd-gfx@lists.freedesktop.org><br>
Cc: "Jiang, Sonny" <Sonny.Jiang@amd.com><br>
Subject: [PATCH] drm: add drm device name<br>
Message-ID: <20190903214040.2386-1-sonny.jiang@amd.com><br>
Content-Type: text/plain; charset="iso-8859-1"<br>
<br>
Add DRM device name and use DRM_IOCTL_VERSION ioctl drmVersion::desc passing it to user space<br>
instead of unused DRM driver name descriptor.<br>
<br>
Change-Id: I809f6d3e057111417efbe8fa7cab8f0113ba4b21<br>
Signed-off-by: Sonny Jiang <sonny.jiang@amd.com><br>
---<br>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 ++<br>
drivers/gpu/drm/drm_drv.c | 17 +++++++++++++++++<br>
drivers/gpu/drm/drm_ioctl.c | 2 +-<br>
include/drm/drm_device.h | 3 +++<br>
include/drm/drm_drv.h | 1 +<br>
5 files changed, 24 insertions(+), 1 deletion(-)<br>
<br>
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
index 67b09cb2a9e2..8f0971cea363 100644<br>
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
@@ -2809,6 +2809,8 @@ int amdgpu_device_init(struct amdgpu_device *adev,<br>
/* init the mode config */<br>
drm_mode_config_init(adev->ddev);<br>
<br>
+ drm_dev_set_name(adev->ddev, amdgpu_asic_name[adev->asic_type]);<br>
+<br>
r = amdgpu_device_ip_init(adev);<br>
if (r) {<br>
/* failed in exclusive mode due to timeout */<br>
diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c<br>
index 862621494a93..6c33879bb538 100644<br>
--- a/drivers/gpu/drm/drm_drv.c<br>
+++ b/drivers/gpu/drm/drm_drv.c<br>
@@ -802,6 +802,7 @@ void drm_dev_fini(struct drm_device *dev)<br>
mutex_destroy(&dev->struct_mutex);<br>
drm_legacy_destroy_members(dev);<br>
kfree(dev->unique);<br>
+ kfree(dev->name);<br>
}<br>
EXPORT_SYMBOL(drm_dev_fini);<br>
<br>
@@ -1078,6 +1079,22 @@ int drm_dev_set_unique(struct drm_device *dev, const char *name)<br>
}<br>
EXPORT_SYMBOL(drm_dev_set_unique);<br>
<br>
+/**<br>
+ * drm_dev_set_name - Set the name of a DRM device<br>
+ * @dev: device of which to set the name<br>
+ * @name: name to be set<br>
+ *<br>
+ * Return: 0 on success or a negative error code on failure.<br>
+ */<br>
+int drm_dev_set_name(struct drm_device *dev, const char *name)<br>
+{<br>
+ kfree(dev->name);<br>
+ dev->name = kstrdup(name, GFP_KERNEL);<br>
+<br>
+ return dev->name ? 0 : -ENOMEM;<br>
+}<br>
+EXPORT_SYMBOL(drm_dev_set_name);<br>
+<br>
/*<br>
* DRM Core<br>
* The DRM core module initializes all global DRM objects and makes them<br>
diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c<br>
index 2263e3ddd822..61f02965106b 100644<br>
--- a/drivers/gpu/drm/drm_ioctl.c<br>
+++ b/drivers/gpu/drm/drm_ioctl.c<br>
@@ -506,7 +506,7 @@ int drm_version(struct drm_device *dev, void *data,<br>
dev->driver->date);<br>
if (!err)<br>
err = drm_copy_field(version->desc, &version->desc_len,<br>
- dev->driver->desc);<br>
+ dev->name);<br>
<br>
return err;<br>
}<br>
diff --git a/include/drm/drm_device.h b/include/drm/drm_device.h<br>
index 7f9ef709b2b6..e29912c484e4 100644<br>
--- a/include/drm/drm_device.h<br>
+++ b/include/drm/drm_device.h<br>
@@ -123,6 +123,9 @@ struct drm_device {<br>
/** @unique: Unique name of the device */<br>
char *unique;<br>
<br>
+ /** @name: device name */<br>
+ char *name;<br>
+<br>
/**<br>
* @struct_mutex:<br>
*<br>
diff --git a/include/drm/drm_drv.h b/include/drm/drm_drv.h<br>
index 68ca736c548d..f742e2bde467 100644<br>
--- a/include/drm/drm_drv.h<br>
+++ b/include/drm/drm_drv.h<br>
@@ -798,6 +798,7 @@ static inline bool drm_drv_uses_atomic_modeset(struct drm_device *dev)<br>
<br>
<br>
int drm_dev_set_unique(struct drm_device *dev, const char *name);<br>
+int drm_dev_set_name(struct drm_device *dev, const char *name);<br>
<br>
<br>
#endif<br>
-- <br>
2.17.1<br>
<br>
<br>
<br>
------------------------------<br>
<br>
Message: 3<br>
Date: Wed, 4 Sep 2019 07:41:07 +1000<br>
From: Dave Airlie <airlied@gmail.com><br>
To: Lyude Paul <lyude@redhat.com><br>
Cc: dri-devel <dri-devel@lists.freedesktop.org>, nouveau<br>
<nouveau@lists.freedesktop.org>, amd-gfx mailing list<br>
<amd-gfx@lists.freedesktop.org>, Sean Paul <sean@poorly.run>, David<br>
Airlie <airlied@linux.ie>, Daniel Vetter <daniel.vetter@ffwll.ch>,<br>
Imre Deak <imre.deak@intel.com>, Maarten Lankhorst<br>
<maarten.lankhorst@linux.intel.com>, LKML<br>
<linux-kernel@vger.kernel.org>, Maxime Ripard <mripard@kernel.org>,<br>
Juston Li <juston.li@intel.com>, Daniel Vetter <daniel@ffwll.ch>,<br>
Harry Wentland <hwentlan@amd.com>, Ville Syrjälä<br>
<ville.syrjala@linux.intel.com><br>
Subject: Re: [PATCH v2 11/27] drm/dp_mst: Constify guid in<br>
drm_dp_get_mst_branch_by_guid()<br>
Message-ID:<br>
<CAPM=9tz0fdZpfFAfQ0aCQ4D+0XQGm=zqeFKDHPFNwVEUeM1f5g@mail.gmail.com><br>
Content-Type: text/plain; charset="UTF-8"<br>
<br>
On Wed, 4 Sep 2019 at 06:48, Lyude Paul <lyude@redhat.com> wrote:<br>
><br>
> And it's helper, we'll be using this in just a moment.<br>
><br>
<br>
Reviewed-by: Dave Airlie <airlied@redhat.com><br>
<br>
> Cc: Juston Li <juston.li@intel.com><br>
> Cc: Imre Deak <imre.deak@intel.com><br>
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com><br>
> Cc: Harry Wentland <hwentlan@amd.com><br>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch><br>
> Signed-off-by: Lyude Paul <lyude@redhat.com><br>
> ---<br>
> drivers/gpu/drm/drm_dp_mst_topology.c | 4 ++--<br>
> 1 file changed, 2 insertions(+), 2 deletions(-)<br>
><br>
> diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c<br>
> index 43452872efad..b44d3696c09a 100644<br>
> --- a/drivers/gpu/drm/drm_dp_mst_topology.c<br>
> +++ b/drivers/gpu/drm/drm_dp_mst_topology.c<br>
> @@ -2060,7 +2060,7 @@ static struct drm_dp_mst_branch *drm_dp_get_mst_branch_device(struct drm_dp_mst_<br>
><br>
> static struct drm_dp_mst_branch *get_mst_branch_device_by_guid_helper(<br>
> struct drm_dp_mst_branch *mstb,<br>
> - uint8_t *guid)<br>
> + const uint8_t *guid)<br>
> {<br>
> struct drm_dp_mst_branch *found_mstb;<br>
> struct drm_dp_mst_port *port;<br>
> @@ -2084,7 +2084,7 @@ static struct drm_dp_mst_branch *get_mst_branch_device_by_guid_helper(<br>
><br>
> static struct drm_dp_mst_branch *<br>
> drm_dp_get_mst_branch_device_by_guid(struct drm_dp_mst_topology_mgr *mgr,<br>
> - uint8_t *guid)<br>
> + const uint8_t *guid)<br>
> {<br>
> struct drm_dp_mst_branch *mstb;<br>
> int ret;<br>
> --<br>
> 2.21.0<br>
><br>
> _______________________________________________<br>
> amd-gfx mailing list<br>
> amd-gfx@lists.freedesktop.org<br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/amd-gfx">https://lists.freedesktop.org/mailman/listinfo/amd-gfx</a><br>
<br>
<br>
------------------------------<br>
<br>
Message: 4<br>
Date: Wed, 4 Sep 2019 07:42:16 +1000<br>
From: Dave Airlie <airlied@gmail.com><br>
To: Lyude Paul <lyude@redhat.com><br>
Cc: dri-devel <dri-devel@lists.freedesktop.org>, nouveau<br>
<nouveau@lists.freedesktop.org>, amd-gfx mailing list<br>
<amd-gfx@lists.freedesktop.org>, Sean Paul <sean@poorly.run>, David<br>
Airlie <airlied@linux.ie>, Daniel Vetter <daniel.vetter@ffwll.ch>,<br>
Imre Deak <imre.deak@intel.com>, Maarten Lankhorst<br>
<maarten.lankhorst@linux.intel.com>, LKML<br>
<linux-kernel@vger.kernel.org>, Maxime Ripard <mripard@kernel.org>,<br>
Juston Li <juston.li@intel.com>, Daniel Vetter <daniel@ffwll.ch>,<br>
Harry Wentland <hwentlan@amd.com>, Ville Syrjälä<br>
<ville.syrjala@linux.intel.com><br>
Subject: Re: [PATCH v2 15/27] drm/dp_mst: Cleanup<br>
drm_dp_send_link_address() a bit<br>
Message-ID:<br>
<CAPM=9ty-264nFotVRy7VwMw_BQPo-=7su7y3J2MjC9Sdkxcu+A@mail.gmail.com><br>
Content-Type: text/plain; charset="UTF-8"<br>
<br>
On Wed, 4 Sep 2019 at 06:48, Lyude Paul <lyude@redhat.com> wrote:<br>
><br>
> Declare local pointer to the drm_dp_link_address_ack_reply struct<br>
> instead of constantly dereferencing it through the union in<br>
> txmsg->reply. Then, invert the order of conditionals so we don't have to<br>
> do the bulk of the work inside them, and can wrap lines even less. Then<br>
> finally, rearrange variable declarations a bit.<br>
><br>
> Cc: Juston Li <juston.li@intel.com><br>
> Cc: Imre Deak <imre.deak@intel.com><br>
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com><br>
> Cc: Harry Wentland <hwentlan@amd.com><br>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch><br>
> Signed-off-by: Lyude Paul <lyude@redhat.com><br>
<br>
Reviewed-by: Dave Airlie <airlied@redhat.com><br>
<br>
<br>
------------------------------<br>
<br>
Message: 5<br>
Date: Wed, 4 Sep 2019 01:17:19 +0000<br>
From: "Quan, Evan" <Evan.Quan@amd.com><br>
To: "Wang, Kevin(Yang)" <Kevin1.Wang@amd.com>,<br>
"amd-gfx@lists.freedesktop.org" <amd-gfx@lists.freedesktop.org>,<br>
"Huang, Ray" <Ray.Huang@amd.com><br>
Cc: "Wang, Kevin(Yang)" <Kevin1.Wang@amd.com><br>
Subject: RE: [PATCH] drm/amd/powerplay: replace smu->table_count with<br>
SMU_TABLE_COUNT in smu<br>
Message-ID:<br>
<MN2PR12MB3344CB5D45A7FE830BDC4E34E4B80@MN2PR12MB3344.namprd12.prod.outlook.com><br>
<br>
Content-Type: text/plain; charset="utf-8"<br>
<br>
Please drop the table_count member from the smu_table structure as it's totally unused.<br>
With that fixed, the patch is reviewed-by: Evan Quan <evan.quan@amd.com><br>
<br>
> -----Original Message-----<br>
> From: amd-gfx <amd-gfx-bounces@lists.freedesktop.org> On Behalf Of<br>
> Wang, Kevin(Yang)<br>
> Sent: 2019年9月3日 16:17<br>
> To: amd-gfx@lists.freedesktop.org; Huang, Ray <Ray.Huang@amd.com><br>
> Cc: Wang, Kevin(Yang) <Kevin1.Wang@amd.com><br>
> Subject: [PATCH] drm/amd/powerplay: replace smu->table_count with<br>
> SMU_TABLE_COUNT in smu<br>
> <br>
> fix bellow patch issue:<br>
> drm/amd/powerplay: introduce smu table id type to handle the smu table<br>
> for each asic<br>
> ----<br>
> "This patch introduces new smu table type, it's to handle the different smu<br>
> table defines for each asic with the same smu ip."<br>
> <br>
> before:<br>
> use smu->table_count to represent the actual table count in smc firmware<br>
> use actual table count to check smu function parameter about smu table<br>
> after:<br>
> use logic table count "SMU_TABLE_COUNT" to check function parameter<br>
> because table id already mapped in smu driver, and smu function will use<br>
> logic table id not actual table id to check func parameter.<br>
> <br>
> Signed-off-by: Kevin Wang <kevin1.wang@amd.com><br>
> ---<br>
> drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 13 ++++---------<br>
> drivers/gpu/drm/amd/powerplay/arcturus_ppt.c | 1 -<br>
> drivers/gpu/drm/amd/powerplay/navi10_ppt.c | 1 -<br>
> drivers/gpu/drm/amd/powerplay/renoir_ppt.c | 1 -<br>
> drivers/gpu/drm/amd/powerplay/smu_v11_0.c | 5 ++---<br>
> drivers/gpu/drm/amd/powerplay/vega20_ppt.c | 1 -<br>
> 6 files changed, 6 insertions(+), 16 deletions(-)<br>
> <br>
> diff --git a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c<br>
> b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c<br>
> index 6f435d60fe86..c71a82a6a785 100644<br>
> --- a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c<br>
> +++ b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c<br>
> @@ -462,7 +462,7 @@ int smu_update_table(struct smu_context *smu,<br>
> enum smu_table_id table_index, int<br>
> int ret = 0;<br>
> int table_id = smu_table_get_index(smu, table_index);<br>
> <br>
> - if (!table_data || table_id >= smu_table->table_count || table_id < 0)<br>
> + if (!table_data || table_id >= SMU_TABLE_COUNT || table_id < 0)<br>
> return -EINVAL;<br>
> <br>
> table = &smu_table->tables[table_index]; @@ -940,14 +940,10 @@<br>
> static int smu_init_fb_allocations(struct smu_context *smu)<br>
> struct amdgpu_device *adev = smu->adev;<br>
> struct smu_table_context *smu_table = &smu->smu_table;<br>
> struct smu_table *tables = smu_table->tables;<br>
> - uint32_t table_count = smu_table->table_count;<br>
> uint32_t i = 0;<br>
> int32_t ret = 0;<br>
> <br>
> - if (table_count <= 0)<br>
> - return -EINVAL;<br>
> -<br>
> - for (i = 0 ; i < table_count; i++) {<br>
> + for (i = 0; i < SMU_TABLE_COUNT; i++) {<br>
> if (tables[i].size == 0)<br>
> continue;<br>
> ret = amdgpu_bo_create_kernel(adev,<br>
> @@ -978,13 +974,12 @@ static int smu_fini_fb_allocations(struct<br>
> smu_context *smu) {<br>
> struct smu_table_context *smu_table = &smu->smu_table;<br>
> struct smu_table *tables = smu_table->tables;<br>
> - uint32_t table_count = smu_table->table_count;<br>
> uint32_t i = 0;<br>
> <br>
> - if (table_count == 0 || tables == NULL)<br>
> + if (!tables)<br>
> return 0;<br>
> <br>
> - for (i = 0 ; i < table_count; i++) {<br>
> + for (i = 0; i < SMU_TABLE_COUNT; i++) {<br>
> if (tables[i].size == 0)<br>
> continue;<br>
> amdgpu_bo_free_kernel(&tables[i].bo,<br>
> diff --git a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c<br>
> b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c<br>
> index f1f072012fac..6e8eb0f94c8b 100644<br>
> --- a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c<br>
> +++ b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c<br>
> @@ -1934,5 +1934,4 @@ void arcturus_set_ppt_funcs(struct smu_context<br>
> *smu)<br>
> struct smu_table_context *smu_table = &smu->smu_table;<br>
> <br>
> smu->ppt_funcs = &arcturus_ppt_funcs;<br>
> - smu_table->table_count = TABLE_COUNT;<br>
> }<br>
> diff --git a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c<br>
> b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c<br>
> index 744b7501c34d..e3add8b59291 100644<br>
> --- a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c<br>
> +++ b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c<br>
> @@ -1633,5 +1633,4 @@ void navi10_set_ppt_funcs(struct smu_context<br>
> *smu)<br>
> struct smu_table_context *smu_table = &smu->smu_table;<br>
> <br>
> smu->ppt_funcs = &navi10_ppt_funcs;<br>
> - smu_table->table_count = TABLE_COUNT;<br>
> }<br>
> diff --git a/drivers/gpu/drm/amd/powerplay/renoir_ppt.c<br>
> b/drivers/gpu/drm/amd/powerplay/renoir_ppt.c<br>
> index de43159564a5..2b953f7431b6 100644<br>
> --- a/drivers/gpu/drm/amd/powerplay/renoir_ppt.c<br>
> +++ b/drivers/gpu/drm/amd/powerplay/renoir_ppt.c<br>
> @@ -169,5 +169,4 @@ void renoir_set_ppt_funcs(struct smu_context *smu)<br>
> <br>
> smu->ppt_funcs = &renoir_ppt_funcs;<br>
> smu->smc_if_version = SMU12_DRIVER_IF_VERSION;<br>
> - smu_table->table_count = TABLE_COUNT;<br>
> }<br>
> diff --git a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c<br>
> b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c<br>
> index deca9f85764c..3709e4d77338 100644<br>
> --- a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c<br>
> +++ b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c<br>
> @@ -439,7 +439,7 @@ static int smu_v11_0_init_smc_tables(struct<br>
> smu_context *smu)<br>
> struct smu_table *tables = NULL;<br>
> int ret = 0;<br>
> <br>
> - if (smu_table->tables || smu_table->table_count == 0)<br>
> + if (smu_table->tables)<br>
> return -EINVAL;<br>
> <br>
> tables = kcalloc(SMU_TABLE_COUNT, sizeof(struct smu_table), @@ -<br>
> 465,13 +465,12 @@ static int smu_v11_0_fini_smc_tables(struct<br>
> smu_context *smu)<br>
> struct smu_table_context *smu_table = &smu->smu_table;<br>
> int ret = 0;<br>
> <br>
> - if (!smu_table->tables || smu_table->table_count == 0)<br>
> + if (!smu_table->tables)<br>
> return -EINVAL;<br>
> <br>
> kfree(smu_table->tables);<br>
> kfree(smu_table->metrics_table);<br>
> smu_table->tables = NULL;<br>
> - smu_table->table_count = 0;<br>
> smu_table->metrics_table = NULL;<br>
> smu_table->metrics_time = 0;<br>
> <br>
> diff --git a/drivers/gpu/drm/amd/powerplay/vega20_ppt.c<br>
> b/drivers/gpu/drm/amd/powerplay/vega20_ppt.c<br>
> index 899bf96b23e1..68548ba9b6ea 100644<br>
> --- a/drivers/gpu/drm/amd/powerplay/vega20_ppt.c<br>
> +++ b/drivers/gpu/drm/amd/powerplay/vega20_ppt.c<br>
> @@ -3189,5 +3189,4 @@ void vega20_set_ppt_funcs(struct smu_context<br>
> *smu)<br>
> struct smu_table_context *smu_table = &smu->smu_table;<br>
> <br>
> smu->ppt_funcs = &vega20_ppt_funcs;<br>
> - smu_table->table_count = TABLE_COUNT;<br>
> }<br>
> --<br>
> 2.22.0<br>
> <br>
> _______________________________________________<br>
> amd-gfx mailing list<br>
> amd-gfx@lists.freedesktop.org<br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/amd-gfx">https://lists.freedesktop.org/mailman/listinfo/amd-gfx</a><br>
<br>
------------------------------<br>
<br>
Subject: Digest Footer<br>
<br>
_______________________________________________<br>
amd-gfx mailing list<br>
amd-gfx@lists.freedesktop.org<br>
<a href="https://lists.freedesktop.org/mailman/listinfo/amd-gfx">https://lists.freedesktop.org/mailman/listinfo/amd-gfx</a><br>
<br>
------------------------------<br>
<br>
End of amd-gfx Digest, Vol 40, Issue 37<br>
***************************************<br>
</div>
</span></font></div>
</body>
</html>