[PATCH v14 3/6] ui/console: Use qemu_dmabuf_get_..() helpers instead

2024-05-08 Thread dongwon . kim
From: Dongwon Kim This commit updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix typos in helper names in ui/spice-display.c v7: removed prefix, "dpy_gl_" from all helpers v8: In

[PATCH v14 6/6] ui/console: move QemuDmaBuf struct def to dmabuf.c

2024-05-08 Thread dongwon . kim
From: Dongwon Kim To complete privatizing process of QemuDmaBuf, QemuDmaBuf struct def is moved to dmabuf.c Suggested-by: Marc-André Lureau Reviewed-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui

[PATCH v14 0/6] ui/console: Private QemuDmaBuf struct

2024-05-08 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v14 4/6] ui/console: Use qemu_dmabuf_set_..() helpers instead

2024-05-08 Thread dongwon . kim
From: Dongwon Kim This commit updates all occurrences where these fields were set directly have been updated to utilize helper functions. v7: removed prefix, "dpy_gl_" from all helpers v8: Introduction of helpers was removed as those were already added by the previous commit

[PATCH v14 5/6] ui/console: Use qemu_dmabuf_new() and free() helpers instead

2024-05-08 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. v7: remove prefix, "dpy_gl_" from all helpers qemu_d

[PATCH v14 2/6] ui/console: new dmabuf.h and dmabuf.c for QemuDmaBuf struct and helpers

2024-05-08 Thread dongwon . kim
From: Dongwon Kim New header and source files are added for containing QemuDmaBuf struct definition and newly introduced helpers for creating/freeing the struct and accessing its data. v10: Change the license type for both dmabuf.h and dmabuf.c from MIT to GPL to be in line with QEMU's

[PATCH v14 1/6] ui/gtk: Check if fence_fd is equal to or greater than 0

2024-05-08 Thread dongwon . kim
From: Dongwon Kim 'fence_fd' needs to be validated always before being referenced And the passing condition should include '== 0' as 0 is a valid value for the file descriptor. Suggested-by: Marc-André Lureau Reviewed-by: Daniel P. Berrangé Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé

[PATCH v13 1/6] ui/gtk: Check if fence_fd is equal to or greater than 0

2024-05-07 Thread dongwon . kim
From: Dongwon Kim 'fence_fd' needs to be validated always before being referenced And the passing condition should include '== 0' as 0 is a valid value for the file descriptor. Suggested-by: Marc-André Lureau Reviewed-by: Daniel P. Berrangé Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé

[PATCH v13 4/6] ui/console: Use qemu_dmabuf_set_..() helpers instead

2024-05-07 Thread dongwon . kim
From: Dongwon Kim This commit updates all occurrences where these fields were set directly have been updated to utilize helper functions. v7: removed prefix, "dpy_gl_" from all helpers v8: Introduction of helpers was removed as those were already added by the previous commit

[PATCH v13 2/6] ui/console: new dmabuf.h and dmabuf.c for QemuDmaBuf struct and helpers

2024-05-07 Thread dongwon . kim
From: Dongwon Kim New header and source files are added for containing QemuDmaBuf struct definition and newly introduced helpers for creating/freeing the struct and accessing its data. v10: Change the license type for both dmabuf.h and dmabuf.c from MIT to GPL to be in line with QEMU's

[PATCH v13 5/6] ui/console: Use qemu_dmabuf_new() and free() helpers instead

2024-05-07 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. v7: remove prefix, "dpy_gl_" from all helpers qemu_d

[PATCH v13 6/6] ui/console: move QemuDmaBuf struct def to dmabuf.c

2024-05-07 Thread dongwon . kim
From: Dongwon Kim To complete privatizing process of QemuDmaBuf, QemuDmaBuf struct def is moved to dmabuf.c Suggested-by: Marc-André Lureau Reviewed-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui

[PATCH v13 3/6] ui/console: Use qemu_dmabuf_get_..() helpers instead

2024-05-07 Thread dongwon . kim
From: Dongwon Kim This commit updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix typos in helper names in ui/spice-display.c v7: removed prefix, "dpy_gl_" from all helpers v8: In

