Re: [PATCH] drm/amdgpu: conditionally compile amdgpu's amdkfd files

2018-05-18 Thread Oded Gabbay
On Thu, May 17, 2018 at 12:09 AM, Felix Kuehling wrote: > Hi Oded, > > Thanks for working on this! The Makefile changes look good. > > Instead of checking and calling function pointers in amdgpu_amdkfd_... > functions at runtime, couldn't you just define empty stub functions in > amdgpu_amdkfd.h i

Re: [PATCH] drm/amdgpu: conditionally compile amdgpu's amdkfd files

2018-05-16 Thread Felix Kuehling
Hi Oded, Thanks for working on this! The Makefile changes look good. Instead of checking and calling function pointers in amdgpu_amdkfd_... functions at runtime, couldn't you just define empty stub functions in amdgpu_amdkfd.h if KFD is not enabled? I think that would make the code shorter and re

[PATCH] drm/amdgpu: conditionally compile amdgpu's amdkfd files

2018-05-16 Thread Oded Gabbay
In case CONFIG_HSA_AMD is not chosen, there is no need to compile amdkfd files that reside inside amdgpu dirver. In addition, because amdkfd depends on x86_64 architecture and amdgpu is not, compiling amdkfd files under i386 architecture can cause compiler errors and warnings. This patch modifies