[PATCH 1/5] drm/displayid: Enhance version reporting

Dave Airlie airlied at gmail.com
Tue May 10 01:16:16 UTC 2016


>>> index 623b4e9..042f9fc 100644
>>> --- a/include/drm/drm_displayid.h
>>> +++ b/include/drm/drm_displayid.h
>>> @@ -52,7 +52,8 @@
>>>  #define PRODUCT_TYPE_DIRECT_DRIVE 6
>>>
>>>  struct displayid_hdr {
>>> -    u8 rev;
>>> +    u8 rev:4;
>>> +    u8 ver:4;
>>>      u8 bytes;
>>>      u8 prod_id;
>>>      u8 ext_count;
>>> @@ -60,7 +61,8 @@ struct displayid_hdr {
>>>
>>>  struct displayid_block {
>>>      u8 tag;
>>> -    u8 rev;
>>> +    u8 rev:3;
>>> +    u8 reserved:5;
>>>      u8 num_bytes;
>>>  } __packed;
>>
>> Using bitfields in an architecture independent structure doesn't
>> feel like an entirely good idea to me.
>
> Yeah, this won't work as expected on some architectures.
>
Indeed, I'll drop this for now.

Dave.


More information about the dri-devel mailing list