[PATCH v13 0/6] ui/console: Private QemuDmaBuf struct

2024-05-07 Thread dongwon . kim
dmabuf after it is released to prevent possible leaking of the ptr (Marc-André Lureau ) --- Use g_autoptr macro to define *dmabuf for auto clean up instead of calling qemu_dmabuf_free (Marc-André Lureau ) Dongwon Kim (6): ui/gtk: Check if fence_fd is equal to or gr

[PATCH] ui/gtk: Explicitly set the default size of new window when untabifying

2024-04-30 Thread dongwon . kim
From: Dongwon Kim When untabifying, the default size of the new window was inadvertently set to the size smaller than quarter of the primary window size due to lack of explicit configuration. This commit addresses the issue by ensuring that the size of untabified windows is set to match

[PATCH v2] ui/gtk: Draw guest frame at refresh cycle

2024-04-26 Thread dongwon . kim
From: Dongwon Kim Draw routine needs to be manually invoked in the next refresh if there is a scanout blob from the guest. This is to prevent a situation where there is a scheduled draw event but it won't happen bacause the window is currently in inactive state (minimized or tabified). If draw

[PATCH] ui/gtk: Draw guest frame at refresh cycle

2024-04-25 Thread dongwon . kim
From: Dongwon Kim Draw routine needs to be manually invoked in the next refresh if there is a scanout blob from the guest. This is to prevent a situation where there is a scheduled draw event but it won't happen bacause the window is currently in inactive state (minimized or tabified). If draw

[PATCH v12 4/6] ui/console: Use qemu_dmabuf_set_..() helpers instead

2024-04-24 Thread dongwon . kim
From: Dongwon Kim This commit updates all occurrences where these fields were set directly have been updated to utilize helper functions. v7: removed prefix, "dpy_gl_" from all helpers v8: Introduction of helpers was removed as those were already added by the previous commit

[PATCH v12 2/6] ui/console: new dmabuf.h and dmabuf.c for QemuDmaBuf struct and helpers

2024-04-24 Thread dongwon . kim
From: Dongwon Kim New header and source files are added for containing QemuDmaBuf struct definition and newly introduced helpers for creating/freeing the struct and accessing its data. v10: Change the license type for both dmabuf.h and dmabuf.c from MIT to GPL to be in line with QEMU's

[PATCH v12 5/6] ui/console: Use qemu_dmabuf_new() and free() helpers instead

2024-04-24 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. v7: remove prefix, "dpy_gl_" from all helpers qemu_d

[PATCH v12 6/6] ui/console: move QemuDmaBuf struct def to dmabuf.c

2024-04-24 Thread dongwon . kim
From: Dongwon Kim To complete privatizing process of QemuDmaBuf, QemuDmaBuf struct def is moved to dmabuf.c Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/dmabuf.h | 19 +-- ui

[PATCH v12 0/6] ui/console: Private QemuDmaBuf struct

2024-04-24 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v12 3/6] ui/console: Use qemu_dmabuf_get_..() helpers instead

2024-04-24 Thread dongwon . kim
From: Dongwon Kim This commit updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix typos in helper names in ui/spice-display.c v7: removed prefix, "dpy_gl_" from all helpers v8: In

[PATCH v12 1/6] ui/gtk: Check if fence_fd is equal to or greater than 0

2024-04-24 Thread dongwon . kim
From: Dongwon Kim 'fence_fd' needs to be validated always before being referenced And the passing condition should include '== 0' as 0 is a valid value for the file descriptor. Suggested-by: Marc-André Lureau Reviewed-by: Daniel P. Berrangé Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé

[PATCH v11 2/6] ui/console: new dmabuf.h and dmabuf.c for QemuDmaBuf struct and helpers

2024-04-23 Thread dongwon . kim
From: Dongwon Kim New header and source files are added for containing QemuDmaBuf struct definition and newly introduced helpers for creating/freeing the struct and accessing its data. v10: Change the license type for both dmabuf.h and dmabuf.c from MIT to GPL to be in line with QEMU's

[PATCH v11 6/6] ui/console: move QemuDmaBuf struct def to dmabuf.c

