[PATCH 01/13] drm/amd/display: Fix compile warnings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Anthony Koo <Anthony.Koo@xxxxxxx>

1. Fix init of integer
2. Fix mixed declarations

Change-Id: Ib6777dc7c59fd6edaf3cc310c4ad1b66874aecad
Signed-off-by: Anthony Koo <anthony.koo at amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng at amd.com>
Acked-by: Harry Wentland <Harry.Wentland at amd.com>
---
 drivers/gpu/drm/amd/display/modules/freesync/freesync.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/modules/freesync/freesync.c b/drivers/gpu/drm/amd/display/modules/freesync/freesync.c
index e0703c588e47..1ee732768f6e 100644
--- a/drivers/gpu/drm/amd/display/modules/freesync/freesync.c
+++ b/drivers/gpu/drm/amd/display/modules/freesync/freesync.c
@@ -208,6 +208,8 @@ bool mod_freesync_add_stream(struct mod_freesync *mod_freesync,
 	struct core_stream *core_stream = NULL;
 	struct core_dc *core_dc = NULL;
 	struct core_freesync *core_freesync = NULL;
+	int persistent_freesync_enable = 0;
+	struct persistent_data_flag flag;
 
 	if (mod_freesync == NULL)
 		return false;
@@ -216,9 +218,6 @@ bool mod_freesync_add_stream(struct mod_freesync *mod_freesync,
 	core_stream = DC_STREAM_TO_CORE(stream);
 	core_dc = DC_TO_CORE(core_freesync->dc);
 
-	int persistent_freesync_enable = 0;
-	struct persistent_data_flag flag;
-
 	flag.save_per_edid = true;
 	flag.save_per_link = false;
 
@@ -779,7 +778,7 @@ bool mod_freesync_get_state(struct mod_freesync *mod_freesync,
 		const struct dc_stream *stream,
 		struct mod_freesync_params *freesync_params)
 {
-	unsigned int index = NULL;
+	unsigned int index = 0;
 	struct core_freesync *core_freesync = NULL;
 
 	if (mod_freesync == NULL)
-- 
2.9.3



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux