[Mesa-dev] [PATCH 02/27] gbm: Fix width height getters return type (trivial)

Daniel Stone daniel at fooishbar.org
Fri Dec 2 18:07:22 UTC 2016


Hi,

On 2 December 2016 at 17:56, Eric Engestrom <eric.engestrom at imgtec.com> wrote:
> On Thursday, 2016-12-01 14:09:43 -0800, Ben Widawsky wrote:
>> --- a/src/gbm/main/gbm.h
>> +++ b/src/gbm/main/gbm.h
>> @@ -294,10 +294,10 @@ gbm_bo_map(struct gbm_bo *bo,
>>  void
>>  gbm_bo_unmap(struct gbm_bo *bo, void *map_data);
>>
>> -uint32_t
>> +unsigned int
>>  gbm_bo_get_width(struct gbm_bo *bo);
>>
>> -uint32_t
>> +unsigned int
>>  gbm_bo_get_height(struct gbm_bo *bo);
>
> I'm not sure I understand this change. Why would you want to remove the
> information of the type size? If the point is to increase it on 64-bit
> machines, I'd go with an explicit `uint64_t` instead.

I have to admit I didn't catch this one. It doesn't help on 64-bit
since unsigned int is still 32-bit there, and in any case it's library
ABI, so if it doesn't change anything then it doesn't help, and if it
does then it's an ABI break, so NAK from me.

Cheers,
Daniel


More information about the mesa-dev mailing list