2024-04-23 Thread dongwon . kim
From: Dongwon Kim To complete privatizing process of QemuDmaBuf, QemuDmaBuf struct def is moved to dmabuf.c Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/dmabuf.h | 19 +-- ui

[PATCH v11 5/6] ui/console: Use qemu_dmabuf_new() and free() helpers instead

2024-04-23 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. v7: remove prefix, "dpy_gl_" from all helpers qemu_d

[PATCH v11 3/6] ui/console: Use qemu_dmabuf_get_..() helpers instead

2024-04-23 Thread dongwon . kim
From: Dongwon Kim This commit updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix typos in helper names in ui/spice-display.c v7: removed prefix, "dpy_gl_" from all helpers v8: In

[PATCH v11 1/6] ui/gtk: Check if fence_fd is equal to or greater than 0

2024-04-23 Thread dongwon . kim
From: Dongwon Kim 'fence_fd' needs to be validated always before being referenced And the passing condition should include '== 0' as 0 is a valid value for the file descriptor. Suggested-by: Marc-André Lureau Reviewed-by: Daniel P. Berrangé Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé

[PATCH v11 4/6] ui/console: Use qemu_dmabuf_set_..() helpers instead

2024-04-23 Thread dongwon . kim
From: Dongwon Kim This commit updates all occurrences where these fields were set directly have been updated to utilize helper functions. v7: removed prefix, "dpy_gl_" from all helpers v8: Introduction of helpers was removed as those were already added by the previous commit

[PATCH v11 0/6] ui/console: Private QemuDmaBuf struct

2024-04-23 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v10 3/6] ui/console: Use qemu_dmabuf_get_..() helpers instead

2024-04-22 Thread dongwon . kim
From: Dongwon Kim This commit updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix typos in helper names in ui/spice-display.c v7: removed prefix, "dpy_gl_" from all helpers v8: In

[PATCH v10 5/6] ui/console: Use qemu_dmabuf_new() and free() helpers instead

2024-04-22 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. v7: remove prefix, "dpy_gl_" from all helpers qemu_d

[PATCH v10 2/6] ui/console: new dmabuf.h and dmabuf.c for QemuDmaBuf struct and helpers

2024-04-22 Thread dongwon . kim
From: Dongwon Kim New header and source files are added for containing QemuDmaBuf struct definition and newly introduced helpers for creating/freeing the struct and accessing its data. v10: Change the license type for both dmabuf.h and dmabuf.c from MIT to GPL to be in line with QEMU's

[PATCH v10 4/6] ui/console: Use qemu_dmabuf_set_..() helpers instead

2024-04-22 Thread dongwon . kim
From: Dongwon Kim This commit updates all occurrences where these fields were set directly have been updated to utilize helper functions. v7: removed prefix, "dpy_gl_" from all helpers v8: Introduction of helpers was removed as those were already added by the previous commit

[PATCH v10 0/6] ui/console: Private QemuDmaBuf struct

2024-04-22 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v10 1/6] ui/gtk: Check if fence_fd is equal to or greater than 0

2024-04-22 Thread dongwon . kim
From: Dongwon Kim 'fence_fd' needs to be validated always before being referenced And the passing condition should include '== 0' as 0 is a valid value for the file descriptor. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off

[PATCH v10 6/6] ui/console: move QemuDmaBuf struct def to dmabuf.c

2024-04-22 Thread dongwon . kim
From: Dongwon Kim To complete privatizing process of QemuDmaBuf, QemuDmaBuf struct def is moved to dmabuf.c Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/dmabuf.h | 19 +-- ui

[PATCH v9 2/6] ui/console: new dmabuf.h and dmabuf.c for QemuDmaBuf struct and helpers

2024-04-19 Thread dongwon . kim
From: Dongwon Kim New header and source files are added for containing QemuDmaBuf struct definition and newly introduced helpers for creating/freeing the struct and accessing its data. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy

[PATCH v9 3/6] ui/console: Use qemu_dmabuf_get_..() helpers instead

2024-04-19 Thread dongwon . kim
From: Dongwon Kim This commit updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix typos in helper names in ui/spice-display.c v7: removed prefix, "dpy_gl_" from all helpers v8: In

