[Libva] [Libva-intel-driver][PATCH 06/17] Fix curbe length in CMD_MEDIA_CURBE_LOAD on GEN8+

Zhao Yakui yakui.zhao at intel.com
Fri Nov 18 01:19:57 UTC 2016


On 11/18/2016 12:22 AM, Xiang, Haihao wrote:
>
>
>> -----Original Message-----
>> From: Zhao, Yakui
>> Sent: Thursday, November 17, 2016 8:47 PM
>> To: Xiang, Haihao<haihao.xiang at intel.com>
>> Cc: libva at lists.freedesktop.org
>> Subject: Re: [Libva] [Libva-intel-driver][PATCH 06/17] Fix curbe length in
>> CMD_MEDIA_CURBE_LOAD on GEN8+
>>
>> On 11/17/2016 04:35 PM, Xiang, Haihao wrote:
>>> It is multiple of 64 bytes
>>
>> Can we align the size of curbe_buffer when calling the gen8_gpe_context_init?
>>
>
> The size is set by gpe user, so I prefer not to change it in gen8_gpe_context_init().
> or we can add a requirement on the size which must be a multiple of 64 bytes.

Sorry that I am wrong. It only requires that the length in 
MEDIA_CURE_LOAD is aligned to 64 while it is aligned to 32 in 
INTERFACE_DESCRIPTOR_DATA.
So we can't align them in gen8_gpe_context_init or add extra alignment 
requirement.

So this patch is fine to me.

>
>>>
>>> Signed-off-by: Xiang, Haihao<haihao.xiang at intel.com>
>>> ---
>>>    src/i965_gpe_utils.c | 2 +-
>>>    1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/src/i965_gpe_utils.c b/src/i965_gpe_utils.c index
>>> 139ab1b..a6d539b 100644
>>> --- a/src/i965_gpe_utils.c
>>> +++ b/src/i965_gpe_utils.c
>>> @@ -1066,7 +1066,7 @@ gen8_gpe_curbe_load(VADriverContextP ctx,
>>>
>>>        OUT_BATCH(batch, CMD_MEDIA_CURBE_LOAD | (4 - 2));
>>>        OUT_BATCH(batch, 0);
>>> -    OUT_BATCH(batch, gpe_context->curbe.length);
>>> +    OUT_BATCH(batch, ALIGN(gpe_context->curbe.length, 64));
>>>        OUT_BATCH(batch, gpe_context->curbe.offset);
>>>
>>>        ADVANCE_BATCH(batch);
>



More information about the Libva mailing list