dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/amd/display: Remove duplicate declaration of dc_state
@ 2021-04-29  3:18 Wan Jiabing
  2021-04-29 12:08 ` Rodrigo Siqueira
  0 siblings, 1 reply; 3+ messages in thread
From: Wan Jiabing @ 2021-04-29  3:18 UTC (permalink / raw)
  To: Harry Wentland, Leo Li, Alex Deucher, Christian König,
	David Airlie, Daniel Vetter, Aric Cyr, Rodrigo Siqueira,
	Qingqing Zhuo, Aurabindo Pillai, Bhawanpreet Lakha, Jacky Liao,
	Meenakshikumar Somasundaram, Nicholas Kazlauskas, Wenjing Liu,
	amd-gfx, dri-devel, linux-kernel
  Cc: kael_w, Wan Jiabing

There are two declarations of struct dc_state here.
The later one is closer to its user. Remove the former duplicate.

Signed-off-by: Wan Jiabing <wanjiabing@vivo.com>
---
 drivers/gpu/drm/amd/display/dc/dc.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h
index 8108b82bac60..cad045db6ea2 100644
--- a/drivers/gpu/drm/amd/display/dc/dc.h
+++ b/drivers/gpu/drm/amd/display/dc/dc.h
@@ -276,8 +276,6 @@ enum surface_update_type {
 /* Forward declaration*/
 struct dc;
 struct dc_plane_state;
-struct dc_state;
-
 
 struct dc_cap_funcs {
 	bool (*get_dcc_compression_cap)(const struct dc *dc,
-- 
2.25.1

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] drm/amd/display: Remove duplicate declaration of dc_state
  2021-04-29  3:18 [PATCH] drm/amd/display: Remove duplicate declaration of dc_state Wan Jiabing
@ 2021-04-29 12:08 ` Rodrigo Siqueira
  2021-04-29 12:31   ` Jiabing Wan
  0 siblings, 1 reply; 3+ messages in thread
From: Rodrigo Siqueira @ 2021-04-29 12:08 UTC (permalink / raw)
  To: Wan Jiabing
  Cc: Jacky Liao, Leo Li, Bhawanpreet Lakha, Qingqing Zhuo,
	Wenjing Liu, linux-kernel, amd-gfx, Nicholas Kazlauskas,
	Meenakshikumar Somasundaram, David Airlie, Aurabindo Pillai,
	dri-devel, Alex Deucher, kael_w, Christian König


[-- Attachment #1.1: Type: text/plain, Size: 916 bytes --]

Hi Wan,

Instead of remove the first dc_state, remove the second one.

Thanks

On 04/29, Wan Jiabing wrote:
> There are two declarations of struct dc_state here.
> The later one is closer to its user. Remove the former duplicate.
> 
> Signed-off-by: Wan Jiabing <wanjiabing@vivo.com>
> ---
>  drivers/gpu/drm/amd/display/dc/dc.h | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h
> index 8108b82bac60..cad045db6ea2 100644
> --- a/drivers/gpu/drm/amd/display/dc/dc.h
> +++ b/drivers/gpu/drm/amd/display/dc/dc.h
> @@ -276,8 +276,6 @@ enum surface_update_type {
>  /* Forward declaration*/
>  struct dc;
>  struct dc_plane_state;
> -struct dc_state;
> -
>  
>  struct dc_cap_funcs {
>  	bool (*get_dcc_compression_cap)(const struct dc *dc,
> -- 
> 2.25.1
> 

-- 
Rodrigo Siqueira
https://siqueira.tech

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 160 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re:Re: [PATCH] drm/amd/display: Remove duplicate declaration of dc_state
  2021-04-29 12:08 ` Rodrigo Siqueira
@ 2021-04-29 12:31   ` Jiabing Wan
  0 siblings, 0 replies; 3+ messages in thread
From: Jiabing Wan @ 2021-04-29 12:31 UTC (permalink / raw)
  To: Rodrigo Siqueira
  Cc: Jacky Liao, Leo Li, Bhawanpreet Lakha, Qingqing Zhuo,
	Wenjing Liu, linux-kernel, amd-gfx, Nicholas Kazlauskas,
	Meenakshikumar Somasundaram, David Airlie, Aurabindo Pillai,
	dri-devel, Alex Deucher, kael_w, Christian König

 
>Hi Wan,
>
>Instead of remove the first dc_state, remove the second one.
>
>Thanks

Hi Rodrigo,

Thanks for your reply.

OK, in fact, there are no functions using struct dc_state between two
struct declarations. So I think removing anyone is OK.
Remove the first one to make it more closer to user.
Remove the second one more secure.
I will send v2. You can choose one of the two.

>On 04/29, Wan Jiabing wrote:
>> There are two declarations of struct dc_state here.
>> The later one is closer to its user. Remove the former duplicate.
>> 
>> Signed-off-by: Wan Jiabing <wanjiabing@vivo.com>
>> ---
>>  drivers/gpu/drm/amd/display/dc/dc.h | 2 --
>>  1 file changed, 2 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h
>> index 8108b82bac60..cad045db6ea2 100644
>> --- a/drivers/gpu/drm/amd/display/dc/dc.h
>> +++ b/drivers/gpu/drm/amd/display/dc/dc.h
>> @@ -276,8 +276,6 @@ enum surface_update_type {
>>  /* Forward declaration*/
>>  struct dc;
>>  struct dc_plane_state;
>> -struct dc_state;
>> -
>>  
>>  struct dc_cap_funcs {
>>  	bool (*get_dcc_compression_cap)(const struct dc *dc,
>> -- 
>> 2.25.1
>> 
>
>-- 
>Rodrigo Siqueira
>https://siqueira.tech

Yours,
Wan Jiabing


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-04-29 12:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-29  3:18 [PATCH] drm/amd/display: Remove duplicate declaration of dc_state Wan Jiabing
2021-04-29 12:08 ` Rodrigo Siqueira
2021-04-29 12:31   ` Jiabing Wan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).