[PATCH v9 5/6] ui/console: Use qemu_dmabuf_new() and free() helpers instead

2024-04-19 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. v7: remove prefix, "dpy_gl_" from all helpers qemu_d

[PATCH v9 0/6] ui/console: Private QemuDmaBuf struct

2024-04-19 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v9 6/6] ui/console: move QemuDmaBuf struct def to dmabuf.c

2024-04-19 Thread dongwon . kim
From: Dongwon Kim To complete privatizing process of QemuDmaBuf, QemuDmaBuf struct def is moved to dmabuf.c Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/dmabuf.h | 19 +-- ui

[PATCH v9 1/6] ui/gtk: Check if fence_fd is equal to or greater than 0

2024-04-19 Thread dongwon . kim
From: Dongwon Kim 'fence_fd' needs to be validated always before being referenced And the passing condition should include '== 0' as 0 is a valid value for the file descriptor. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off

[PATCH v9 4/6] ui/console: Use qemu_dmabuf_set_..() helpers instead

2024-04-19 Thread dongwon . kim
From: Dongwon Kim This commit updates all occurrences where these fields were set directly have been updated to utilize helper functions. v7: removed prefix, "dpy_gl_" from all helpers v8: Introduction of helpers was removed as those were already added by the previous commit

[PATCH v8 2/6] ui/console: new dmabuf.h and dmabuf.c for QemuDmaBuf struct and helpers

2024-04-19 Thread dongwon . kim
From: Dongwon Kim New header and source files are added for containing QemuDmaBuf struct definition and newly introduced helpers for creating/freeing the struct and accessing its data. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy

[PATCH v8 5/6] ui/console: Use qemu_dmabuf_new() and free() helpers instead

2024-04-19 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. v7: remove prefix, "dpy_gl_" from all helpers qemu_d

[PATCH v8 1/6] ui/gtk: Check if fence_fd is equal to or greater than 0

2024-04-19 Thread dongwon . kim
From: Dongwon Kim 'fence_fd' needs to be validated always before being referenced And the passing condition should include '== 0' as 0 is a valid value for the file descriptor. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off

[PATCH v8 6/6] ui/console: move QemuDmaBuf struct def to dmabuf.c

2024-04-19 Thread dongwon . kim
From: Dongwon Kim To complete privatizing process of QemuDmaBuf, QemuDmaBuf struct def is moved to dmabuf.c Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/dmabuf.h | 19 +-- ui

[PATCH v8 0/6] ui/console: Private QemuDmaBuf struct

2024-04-19 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v8 4/6] ui/console: Use qemu_dmabuf_set_..() helpers instead

2024-04-19 Thread dongwon . kim
From: Dongwon Kim This commit updates all occurrences where these fields were set directly have been updated to utilize helper functions. v7: removed prefix, "dpy_gl_" from all helpers v8: Introduction of helpers was removed as those were already added by the previous commit

[PATCH v8 3/6] ui/console: Use qemu_dmabuf_get_..() helpers instead

2024-04-19 Thread dongwon . kim
From: Dongwon Kim This commit updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix typos in helper names in ui/spice-display.c v7: removed prefix, "dpy_gl_" from all helpers v8: In

[PATCH v7 4/5] ui/console: Introduce qemu_dmabuf_new() and free() helpers

2024-04-18 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. v7: remove prefix, "dpy_gl_" from all helpers qemu_d

[PATCH v7 5/5] ui/dmabuf: New dmabuf.c and dmabuf.h for QemuDmaBuf struct and helpers

2024-04-18 Thread dongwon . kim
From: Dongwon Kim Create new header and source files to encapsulate QemuDmaBuf struct and its data for privatization. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/console.h | 52

[PATCH v7 2/5] ui/console: Introduce qemu_dmabuf_get_..() helpers

2024-04-18 Thread dongwon . kim
From: Dongwon Kim This commit introduces qemu_dmabuf_get_... helpers to extract specific fields from the QemuDmaBuf struct. It also updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix typos

[PATCH v7 3/5] ui/console: Introduce qemu_dmabuf_set_..() helpers

