On 11/12/25 14:03, Dmitry Osipenko wrote:
> On 10/27/25 23:53, [email protected] wrote:
>> +    /* store the dmabuf imported object with its params to
>> +     * the restore list
>> +     */
>> +    memcpy(&bo->params, &params, sizeof(params));
> 
> Nit: using memcpy is unnecessary for structs, "bo->params = params"
> would look cleaner

Won't hurt to add helper for adding obj to a restore list since same
code repeats two times.

virtio_gpu_add_object_to_restore_list(struct virtio_gpu_device *vgdev,
                                      struct virtio_gpu_object *bo)
{
  ...
}

-- 
Best regards,
Dmitry

Reply via email to