All of lore.kernel.org
 help / color / mirror / Atom feed
From: <sunpeng.li-5C7GfCeVMHo@public.gmane.org>
To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Cc: Josip Pavic <Josip.Pavic-5C7GfCeVMHo@public.gmane.org>
Subject: [PATCH 08/20] drm/amd/display: Update DMCU versioning mechanism
Date: Tue, 22 Jan 2019 13:28:54 -0500	[thread overview]
Message-ID: <1548181746-23783-9-git-send-email-sunpeng.li@amd.com> (raw)
In-Reply-To: <1548181746-23783-1-git-send-email-sunpeng.li-5C7GfCeVMHo@public.gmane.org>

From: Josip Pavic <Josip.Pavic@amd.com>

[Why]
Current date based versioning doesn't tell us about feature version
and build version, and is not useful for debug.

[How]
Add versioning based on feature and build

Signed-off-by: Josip Pavic <Josip.Pavic@amd.com>
Reviewed-by: Anthony Koo <Anthony.Koo@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
---
 drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c             | 6 +++---
 drivers/gpu/drm/amd/display/dc/inc/hw/dmcu.h              | 6 +++---
 drivers/gpu/drm/amd/display/modules/power/power_helpers.c | 9 ++++-----
 3 files changed, 10 insertions(+), 11 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c
index e927c89..c2926cf 100644
--- a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c
+++ b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c
@@ -331,10 +331,10 @@ static void dcn10_get_dmcu_version(struct dmcu *dmcu)
 	/* Write address to IRAM_RD_ADDR and read from DATA register */
 	REG_WRITE(DMCU_IRAM_RD_CTRL, dmcu_version_offset);
 	dmcu->dmcu_version.interface_version = REG_READ(DMCU_IRAM_RD_DATA);
-	dmcu->dmcu_version.year = ((REG_READ(DMCU_IRAM_RD_DATA) << 8) |
+	dmcu->dmcu_version.abm_version = REG_READ(DMCU_IRAM_RD_DATA);
+	dmcu->dmcu_version.psr_version = REG_READ(DMCU_IRAM_RD_DATA);
+	dmcu->dmcu_version.build_version = ((REG_READ(DMCU_IRAM_RD_DATA) << 8) |
 						REG_READ(DMCU_IRAM_RD_DATA));
-	dmcu->dmcu_version.month = REG_READ(DMCU_IRAM_RD_DATA);
-	dmcu->dmcu_version.date = REG_READ(DMCU_IRAM_RD_DATA);
 
 	/* Disable write access to IRAM to allow dynamic sleep state */
 	REG_UPDATE_2(DMCU_RAM_ACCESS_CTRL,
diff --git a/drivers/gpu/drm/amd/display/dc/inc/hw/dmcu.h b/drivers/gpu/drm/amd/display/dc/inc/hw/dmcu.h
index ed32a75..cbaa438 100644
--- a/drivers/gpu/drm/amd/display/dc/inc/hw/dmcu.h
+++ b/drivers/gpu/drm/amd/display/dc/inc/hw/dmcu.h
@@ -39,10 +39,10 @@ enum dmcu_state {
 };
 
 struct dmcu_version {
-	unsigned int date;
-	unsigned int month;
-	unsigned int year;
 	unsigned int interface_version;
+	unsigned int abm_version;
+	unsigned int psr_version;
+	unsigned int build_version;
 };
 
 struct dmcu {
diff --git a/drivers/gpu/drm/amd/display/modules/power/power_helpers.c b/drivers/gpu/drm/amd/display/modules/power/power_helpers.c
index 89b082b..5432183 100644
--- a/drivers/gpu/drm/amd/display/modules/power/power_helpers.c
+++ b/drivers/gpu/drm/amd/display/modules/power/power_helpers.c
@@ -87,11 +87,10 @@ struct iram_table_v_2 {
 
 	/* For reading PSR State directly from IRAM */
 	uint8_t psr_state;						/* 0xf0       */
-	uint8_t dmcu_interface_version;					/* 0xf1       */
-	uint8_t dmcu_date_version_year_b0;				/* 0xf2       */
-	uint8_t dmcu_date_version_year_b1;				/* 0xf3       */
-	uint8_t dmcu_date_version_month;				/* 0xf4       */
-	uint8_t dmcu_date_version_day;					/* 0xf5       */
+	uint8_t dmcu_mcp_interface_version;							/* 0xf1       */
+	uint8_t dmcu_abm_feature_version;							/* 0xf2       */
+	uint8_t dmcu_psr_feature_version;							/* 0xf3       */
+	uint16_t dmcu_version;										/* 0xf4       */
 	uint8_t dmcu_state;						/* 0xf6       */
 
 	uint16_t blRampReduction;					/* 0xf7       */
-- 
2.7.4

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

  parent reply	other threads:[~2019-01-22 18:28 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-22 18:28 [PATCH 00/20] DC Patches Jan 22, 2019 sunpeng.li-5C7GfCeVMHo
     [not found] ` <1548181746-23783-1-git-send-email-sunpeng.li-5C7GfCeVMHo@public.gmane.org>
2019-01-22 18:28   ` [PATCH 01/20] drm/amd/display: Restructure DCN10 hubbub sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` [PATCH 02/20] drm/amd/display: Introduce DC VM interface sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` [PATCH 03/20] drm/amd/display: Simplify underscan and ABM commit sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` [PATCH 04/20] drm/amd/display: Know what a pageflip is sunpeng.li-5C7GfCeVMHo
     [not found]     ` <1548181746-23783-5-git-send-email-sunpeng.li-5C7GfCeVMHo@public.gmane.org>
2019-01-23  9:20       ` Michel Dänzer
2019-01-23 16:08       ` Grodzovsky, Andrey
     [not found]         ` <f91f0b7f-6a8c-2efb-ed5d-7fb0d6e38bab-5C7GfCeVMHo@public.gmane.org>
2019-01-23 19:23           ` Kazlauskas, Nicholas
2019-01-22 18:28   ` [PATCH 05/20] drm/amd/display: Call into DC once per multiplane flip sunpeng.li-5C7GfCeVMHo
     [not found]     ` <1548181746-23783-6-git-send-email-sunpeng.li-5C7GfCeVMHo@public.gmane.org>
2019-01-28 11:59       ` Michel Dänzer
     [not found]         ` <90388e58-87dc-2033-5c36-cf9c903d6b0b-otUistvHUpPR7s880joybQ@public.gmane.org>
2019-01-28 13:47           ` Kazlauskas, Nicholas
2019-01-22 18:28   ` [PATCH 06/20] drm/amd/display: Let updates with no scaling changes be fast sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` [PATCH 07/20] drm/amd/display: Perform plane updates only when needed sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` sunpeng.li-5C7GfCeVMHo [this message]
2019-01-22 18:28   ` [PATCH 09/20] drm/amd/display: Create switching mechanism for ABM 2.2 sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` [PATCH 10/20] drm/amd/display: Fix use of uninitialized union sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` [PATCH 11/20] drm/amd/display: Default to linear output gamma sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` [PATCH 12/20] drm/amd/display: Adjust ABM 2.2 contrast parameters sunpeng.li-5C7GfCeVMHo
2019-01-22 18:28   ` [PATCH 13/20] revert "drm/amd/display: Add condition to sync eDP SW status and HW status" sunpeng.li-5C7GfCeVMHo
2019-01-22 18:29   ` [PATCH 14/20] drm/amd/display: take dpms_off into account for edp turn off logic sunpeng.li-5C7GfCeVMHo
2019-01-22 18:29   ` [PATCH 15/20] drm/amd/display: 3.2.15 sunpeng.li-5C7GfCeVMHo
2019-01-22 18:29   ` [PATCH 16/20] drm/amd/display: Connect dig_fe to otg directly instead of calling bios sunpeng.li-5C7GfCeVMHo
2019-01-22 18:29   ` [PATCH 17/20] drm/amd/display: Poll pending down rep before clear payload allocation table sunpeng.li-5C7GfCeVMHo
2019-01-22 18:29   ` [PATCH 18/20] drm/amd/display: Enable vblank interrupt during CRC capture sunpeng.li-5C7GfCeVMHo
2019-01-22 18:29   ` [PATCH 19/20] drm/amd/display: Re-enable CRC capture following modeset sunpeng.li-5C7GfCeVMHo
2019-01-22 18:29   ` [PATCH 20/20] drm/amd/display: Add Vline1 interrupt source to InterruptManager sunpeng.li-5C7GfCeVMHo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1548181746-23783-9-git-send-email-sunpeng.li@amd.com \
    --to=sunpeng.li-5c7gfcevmho@public.gmane.org \
    --cc=Josip.Pavic-5C7GfCeVMHo@public.gmane.org \
    --cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.