Mir

Code review comment for lp://staging/~kdub/mir/gbm-ext-v2

Revision history for this message
Chris Halse Rogers (raof) wrote :

This:
- gbm_buffer{allocate_buffer_gbm},
+ gbm_buffer1{allocate_buffer_gbm},
+ gbm_buffer2{allocate_buffer_gbm, allocate_buffer_gbm_sync,
+ is_gbm_importable, import_fd, buffer_stride, buffer_format, buffer_flags, buffer_age},

is unnecessary; just change the type of gbm_buffer to MirExtensionGbmBufferV2.

Likewise,

     if (!strcmp(extension_name, "mir_extension_gbm_buffer") && (version == 1))
- return &gbm_buffer;
+ return &gbm_buffer1;
+ if (!strcmp(extension_name, "mir_extension_gbm_buffer") && (version == 2))
+ return &gbm_buffer2;

Is unnecessary; just check for version <= 2, and return gbm_buffer.

Otherwise looks good!

review: Needs Fixing

« Back to merge proposal