Build fix for older libdrm versions.
When building against an older libdrm, the DRM_FORMAT_MOD_LINEAR enum will be missing. It's OK to use DRM_FORMAT_MOD_NONE instead, because this older libdrm has limited DRM_FORMAT_MOD_xx support and not all of the backends actually need it. Change-Id: I0c289c50de4ad1fe5a9b0848961f5bcb75bd4bf8 Reviewed-on: https://chromium-review.googlesource.com/971358 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Tested-by: Alistair Strachan <astrachan@google.com> Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
This commit is contained in:
parent
3381588d35
commit
a50131a710
1 changed files with 4 additions and 0 deletions
|
|
@ -92,6 +92,10 @@ struct backend {
|
|||
|
||||
#define BO_USE_SW_RARELY BO_USE_SW_READ_RARELY | BO_USE_SW_WRITE_RARELY
|
||||
|
||||
#ifndef DRM_FORMAT_MOD_LINEAR
|
||||
#define DRM_FORMAT_MOD_LINEAR DRM_FORMAT_MOD_NONE
|
||||
#endif
|
||||
|
||||
#define LINEAR_METADATA (struct format_metadata) { 0, 1, DRM_FORMAT_MOD_LINEAR }
|
||||
// clang-format on
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue