Skip to contentSkip to conversation

drm/amd/display: fix compilation error

PATCH In review Hariprasad Kelam 4 participants 6 messages Jun 13, 2019

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/amd/display: fix compilation error

this patch fixes below compilation error

drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c: In function ‘dcn10_apply_ctx_for_surface’:
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c:2378:3:
error: implicit declaration of function ‘udelay’ [-Werror=implicit-function-declaration]
udelay(underflow_check_delay_us);

---
 drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c +1 -0
index d2352949..1ac9a4f 100644
@@ -23,6 +23,7 @@
  *
  */
 
+#include <linux/delay.h>
 #include "dm_services.h"
 #include "core_types.h"
 #include "resource.h"
Signature · 6 lines
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
#1 lore raw
Quoted 11 lines · Hariprasad Kelam

this patch fixes below compilation error

drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c: In function ‘dcn10_apply_ctx_for_surface’:
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c:2378:3:
error: implicit declaration of function ‘udelay’ [-Werror=implicit-function-declaration]
udelay(underflow_check_delay_us);

What branch is this patch based on?

Alex

Quoted 19 lines
---
 drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c +1 -1
index d2352949..1ac9a4f 100644
@@ -23,6 +23,7 @@
  *
  */
 
+#include <linux/delay.h>
 #include "dm_services.h"
 #include "core_types.h"
 #include "resource.h"
--

2.7.4

Quoted 4 lines

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#2 lore raw
Quoted 12 lines · Alex Deucher
Quoted 10 lines · Hariprasad Kelam

this patch fixes below compilation error

drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c: In function ‘dcn10_apply_ctx_for_surface’:
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c:2378:3:
error: implicit declaration of function ‘udelay’ [-Werror=implicit-function-declaration]
udelay(underflow_check_delay_us);

Quoted 5 lines
Quoted 1 line

What branch is this patch based on?

Alex

Hi Alex,

It is on linux-next

Thanks,
Hariprasad k

Quoted 19 lines
Quoted 19 lines
---
 drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c +1 -1
index d2352949..1ac9a4f 100644
@@ -23,6 +23,7 @@
  *
  */
 
+#include <linux/delay.h>
 #include "dm_services.h"
 #include "core_types.h"
 #include "resource.h"
--

2.7.4

Quoted 4 lines
Quoted 4 lines

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

#3 lore raw
Quoted 15 lines · Hariprasad Kelam
Quoted 14 lines · Alex Deucher
Quoted 11 lines · Hariprasad Kelam

this patch fixes below compilation error

drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c: In function ‘dcn10_apply_ctx_for_surface’:
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c:2378:3:
error: implicit declaration of function ‘udelay’ [-Werror=implicit-function-declaration]
udelay(underflow_check_delay_us);

Quoted 7 lines
Quoted 3 lines

What branch is this patch based on?

Alex

Hi Alex,

It is on linux-next

drm-misc-next has Sam's header cleanup. I guess we pull linux/delay.h in implicitly somewhere, but not for all configs.
-Daniel

Quoted 26 lines

Thanks,
Hariprasad k

Quoted 23 lines
Quoted 23 lines
---
 drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c +1 -1
index d2352949..1ac9a4f 100644
@@ -23,6 +23,7 @@
  *
  */
 
+#include <linux/delay.h>
 #include "dm_services.h"
 #include "core_types.h"
 #include "resource.h"
--

2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

Signature · 7 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#4 lore raw
In reply to Alex Deucher

Hi Alex.

Quoted 5 lines · Alex Deucher
Quoted 3 lines · Hariprasad Kelam

this patch fixes below compilation error

Quoted 8 lines
Quoted 8 lines

drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c: In function ‘dcn10_apply_ctx_for_surface’:
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c:2378:3:
error: implicit declaration of function ‘udelay’ [-Werror=implicit-function-declaration]
udelay(underflow_check_delay_us);

Am I right in assuming you took this patch?

I expect that new code using udelay was added to the amd tree, and when merged with drm-misc-next it failed, because drm-misc-next no longer had drmP.h included so no implicit include of delay.h

The root cause was that my original patchset should have been based on the amd tree, and applied there :-(

Sam
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

#5 lore raw
Quoted 18 lines · Sam Ravnborg

Hi Alex.

Quoted 5 lines · Alex Deucher
Quoted 3 lines · Hariprasad Kelam

this patch fixes below compilation error

Quoted 8 lines
Quoted 8 lines

drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c: In function ‘dcn10_apply_ctx_for_surface’:
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn10/dcn10_hw_sequencer.c:2378:3:
error: implicit declaration of function ‘udelay’ [-Werror=implicit-function-declaration]
udelay(underflow_check_delay_us);

Quoted 8 lines

Am I right in assuming you took this patch?

I expect that new code using udelay was added to the amd tree, and when merged with drm-misc-next it failed, because drm-misc-next no longer had drmP.h included so no implicit include of delay.h

The root cause was that my original patchset should have been based on the amd tree, and applied there :-(

No worries. I've picked it up.

Alex