Re: [PATCH] hw/display/virtio-gpu: Initialize blob mapping for ATTACH_BACKING

Akihiko Odaki <[email protected]>
Newsgroups gmane.comp.emulators.qemu,gmane.comp.emulators.qemu.stable
Message-ID <[email protected]>
On 2026/07/28 6:36, Michael Tokarev wrote:
> On 7/25/26 10:11, Akihiko Odaki wrote:
>> It is necessary for blob cursor and scanout.
>>
>> Fixes: e0933d91b1cd ("virtio-gpu: Add virtio_gpu_resource_create_blob")
>> Signed-off-by: Akihiko Odaki <[email protected]>
>> ---
>>   hw/display/virtio-gpu.c | 4 ++++
>>   1 file changed, 4 insertions(+)
> 
> Again, is this a qemu-stable material?  From the description
> it's difficult to say what's going on here, it feels like this
> change should be back-ported to the stable branches.

This is another[1] NULL pointer derefence fix; it is a trivial fix that 
can be cleanly backported.

[1] 
https://lore.kernel.org/qemu-devel/[email protected]/

Regards,
Akihiko Odaki

> 
> Thanks,
> 
> /mjt
> 
>> diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c
>> index 718ba3039290..e886298ec42f 100644
>> --- a/hw/display/virtio-gpu.c
>> +++ b/hw/display/virtio-gpu.c
>> @@ -984,6 +984,10 @@ virtio_gpu_resource_attach_backing(VirtIOGPU *g,
>>           cmd->error = VIRTIO_GPU_RESP_ERR_UNSPEC;
>>           return;
>>       }
>> +
>> +    if (!res->image) {
>> +        virtio_gpu_init_udmabuf(res);
>> +    }
>>   }
>>   static void
>>
>> ---
>> base-commit: 006a22cb26998998385b104db1ff9466ef2f3153
>> change-id: 20260725-backing-db0e69515455
>>
>> Best regards,
>> -- 
>> Akihiko Odaki <[email protected]>
>>
>>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.