2024-04-18 Thread dongwon . kim
From: Dongwon Kim To enhance security in accessing the QemuDmaBuf struct, new helper functions for setting specific fields within the struct were introduced. And all occurrences where these fields were previously set directly have been updated to utilize these helper functions. v7: removed

[PATCH v7 0/5] ui/console: Private QemuDmaBuf struct

2024-04-18 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v7 1/5] ui/gtk: Check if fence_fd is equal to or greater than 0

2024-04-18 Thread dongwon . kim
From: Dongwon Kim 'fence_fd' needs to be validated always before being referenced And the passing condition should include '== 0' as 0 is a valid value for the file descriptor. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Daniel P. Berrangé Cc: Vivek Kasireddy Signed-off

[PATCH v6 2/3] ui/console: Introduce dpy_gl_qemu_dmabuf_set_..() helpers

2024-04-16 Thread dongwon . kim
From: Dongwon Kim To enhance security in accessing the QemuDmaBuf struct, new helper functions for setting specific fields within the struct were introduced. And all occurrences where these fields were previously set directly have been updated to utilize these helper functions. Suggested

[PATCH v6 0/3] ui/console: Private QemuDmaBuf struct

2024-04-16 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v6 3/3] ui/console: Introduce dpy_gl_qemu_dmabuf_new() and free() helpers

2024-04-16 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Vivek

[PATCH v6 1/3] ui/console: Introduce dpy_gl_qemu_dmabuf_get_..() helpers

2024-04-16 Thread dongwon . kim
From: Dongwon Kim This commit introduces dpy_gl_qemu_dmabuf_get_... helpers to extract specific fields from the QemuDmaBuf struct. It also updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. v6: fix

[PATCH v5 1/3] ui/console: Introduce dpy_gl_qemu_dmabuf_get_..() helpers

2024-04-15 Thread dongwon . kim
From: Dongwon Kim This commit introduces dpy_gl_qemu_dmabuf_get_... helpers to extract specific fields from the QemuDmaBuf struct. It also updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. Suggested

[PATCH v5 3/3] ui/console: Introduce dpy_gl_qemu_dmabuf_new() and free() helpers

2024-04-15 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Vivek

[PATCH v5 0/3] ui/console: Private QemuDmaBuf struct

2024-04-15 Thread dongwon . kim
From: Dongwon Kim This series introduces privacy enhancements to the QemuDmaBuf struct and its contained data to bolster security. it accomplishes this by introducing of helper functions for allocating, deallocating, and accessing individual fields within the struct and replacing all direct

[PATCH v5 2/3] ui/console: Introduce dpy_gl_qemu_dmabuf_set_..() helpers

2024-04-15 Thread dongwon . kim
From: Dongwon Kim To enhance security in accessing the QemuDmaBuf struct, new helper functions for setting specific fields within the struct were introduced. And all occurrences where these fields were previously set directly have been updated to utilize these helper functions. Suggested

[PATCH v5 3/3] ui/console: Introduce dpy_gl_qemu_dmabuf_new() and free() helpers

2024-04-11 Thread dongwon . kim
From: Dongwon Kim This commit introduces utility functions for the creation and deallocation of QemuDmaBuf instances. Additionally, it updates all relevant sections of the codebase to utilize these new utility functions. Suggested-by: Marc-André Lureau Cc: Philippe Mathieu-Daudé Cc: Vivek

[PATCH v5 2/3] ui/console: Introduce dpy_gl_qemu_dmabuf_set_..() helpers

2024-04-11 Thread dongwon . kim
From: Dongwon Kim To enhance security in accessing the QemuDmaBuf struct, new helper functions for setting specific fields within the struct were introduced. And all occurrences where these fields were previously set directly have been updated to utilize these helper functions. Suggested

[PATCH v5 1/3] ui/console: Introduce dpy_gl_qemu_dmabuf_get_..() helpers

2024-04-11 Thread dongwon . kim
From: Dongwon Kim This commit introduces dpy_gl_qemu_dmabuf_get_... helpers to extract specific fields from the QemuDmaBuf struct. It also updates all instances where fields within the QemuDmaBuf struct are directly accessed, replacing them with calls to these new helper functions. Suggested

