Skip to contentSkip to conversation

kselftests/dmabuf-heaps: Fix compiler error in one condition

PATCH In review Xiao Yang 3 participants 5 messages Nov 1, 2019 – Nov 7, 2019

Subsystems (2)
lore
Share & tools
lore

Xiao Yang

author
#0 lore raw

PATCH 1/1 kselftests/dmabuf-heaps: Fix compiler error in one condition

Compiling dmabuf-heaps cannot locate headers and then gets the following error when kernel source code instead of system provides headers:
-------------------------------------------
dmabuf-heap.c:16:10: fatal error: drm/drm.h: No such file or directory
-------------------------------------------

---
 tools/testing/selftests/dmabuf-heaps/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tools/testing/selftests/dmabuf-heaps/Makefile +1 -1
index 8c4c36e2972d..9043e0b5a432 100644
@@ -1,5 +1,5 @@
 # SPDX-License-Identifier: GPL-2.0
-CFLAGS += -static -O3 -Wl,-no-as-needed -Wall
+CFLAGS += -static -O3 -Wl,-no-as-needed -Wall -I../../../../usr/include
 #LDLIBS += -lrt -lpthread -lm
 
 # these are all "safe" tests that don't modify
Signature · 1 line
2.21.0
author
#1 lore raw

Hi,

If you fix the issue, kindly add following tag

Quoted 22 lines · Xiao Yang

Compiling dmabuf-heaps cannot locate headers and then gets the following error when kernel source code instead of system provides headers:
-------------------------------------------
dmabuf-heap.c:16:10: fatal error: drm/drm.h: No such file or directory
-------------------------------------------

---
  tools/testing/selftests/dmabuf-heaps/Makefile | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
tools/testing/selftests/dmabuf-heaps/Makefile +1 -1
index 8c4c36e2972d..9043e0b5a432 100644
@@ -1,5 +1,5 @@
  # SPDX-License-Identifier: GPL-2.0
-CFLAGS += -static -O3 -Wl,-no-as-needed -Wall
+CFLAGS += -static -O3 -Wl,-no-as-needed -Wall -I../../../../usr/include
  #LDLIBS += -lrt -lpthread -lm
 
  # these are all "safe" tests that don't modify
maintainer
#2 lore raw
Quoted 5 lines · Xiao Yang

Hi,

If you fix the issue, kindly add following tag

Do you plan to send another patch? I don't understand if this meant you think this patch doesn't fix the problem?

Quoted 12 lines · Xiao Yang
Quoted 11 lines

Compiling dmabuf-heaps cannot locate headers and then gets the following error when kernel source code instead of system provides headers:
-------------------------------------------
dmabuf-heap.c:16:10: fatal error: drm/drm.h: No such file or directory
-------------------------------------------

---
  tools/testing/selftests/dmabuf-heaps/Makefile | 2 +-

  1 file changed, 1 insertion(+), 1 deletion(-)
Quoted 12 lines

tools/testing/selftests/dmabuf-heaps/Makefile line 4

Quoted 10 lines
tools/testing/selftests/dmabuf-heaps/Makefile +1 -1
index 8c4c36e2972d..9043e0b5a432 100644
@@ -1,5 +1,5 @@
   # SPDX-License-Identifier: GPL-2.0
-CFLAGS += -static -O3 -Wl,-no-as-needed -Wall
+CFLAGS += -static -O3 -Wl,-no-as-needed -Wall -I../../../../usr/include
   #LDLIBS += -lrt -lpthread -lm
   # these are all "safe" tests that don't modify

thanks,
-- Shuah

#3 lore raw
Quoted 10 lines · shuah
Quoted 5 lines · Xiao Yang

Hi,

If you fix the issue, kindly add following tag

Do you plan to send another patch? I don't understand if this meant you think this patch doesn't fix the problem?

I've actually folded in the fix into my patches.

thanks
-john

maintainer
#4 lore raw
Quoted 8 lines · John Stultz
Quoted 7 lines · shuah
Quoted 5 lines · Xiao Yang

Hi,

If you fix the issue, kindly add following tag

Quoted 9 lines
Quoted 3 lines

Do you plan to send another patch? I don't understand if this meant you think this patch doesn't fix the problem?

I've actually folded in the fix into my patches.

thanks
-john

Thanks for the clarification.

-- Shuah