Skip to content

ac: Only use our own amdgpu type definitions if amdgpu.h isn't included

Michel Dänzer requested to merge daenzer/mesa:ac-amdgpu.h into master

In order to enforce this, use a bogus definition of amdgpu_device_handle, so places which include amdgpu.h after ac_gpu_info.h fail to compile. Fix up the places where this was the case.

The motivation is that amdgpu_device_handle is supposed to be an opaque type, and future versions of libdrm_amdgpu may define it differently, in which case the Mesa build would break without this.

Cc: mesa-stable@lists.freedesktop.org

/cc @mareko @evelikov @bnieuwenhuizen

Merge request reports