[PATCH v4 1/3] ui/console: Introduce dpy_gl_dmabuf_get_height/width() helpers

2024-03-21 Thread dongwon . kim
From: Dongwon Kim dpy_gl_dmabuf_get_height() and dpy_gl_dmabuf_get_width() are helpers for retrieving width and height fields from QemuDmaBuf struct. Cc: Philippe Mathieu-Daudé Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/console.h| 2

[PATCH v4 2/3] ui/console: Introduce dpy_gl_dmabuf_get_fd() helper

2024-03-21 Thread dongwon . kim
From: Dongwon Kim dpy_gl_dmabuf_get_fd() is a helper for retrieving FD of the dmabuf from QemuDmaBuf struct. Cc: Philippe Mathieu-Daudé Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/console.h | 1 + hw/vfio/display.c| 8 +++- ui/console.c

[PATCH v4 3/3] ui/console: Introduce dpy_gl_create_dmabuf() helper

2024-03-21 Thread dongwon . kim
From: Dongwon Kim dpy_gl_create_dmabuf() allocates QemuDmaBuf and initialize fields. hw/display modules, hw/vfio and ui/dbus-listener now use this method to create QemuDmaBuf instead of declaring and initializing it on their own. Cc: Philippe Mathieu-Daudé Cc: Marc-André Lureau Cc: Vivek

[PATCH v4 0/3] ui/console: Introduce helpers for creating and

2024-03-21 Thread dongwon . kim
From: Dongwon Kim QemuDmaBuf struct is defined and primarily used by ui/console/gl so it is better to handle its creation, initialization and access within ui/console rather than within hw modules such as hw/display/virtio-gpu, hw/display/vhost-user-gpu and hw/vfio as well as ui/dbus-listener

[PATCH v4] ui/gtk: flush display pipeline before saving vmstate when blob=true

2024-03-20 Thread dongwon . kim
From: Dongwon Kim It is required to ensure the current scanout frame is completed before transitioning guest's run-state to save to prevent potential guest waiting for the response on the resource flush of the old scanout frame upon resume. v2: Giving some time for the fence to be signaled

[PATCH 1/3] hw/virtio: initialize QemuDmaBuf using the function from ui/console

2024-03-20 Thread dongwon . kim
From: Dongwon Kim QemuDmaBuf is an abstraction of dmabuf specifically for ui/console usage. To enhance safety and maintainability, it is needed to centralizes its creation and initialization within ui/console using newly introduced methods. Cc: Philippe Mathieu-Daudé Cc: Marc-André Lureau Cc

[PATCH 2/3] hw/vfio: intialize QemuDmaBuf using the function from ui/console

2024-03-20 Thread dongwon . kim
From: Dongwon Kim QemuDmaBuf is an abstraction of dmabuf specifically for ui/console usage. To enhance safety and maintainability, it is needed to centralizes its creation and initialization within ui/console using newly introduced methods. Cc: Philippe Mathieu-Daudé Cc: Marc-André Lureau Cc

[PATCH 3/3] ui/console: add methods for allocating, intializing and accessing QemuDmaBuf

2024-03-20 Thread dongwon . kim
From: Dongwon Kim This commit introduces new methods within ui/console to handle the allocation, initialization, and field retrieval of QemuDmaBuf. By isolating these operations within ui/console, it enhances safety and encapsulation of the struct. Cc: Philippe Mathieu-Daudé Cc: Marc-André

[PATCH 0/3] ui/console: initialize QemuDmaBuf in ui/console

2024-03-20 Thread dongwon . kim
From: Dongwon Kim QemuDmaBuf struct is defined and primarily used by ui/console/gl so it is better to handle its creation, initialization and access within ui/console rather than within hw modules such as hw/display/virtio-gpu and hw/vfio/display. To achieve this, new methods for allocating

[PATCH] ui/console: initialize QemuDmaBuf from ui/console.

2024-03-19 Thread dongwon . kim
From: Dongwon Kim It is safer to create, initialize, and access all the parameters in QemuDmaBuf from a central location, ui/console, instead of hw/virtio-gpu or hw/vfio modules. Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- hw/display/virtio-gpu-udmabuf.c | 27

