[Mesa-dev] [PATCH] radv: initialize the trace BO to 0
Samuel Pitoiset
samuel.pitoiset at gmail.com
Thu Sep 14 08:36:31 UTC 2017
On 09/13/2017 04:01 PM, Grazvydas Ignotas wrote:
> Wouldn't it be better to set AMDGPU_GEM_CREATE_VRAM_CLEARED when
> creating the bo? That would need new RADEON_FLAG_* for winsys.
>
> If not, at least make 4096 a define to use for both
> ws->buffer_create() and memset.
I have added a define for the trace BO size.
Thanks!
>
> GraÅžvydas
>
> On Wed, Sep 13, 2017 at 12:26 PM, Samuel Pitoiset
> <samuel.pitoiset at gmail.com> wrote:
>> To avoid random initial values.
>>
>> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
>> ---
>> src/amd/vulkan/radv_debug.c | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/src/amd/vulkan/radv_debug.c b/src/amd/vulkan/radv_debug.c
>> index c004bc436b..1e5c578aae 100644
>> --- a/src/amd/vulkan/radv_debug.c
>> +++ b/src/amd/vulkan/radv_debug.c
>> @@ -65,6 +65,8 @@ radv_init_trace(struct radv_device *device)
>> if (!device->trace_id_ptr)
>> return false;
>>
>> + memset(device->trace_id_ptr, 0, 4096);
>> +
>> ac_vm_fault_occured(device->physical_device->rad_info.chip_class,
>> &device->dmesg_timestamp, NULL);
>>
>> --
>> 2.14.1
>>
>> _______________________________________________
>> mesa-dev mailing list
>> mesa-dev at lists.freedesktop.org
>> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list