[PATCH v2] virtio-gpu: first surface update with blob scanout after resumed

2024-03-06 Thread dongwon . kim
From: Dongwon Kim The guest surface needs to be updated with a blob scanout after resumed from saved vm state if blob is enabled. v2: Rebased Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- hw/display/virtio-gpu.c | 21 ++--- 1 file changed, 14

[PATCH v3] ui/gtk: flush display pipeline before saving vmstate when blob=true

2024-03-06 Thread dongwon . kim
From: Dongwon Kim If the guest state is paused before it gets a response for the current scanout frame submission (resource-flush), it won't flush new frames after being restored as it still waits for the old response, which is accepted as a scanout render done signal. So it's needed to unblock

[PATCH 1/2] ui/gtk: flush display pipeline before saving vmstate when blob=true

2024-03-05 Thread dongwon . kim
From: Dongwon Kim If the guest state is paused before it gets a response for the current scanout frame submission (resource-flush), it won't flush new frames after being restored as it still waits for the old response, which is accepted as a scanout render done signal. So it's needed to unblock

[PATCH 2/2] virtio-gpu: first surface update with blob scanout after resumed

2024-03-05 Thread dongwon . kim
From: Dongwon Kim The guest surface needs to be updated with a blob scanout after resumed from saved vm state if blob is enabled. Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- hw/display/virtio-gpu.c | 21 ++--- 1 file changed, 14 insertions(+), 7

[PATCH 0/3] ui/gtk: introducing vc->visible

2024-01-30 Thread dongwon . kim
From: Dongwon Kim Drawing guest display frames can't be completed while the VC is not in visible state, which could result in timeout in both the host and the guest especially when using blob scanout. Therefore it is needed to update and track the visiblity status of the VC and unblock

[PATCH 1/3] ui/gtk: skip drawing guest scanout when associated VC is invisible

2024-01-30 Thread dongwon . kim
From: Dongwon Kim A new flag "visible" is added to show visibility status of the gfx console. The flag is set to 'true' when the VC is visible but set to 'false' when it is hidden or closed. When the VC is invisible, drawing guest frames should be skipped as it will never be

[PATCH 3/3] ui/gtk: reset visible flag when window is minimized

2024-01-30 Thread dongwon . kim
From: Dongwon Kim Adding a callback for window-state-event that resets the flag, 'visible' when associated window is minimized or restored. When minimizing, it cancels any of queued draw events associated with the VC. Cc: Marc-André Lureau Cc: Gerd Hoffmann Cc: Vivek Kasireddy Signed-off

[PATCH 2/3] ui/gtk: set the ui size to 0 when invisible

2024-01-30 Thread dongwon . kim
From: Dongwon Kim UI size is set to 0 when the VC is invisible, which will prevent the further scanout update by notifying the guest that the display is not in active state. Then it is restored to the original size whenever the VC becomes visible again. Cc: Marc-André Lureau Cc: Gerd Hoffmann

[PATCH v3 1/2] ui/gtk: flush display pipeline before saving vmstate when blob=true

2024-01-23 Thread dongwon . kim
From: Dongwon Kim If the guest state is paused before it gets a response for the current scanout frame submission (resource-flush), it won't flush new frames after being restored as it still waits for the old response, which is accepted as a scanout render done signal. So it's needed to unblock

[PATCH 3/3] virtio-gpu: first surface update with blob scanout after resumed

2023-12-13 Thread Dongwon Kim
The guest surface needs to be updated with a blob scanout after resumed from saved vm state if blob is enabled. Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- hw/display/virtio-gpu.c | 22 +++--- 1 file changed, 15 insertions(+), 7 deletions(-) diff

[PATCH 1/3] ui/gtk: flush display pipeline before saving vmstate when blob=true

2023-12-13 Thread Dongwon Kim
render pipeline before the run state is changed to make sure the guest receives the response for the current frame submission. v2: Giving some time for the fence to be signaled before flushing the pipeline Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- ui/gtk.c

[PATCH 2/3] ui/gtk: unblock pipeline only if fence hasn't been signaled yet

2023-12-13 Thread Dongwon Kim
It is needed to unblock the pipeline only if there is an active dmabuf to be rendered and the fence for it is not yet signaled. Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- ui/gtk.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git

[PATCH] ui/gtk: flush display pipeline before saving vmstate when blob=true

2023-12-04 Thread Dongwon Kim
the current scanout render pipeline before the run state is changed to make sure the guest receives the response for the current frame submission. Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- ui/gtk.c | 12 1 file changed, 12 insertions(+) diff --git a/ui/gtk.c

[PATCH] ui/gtk-egl: apply scale factor when calculating window's dimension

2023-10-12 Thread Dongwon Kim
Scale factor needs to be applied when calculating width/height of the GTK windows. Cc: Marc-André Lureau Signed-off-by: Dongwon Kim --- ui/gtk-egl.c | 14 -- 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/ui/gtk-egl.c b/ui/gtk-egl.c index a1060fd80f..45c7544337

[PATCH] ui/gtk: full-screening all detached windows

2023-10-12 Thread Dongwon Kim
When turning on or off full-screen menu, all detached windows should be full-screened or un-full-screened altogether. Cc: Marc-André Lureau Signed-off-by: Dongwon Kim --- ui/gtk.c | 44 ++-- 1 file changed, 34 insertions(+), 10 deletions(-) diff --git

[PATCH] ui/gtk: set scanout mode in gd_egl/gd_gl_area_scanout_texture

2023-07-24 Thread Dongwon Kim
rted-by: Volker Rümelin Cc: Gerd Hoffmann Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- ui/gtk-egl.c | 1 + ui/gtk-gl-area.c | 1 + 2 files changed, 2 insertions(+) diff --git a/ui/gtk-egl.c b/ui/gtk-egl.c index 4c29ac10d0..a1060fd80f 100644 --- a/ui/gtk-egl

[PATCH] virtio-gpu-udmabuf: correct naming of QemuDmaBuf size properties

2023-07-12 Thread Dongwon Kim
Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- hw/display/virtio-gpu-udmabuf.c | 12 ++-- include/ui/console.h| 4 ++-- ui/dbus-listener.c | 8 ui/egl-helpers.c| 8 ui/gtk-egl.c| 8 ui/gtk

[RFC PATCH v2 6/9] ui/gtk: Add a new parameter to assign connectors/monitors to GFX VCs

2023-07-10 Thread Dongwon Kim
d Hoffmann Cc: Daniel P. Berrangé Cc: Markus Armbruster Cc: Philippe Mathieu-Daudé Cc: Marc-André Lureau Signed-off-by: Vivek Kasireddy Signed-off-by: Dongwon Kim --- include/ui/gtk.h | 1 + qapi/ui.json | 26 - qemu-options.hx | 5 +- ui/gtk.c

[PATCH] ui/gtk: set scanout-mode right before scheduling draw

2023-07-06 Thread Dongwon Kim
: Vivek Kasireddy Signed-off-by: Dongwon Kim --- ui/gtk-egl.c | 2 +- ui/gtk-gl-area.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/gtk-egl.c b/ui/gtk-egl.c index d59b8cd7d7..b0356d1969 100644 --- a/ui/gtk-egl.c +++ b/ui/gtk-egl.c @@ -238,7 +238,6 @@ void

[PATCH] ui/gtk: skip refresh if new dmabuf has been submitted

2023-07-06 Thread Dongwon Kim
Skip refresh if a new dmabuf (guest scanout frame) has already been submitted and ready to be drawn because the scanout will be updated with new frame anyway. Cc: Gerd Hoffmann Cc: Marc-André Lureau Cc: Vivek Kasireddy Signed-off-by: Dongwon Kim --- ui/gtk-egl.c | 4 ui/gtk-gl

[PATCH] virtio-gpu-udmabuf: replacing scanout_width/height with backing_width/height

2023-07-05 Thread Dongwon Kim
-by: Dongwon Kim --- hw/display/virtio-gpu-udmabuf.c | 8 include/ui/console.h| 4 ++-- ui/dbus-listener.c | 4 ++-- ui/egl-helpers.c| 4 ++-- ui/gtk-egl.c| 4 ++-- ui/gtk-gl-area.c| 4 ++-- 6 files changed, 14 insertions

  1   2   3   >