)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"fd7c416702247eb5d70ca7f532c69351a05d9172","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"b80341b1_7151c137","updated":"2023-10-18 08:18:09.000000000","message":"my devstack seems happy with this patch https://paste.opendev.org/show/bBKFG3Vg7YTQBHPz11Za/","commit_id":"c14a1f5fc47ddbee362666600e5d28afa462deb3"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"111691e130458337a1e36eeac16a6d2845b0eacf","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":11,"id":"6c441900_d24d8542","updated":"2025-05-22 06:49:31.000000000","message":"i do not know whre the bug is but there is something wrong in this patche that can cause 2 domains to try and use the same device when using mtty/mdpy devices.\n\ni rebased and reorded the seriese to put my pathc on the bottom because it fixed the  ci failure you were hiting but test still fialed becasue of the same device being allocated to two domains.","commit_id":"36baca4569c08ddbe5bf7a67161ae3be7583e387"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"a96c31d57617069eb4ab7625aa39b0c1755b8145","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":11,"id":"418c4c44_b37dfd31","in_reply_to":"6c441900_d24d8542","updated":"2026-06-17 13:55:18.000000000","message":"Done","commit_id":"36baca4569c08ddbe5bf7a67161ae3be7583e387"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"fbb2758728702d19efbad56a9af4c133d2672882","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"8f69c3b0_7ff774f8","updated":"2026-06-17 13:31:00.000000000","message":"recheck post failures are not related","commit_id":"5f9feb73cc602b5dd008b5e87cf58e5bafac3b58"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"4934f7e223dec1b5598fd313770357ffa7952c7d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"6ca25467_4c156205","updated":"2026-06-17 13:27:01.000000000","message":"we could also update the commit messate for the fact this is unfortully realy only mtty not mdpy","commit_id":"5f9feb73cc602b5dd008b5e87cf58e5bafac3b58"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"02eba10512cb1c96de60bca3cac9c3cf0c398998","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":15,"id":"92d8ca17_7fbd9941","updated":"2026-06-23 02:14:10.000000000","message":"If I understand correctly, in order to test with mtty we need to be able to support both normal mdevs and virtual mdevs in the driver. On my first impression, the code feels a bit hard to parse as a reader or maintainer that the point is virtual mdev need some different logic than normal mdev.\n\nI wonder if a few simple organization suggestions inline could make it a bit easier to understand at a faster glance.","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"6878481dc309a2a9f1845527b9d3781211fb16f8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":15,"id":"f237ab6b_05396b47","updated":"2026-06-17 16:17:19.000000000","message":"recheck unrelated test failed with ConnectionError","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"a520055ff75fbb397da054d5044865c8ed91afa6","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"80f56bdc_a44576af","updated":"2026-06-23 17:06:31.000000000","message":"Nice improvement, LGTM","commit_id":"f412fac1ae1e78e91b8b7c2c4b0cf2be4f63ceb2"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"b8779f7e9d00cdbad30f54777fb6411f9e7eae67","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"580ade84_fe02388f","updated":"2026-07-01 10:10:03.000000000","message":"thansk this look good to me\ni agree that facoting out the fucntion has helped","commit_id":"f412fac1ae1e78e91b8b7c2c4b0cf2be4f63ceb2"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"225e2efc4dea32971716cb763ba2d7f034f18963","unresolved":true,"context_lines":[{"line_number":242,"context_line":""},{"line_number":243,"context_line":"VGPU_RESOURCE_SEMAPHORE \u003d \u0027vgpu_resources\u0027"},{"line_number":244,"context_line":""},{"line_number":245,"context_line":"VGPU_VIRTUAL_SENTINELS \u003d [\u0027mtty\u0027, \u0027mdpy\u0027]"},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"LIBVIRT_PERF_EVENT_PREFIX \u003d \u0027VIR_PERF_PARAM_\u0027"},{"line_number":248,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"c5cbab23_e75ec729","line":245,"updated":"2023-10-18 13:35:55.000000000","message":"i dont want use to hardcode which virtual mdev moduels  we supprot as i dont want ot have to extend this on an ongoing basis.\n\nso can we make this dymic by either checkign for types in sysfs or make this a config option in the device section\noptionall with this as the default\n\nwe can check in sysfs liek this \nbut im not sure we want to do that in nova \nls /sys/devices/virtual/*/*/mdev_supported_types/ | grep -v \":\" | xargs\n\nwhich is why i have a small prefernce for a cofnig option in the devices section.","commit_id":"c14a1f5fc47ddbee362666600e5d28afa462deb3"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"226c423eace31df004e5c1d7f163994597b67ed5","unresolved":false,"context_lines":[{"line_number":242,"context_line":""},{"line_number":243,"context_line":"VGPU_RESOURCE_SEMAPHORE \u003d \u0027vgpu_resources\u0027"},{"line_number":244,"context_line":""},{"line_number":245,"context_line":"VGPU_VIRTUAL_SENTINELS \u003d [\u0027mtty\u0027, \u0027mdpy\u0027]"},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"LIBVIRT_PERF_EVENT_PREFIX \u003d \u0027VIR_PERF_PARAM_\u0027"},{"line_number":248,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"e152d978_0ec91386","line":245,"in_reply_to":"c5cbab23_e75ec729","updated":"2024-05-07 06:30:55.000000000","message":"Done","commit_id":"c14a1f5fc47ddbee362666600e5d28afa462deb3"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"eb281f631c98986233b93724e38e61b96feabca8","unresolved":true,"context_lines":[{"line_number":8657,"context_line":"                try:"},{"line_number":8658,"context_line":"                    pci_utils.parse_address(device_address)"},{"line_number":8659,"context_line":"                except exception.PciDeviceWrongAddressFormat:"},{"line_number":8660,"context_line":"                    # Meh, that\u0027s fine, this is maybe a virtual address"},{"line_number":8661,"context_line":"                    # if so, the address should be something like mtty_mtty"},{"line_number":8662,"context_line":"                    device_path \u003d device_address.replace(\u0027_\u0027, \u0027/\u0027)"},{"line_number":8663,"context_line":"                    if not os.path.exists("}],"source_content_type":"text/x-python","patch_set":13,"id":"eee94040_83cf0164","line":8660,"updated":"2026-06-12 15:23:43.000000000","message":"Seems like all the comments in this patch were from initial testing but probably need to be formalized a bit to make sense long-term.","commit_id":"77eb290e66c74bb1445ade9e101289a67d2fce77"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"a96c31d57617069eb4ab7625aa39b0c1755b8145","unresolved":false,"context_lines":[{"line_number":8657,"context_line":"                try:"},{"line_number":8658,"context_line":"                    pci_utils.parse_address(device_address)"},{"line_number":8659,"context_line":"                except exception.PciDeviceWrongAddressFormat:"},{"line_number":8660,"context_line":"                    # Meh, that\u0027s fine, this is maybe a virtual address"},{"line_number":8661,"context_line":"                    # if so, the address should be something like mtty_mtty"},{"line_number":8662,"context_line":"                    device_path \u003d device_address.replace(\u0027_\u0027, \u0027/\u0027)"},{"line_number":8663,"context_line":"                    if not os.path.exists("}],"source_content_type":"text/x-python","patch_set":13,"id":"e0d4097f_5bd168f0","line":8660,"in_reply_to":"c8235246_0513d073","updated":"2026-06-17 13:55:18.000000000","message":"Done","commit_id":"77eb290e66c74bb1445ade9e101289a67d2fce77"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"eff11bbb7385bb96fa6c33b616ea44a1f37bc553","unresolved":true,"context_lines":[{"line_number":8657,"context_line":"                try:"},{"line_number":8658,"context_line":"                    pci_utils.parse_address(device_address)"},{"line_number":8659,"context_line":"                except exception.PciDeviceWrongAddressFormat:"},{"line_number":8660,"context_line":"                    # Meh, that\u0027s fine, this is maybe a virtual address"},{"line_number":8661,"context_line":"                    # if so, the address should be something like mtty_mtty"},{"line_number":8662,"context_line":"                    device_path \u003d device_address.replace(\u0027_\u0027, \u0027/\u0027)"},{"line_number":8663,"context_line":"                    if not os.path.exists("}],"source_content_type":"text/x-python","patch_set":13,"id":"c8235246_0513d073","line":8660,"in_reply_to":"eee94040_83cf0164","updated":"2026-06-15 09:35:13.000000000","message":"yes, I\u0027ll change them in next patchset","commit_id":"77eb290e66c74bb1445ade9e101289a67d2fce77"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"eb281f631c98986233b93724e38e61b96feabca8","unresolved":true,"context_lines":[{"line_number":8666,"context_line":"                        raise exception.InvalidLibvirtMdevConfig("},{"line_number":8667,"context_line":"                            reason\u003d\"incorrect PCI address: %s\" % device_address"},{"line_number":8668,"context_line":"                        )"},{"line_number":8669,"context_line":"                    # okay, so that\u0027s a mtty or a mdpy device that was set"},{"line_number":8670,"context_line":"                    self.virtual_mdevs.add(device_address)"},{"line_number":8671,"context_line":"                self.pgpu_type_mapping[device_address] \u003d vgpu_type"},{"line_number":8672,"context_line":"                self.mdev_class_mapping[device_address] \u003d mdev_class"}],"source_content_type":"text/x-python","patch_set":13,"id":"87355690_8d9485ac","line":8669,"updated":"2026-06-12 15:23:43.000000000","message":"Presumably this is any mdev device that is not backed by a real PCI device, of which, mtty, mdpy are examples... correct?","commit_id":"77eb290e66c74bb1445ade9e101289a67d2fce77"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"eff11bbb7385bb96fa6c33b616ea44a1f37bc553","unresolved":true,"context_lines":[{"line_number":8666,"context_line":"                        raise exception.InvalidLibvirtMdevConfig("},{"line_number":8667,"context_line":"                            reason\u003d\"incorrect PCI address: %s\" % device_address"},{"line_number":8668,"context_line":"                        )"},{"line_number":8669,"context_line":"                    # okay, so that\u0027s a mtty or a mdpy device that was set"},{"line_number":8670,"context_line":"                    self.virtual_mdevs.add(device_address)"},{"line_number":8671,"context_line":"                self.pgpu_type_mapping[device_address] \u003d vgpu_type"},{"line_number":8672,"context_line":"                self.mdev_class_mapping[device_address] \u003d mdev_class"}],"source_content_type":"text/x-python","patch_set":13,"id":"ca22d08c_33095215","line":8669,"in_reply_to":"87355690_8d9485ac","updated":"2026-06-15 09:35:13.000000000","message":"that\u0027s correct mtty/mdpy are sample kernel modules to test mdevs without hardware","commit_id":"77eb290e66c74bb1445ade9e101289a67d2fce77"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"a96c31d57617069eb4ab7625aa39b0c1755b8145","unresolved":false,"context_lines":[{"line_number":8666,"context_line":"                        raise exception.InvalidLibvirtMdevConfig("},{"line_number":8667,"context_line":"                            reason\u003d\"incorrect PCI address: %s\" % device_address"},{"line_number":8668,"context_line":"                        )"},{"line_number":8669,"context_line":"                    # okay, so that\u0027s a mtty or a mdpy device that was set"},{"line_number":8670,"context_line":"                    self.virtual_mdevs.add(device_address)"},{"line_number":8671,"context_line":"                self.pgpu_type_mapping[device_address] \u003d vgpu_type"},{"line_number":8672,"context_line":"                self.mdev_class_mapping[device_address] \u003d mdev_class"}],"source_content_type":"text/x-python","patch_set":13,"id":"fa9d506c_bb20237f","line":8669,"in_reply_to":"ca22d08c_33095215","updated":"2026-06-17 13:55:18.000000000","message":"Done","commit_id":"77eb290e66c74bb1445ade9e101289a67d2fce77"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"4934f7e223dec1b5598fd313770357ffa7952c7d","unresolved":true,"context_lines":[{"line_number":8658,"context_line":"                    pci_utils.parse_address(device_address)"},{"line_number":8659,"context_line":"                except exception.PciDeviceWrongAddressFormat:"},{"line_number":8660,"context_line":"                    # if the address is not a valid PCI address it could still"},{"line_number":8661,"context_line":"                    # be a virtual address for a mtty/mdpy mdev"},{"line_number":8662,"context_line":"                    # if so, the address should be something like mtty_mtty"},{"line_number":8663,"context_line":"                    device_path \u003d device_address.replace(\u0027_\u0027, \u0027/\u0027)"},{"line_number":8664,"context_line":"                    if not os.path.exists("}],"source_content_type":"text/x-python","patch_set":14,"id":"2a90a968_fd807cc1","line":8661,"range":{"start_line":8661,"start_character":49,"end_line":8661,"end_character":58},"updated":"2026-06-17 13:27:01.000000000","message":"we could update this comment based on your findign that libivrt speciall cased\nmtty and only mtty\n\nthat wont be a limitation for cybrog as we are not allowed to use libvirt for devcie discorvery adn instead use /sys or tooles like lspci directly but for nova its currenlty limited to mtty due to the libvirt constratint","commit_id":"5f9feb73cc602b5dd008b5e87cf58e5bafac3b58"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"a96c31d57617069eb4ab7625aa39b0c1755b8145","unresolved":true,"context_lines":[{"line_number":8658,"context_line":"                    pci_utils.parse_address(device_address)"},{"line_number":8659,"context_line":"                except exception.PciDeviceWrongAddressFormat:"},{"line_number":8660,"context_line":"                    # if the address is not a valid PCI address it could still"},{"line_number":8661,"context_line":"                    # be a virtual address for a mtty/mdpy mdev"},{"line_number":8662,"context_line":"                    # if so, the address should be something like mtty_mtty"},{"line_number":8663,"context_line":"                    device_path \u003d device_address.replace(\u0027_\u0027, \u0027/\u0027)"},{"line_number":8664,"context_line":"                    if not os.path.exists("}],"source_content_type":"text/x-python","patch_set":14,"id":"87bda396_0d82a5b3","line":8661,"range":{"start_line":8661,"start_character":49,"end_line":8661,"end_character":58},"in_reply_to":"2a90a968_fd807cc1","updated":"2026-06-17 13:55:18.000000000","message":"I added more info in this comment and in the commit message to note that only mtty will work since it\u0027s a special case in libvirt","commit_id":"5f9feb73cc602b5dd008b5e87cf58e5bafac3b58"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"40ca57cbaf3876dcdbe94553d8885c1341f04bb2","unresolved":false,"context_lines":[{"line_number":8658,"context_line":"                    pci_utils.parse_address(device_address)"},{"line_number":8659,"context_line":"                except exception.PciDeviceWrongAddressFormat:"},{"line_number":8660,"context_line":"                    # if the address is not a valid PCI address it could still"},{"line_number":8661,"context_line":"                    # be a virtual address for a mtty/mdpy mdev"},{"line_number":8662,"context_line":"                    # if so, the address should be something like mtty_mtty"},{"line_number":8663,"context_line":"                    device_path \u003d device_address.replace(\u0027_\u0027, \u0027/\u0027)"},{"line_number":8664,"context_line":"                    if not os.path.exists("}],"source_content_type":"text/x-python","patch_set":14,"id":"df63e4ea_49f794b7","line":8661,"range":{"start_line":8661,"start_character":49,"end_line":8661,"end_character":58},"in_reply_to":"87bda396_0d82a5b3","updated":"2026-06-23 06:24:44.000000000","message":"Done","commit_id":"5f9feb73cc602b5dd008b5e87cf58e5bafac3b58"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"02eba10512cb1c96de60bca3cac9c3cf0c398998","unresolved":true,"context_lines":[{"line_number":8655,"context_line":"                # Just checking whether the operator fat-fingered the address."},{"line_number":8656,"context_line":"                # If it\u0027s wrong, it will return an exception"},{"line_number":8657,"context_line":"                try:"},{"line_number":8658,"context_line":"                    pci_utils.parse_address(device_address)"},{"line_number":8659,"context_line":"                except exception.PciDeviceWrongAddressFormat:"},{"line_number":8660,"context_line":"                    # if the address is not a valid PCI address it could still"},{"line_number":8661,"context_line":"                    # be a virtual address for a mtty mdev"},{"line_number":8662,"context_line":"                    # if so, the address should be something like mtty_mtty"},{"line_number":8663,"context_line":"                    # it can\u0027t be mdpy since libvirt added support for mtty"},{"line_number":8664,"context_line":"                    # explicitly by hardcoding it as a parent for mediated"},{"line_number":8665,"context_line":"                    # devices but did not do the same for mdpy"},{"line_number":8666,"context_line":"                    # \u001bhttps://gitlab.com/libvirt/libvirt/-/commit/ab29ddfdf8774eaffbe4d6e83fd47ccb6b1c0308"},{"line_number":8667,"context_line":"                    device_path \u003d device_address.replace(\u0027_\u0027, \u0027/\u0027)"},{"line_number":8668,"context_line":"                    if not os.path.exists("},{"line_number":8669,"context_line":"                            \u0027/sys/devices/virtual/%s\u0027 % device_path):"},{"line_number":8670,"context_line":"                        # if the address is not from some virtual device, then"},{"line_number":8671,"context_line":"                        # it must be incorrect"},{"line_number":8672,"context_line":"                        raise exception.InvalidLibvirtMdevConfig("},{"line_number":8673,"context_line":"                            reason\u003d\"incorrect PCI address: %s\" % device_address"},{"line_number":8674,"context_line":"                        )"},{"line_number":8675,"context_line":"                    # the address corresponds to a virtual device like a mtty"},{"line_number":8676,"context_line":"                    # or mdpy mdev"},{"line_number":8677,"context_line":"                    self.virtual_mdevs.add(device_address)"},{"line_number":8678,"context_line":"                self.pgpu_type_mapping[device_address] \u003d vgpu_type"},{"line_number":8679,"context_line":"                self.mdev_class_mapping[device_address] \u003d mdev_class"},{"line_number":8680,"context_line":"                self.mdev_classes.add(mdev_class)"}],"source_content_type":"text/x-python","patch_set":15,"id":"8f2a163a_c94c509e","line":8677,"range":{"start_line":8658,"start_character":0,"end_line":8677,"end_character":58},"updated":"2026-06-23 02:14:10.000000000","message":"I\u0027m thinking it might be worth extracting this code into a helper method, perhaps `_validate_device_address` to try and compartmentalize the virtual mdev handling a bit more.","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"b02d482f8654d2ec2047dfc95d6e35859e18de8c","unresolved":false,"context_lines":[{"line_number":8655,"context_line":"                # Just checking whether the operator fat-fingered the address."},{"line_number":8656,"context_line":"                # If it\u0027s wrong, it will return an exception"},{"line_number":8657,"context_line":"                try:"},{"line_number":8658,"context_line":"                    pci_utils.parse_address(device_address)"},{"line_number":8659,"context_line":"                except exception.PciDeviceWrongAddressFormat:"},{"line_number":8660,"context_line":"                    # if the address is not a valid PCI address it could still"},{"line_number":8661,"context_line":"                    # be a virtual address for a mtty mdev"},{"line_number":8662,"context_line":"                    # if so, the address should be something like mtty_mtty"},{"line_number":8663,"context_line":"                    # it can\u0027t be mdpy since libvirt added support for mtty"},{"line_number":8664,"context_line":"                    # explicitly by hardcoding it as a parent for mediated"},{"line_number":8665,"context_line":"                    # devices but did not do the same for mdpy"},{"line_number":8666,"context_line":"                    # \u001bhttps://gitlab.com/libvirt/libvirt/-/commit/ab29ddfdf8774eaffbe4d6e83fd47ccb6b1c0308"},{"line_number":8667,"context_line":"                    device_path \u003d device_address.replace(\u0027_\u0027, \u0027/\u0027)"},{"line_number":8668,"context_line":"                    if not os.path.exists("},{"line_number":8669,"context_line":"                            \u0027/sys/devices/virtual/%s\u0027 % device_path):"},{"line_number":8670,"context_line":"                        # if the address is not from some virtual device, then"},{"line_number":8671,"context_line":"                        # it must be incorrect"},{"line_number":8672,"context_line":"                        raise exception.InvalidLibvirtMdevConfig("},{"line_number":8673,"context_line":"                            reason\u003d\"incorrect PCI address: %s\" % device_address"},{"line_number":8674,"context_line":"                        )"},{"line_number":8675,"context_line":"                    # the address corresponds to a virtual device like a mtty"},{"line_number":8676,"context_line":"                    # or mdpy mdev"},{"line_number":8677,"context_line":"                    self.virtual_mdevs.add(device_address)"},{"line_number":8678,"context_line":"                self.pgpu_type_mapping[device_address] \u003d vgpu_type"},{"line_number":8679,"context_line":"                self.mdev_class_mapping[device_address] \u003d mdev_class"},{"line_number":8680,"context_line":"                self.mdev_classes.add(mdev_class)"}],"source_content_type":"text/x-python","patch_set":15,"id":"5bed2772_a93422ab","line":8677,"range":{"start_line":8658,"start_character":0,"end_line":8677,"end_character":58},"in_reply_to":"8f2a163a_c94c509e","updated":"2026-06-23 09:17:15.000000000","message":"Done","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"02eba10512cb1c96de60bca3cac9c3cf0c398998","unresolved":true,"context_lines":[{"line_number":8683,"context_line":"    def _get_pci_id_from_libvirt_name("},{"line_number":8684,"context_line":"            self, libvirt_address: str"},{"line_number":8685,"context_line":"        ) -\u003e str | None:"},{"line_number":8686,"context_line":"        \"\"\"Returns a PCI ID from a libvirt pci address name."},{"line_number":8687,"context_line":""},{"line_number":8688,"context_line":"        :param libvirt_address: the libvirt PCI device name,"},{"line_number":8689,"context_line":"                                eg.\u0027pci_0000_84_00_0\u0027"}],"source_content_type":"text/x-python","patch_set":15,"id":"79a1ee4a_7315d8b1","line":8686,"range":{"start_line":8686,"start_character":11,"end_line":8686,"end_character":60},"updated":"2026-06-23 02:14:10.000000000","message":"I think we need to update the docstring to include the behavior if it\u0027s a virtual mdev (there will be no PCI ID and instead just returns the libvirt_address unchanged).\n\nWe could also consider renaming the method to something more generic like `_get_device_address` that takes a `libvirt_name` and returns a device address.","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"b02d482f8654d2ec2047dfc95d6e35859e18de8c","unresolved":true,"context_lines":[{"line_number":8683,"context_line":"    def _get_pci_id_from_libvirt_name("},{"line_number":8684,"context_line":"            self, libvirt_address: str"},{"line_number":8685,"context_line":"        ) -\u003e str | None:"},{"line_number":8686,"context_line":"        \"\"\"Returns a PCI ID from a libvirt pci address name."},{"line_number":8687,"context_line":""},{"line_number":8688,"context_line":"        :param libvirt_address: the libvirt PCI device name,"},{"line_number":8689,"context_line":"                                eg.\u0027pci_0000_84_00_0\u0027"}],"source_content_type":"text/x-python","patch_set":15,"id":"bbc51aed_b8258d7c","line":8686,"range":{"start_line":8686,"start_character":11,"end_line":8686,"end_character":60},"in_reply_to":"79a1ee4a_7315d8b1","updated":"2026-06-23 09:17:15.000000000","message":"I\u0027ve changed the method name and made the docstring more explicit about the cases that it could be handling","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"a520055ff75fbb397da054d5044865c8ed91afa6","unresolved":false,"context_lines":[{"line_number":8683,"context_line":"    def _get_pci_id_from_libvirt_name("},{"line_number":8684,"context_line":"            self, libvirt_address: str"},{"line_number":8685,"context_line":"        ) -\u003e str | None:"},{"line_number":8686,"context_line":"        \"\"\"Returns a PCI ID from a libvirt pci address name."},{"line_number":8687,"context_line":""},{"line_number":8688,"context_line":"        :param libvirt_address: the libvirt PCI device name,"},{"line_number":8689,"context_line":"                                eg.\u0027pci_0000_84_00_0\u0027"}],"source_content_type":"text/x-python","patch_set":15,"id":"8ebec3b0_0c684282","line":8686,"range":{"start_line":8686,"start_character":11,"end_line":8686,"end_character":60},"in_reply_to":"bbc51aed_b8258d7c","updated":"2026-06-23 17:06:31.000000000","message":"Done","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"02eba10512cb1c96de60bca3cac9c3cf0c398998","unresolved":true,"context_lines":[{"line_number":8688,"context_line":"        :param libvirt_address: the libvirt PCI device name,"},{"line_number":8689,"context_line":"                                eg.\u0027pci_0000_84_00_0\u0027"},{"line_number":8690,"context_line":"        \"\"\""},{"line_number":8691,"context_line":"        if libvirt_address in self.virtual_mdevs:"},{"line_number":8692,"context_line":"            return libvirt_address"},{"line_number":8693,"context_line":"        try:"},{"line_number":8694,"context_line":"            device_address \u003d \"{}:{}:{}.{}\".format("}],"source_content_type":"text/x-python","patch_set":15,"id":"7700a38f_0dc814a4","line":8691,"range":{"start_line":8691,"start_character":11,"end_line":8691,"end_character":49},"updated":"2026-06-23 02:14:10.000000000","message":"Could we consider making a helper method for this like `_is_virtual_mdev()` that takes an address and returns true/false if it\u0027s virtual? And use that at the call sites?","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"b02d482f8654d2ec2047dfc95d6e35859e18de8c","unresolved":false,"context_lines":[{"line_number":8688,"context_line":"        :param libvirt_address: the libvirt PCI device name,"},{"line_number":8689,"context_line":"                                eg.\u0027pci_0000_84_00_0\u0027"},{"line_number":8690,"context_line":"        \"\"\""},{"line_number":8691,"context_line":"        if libvirt_address in self.virtual_mdevs:"},{"line_number":8692,"context_line":"            return libvirt_address"},{"line_number":8693,"context_line":"        try:"},{"line_number":8694,"context_line":"            device_address \u003d \"{}:{}:{}.{}\".format("}],"source_content_type":"text/x-python","patch_set":15,"id":"2bfb5a0b_36f98d68","line":8691,"range":{"start_line":8691,"start_character":11,"end_line":8691,"end_character":49},"in_reply_to":"7700a38f_0dc814a4","updated":"2026-06-23 09:17:15.000000000","message":"makes sense, done","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"02eba10512cb1c96de60bca3cac9c3cf0c398998","unresolved":true,"context_lines":[{"line_number":9004,"context_line":"            cap \u003d cfgdev.pci_capability"},{"line_number":9005,"context_line":"        else:"},{"line_number":9006,"context_line":"            # the mtty device has a mdev capability instead of a pci capability"},{"line_number":9007,"context_line":"            cap \u003d cfgdev.mdev_capability"},{"line_number":9008,"context_line":""},{"line_number":9009,"context_line":"        for mdev_cap in cap.mdev_capability:"},{"line_number":9010,"context_line":"            for cap in mdev_cap.mdev_types:"}],"source_content_type":"text/x-python","patch_set":15,"id":"60189de5_b339f38b","line":9007,"updated":"2026-06-23 02:14:10.000000000","message":"Should we consider setting `device[\"vendor_id\"] \u003d None` instead of omitting it? Thinking about potential `KeyError` down the line.","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"},{"author":{"_account_id":34452,"name":"Joan Gilabert","display_name":"jgilaber","email":"jgilaber@redhat.com","username":"jgilaber"},"change_message_id":"b02d482f8654d2ec2047dfc95d6e35859e18de8c","unresolved":true,"context_lines":[{"line_number":9004,"context_line":"            cap \u003d cfgdev.pci_capability"},{"line_number":9005,"context_line":"        else:"},{"line_number":9006,"context_line":"            # the mtty device has a mdev capability instead of a pci capability"},{"line_number":9007,"context_line":"            cap \u003d cfgdev.mdev_capability"},{"line_number":9008,"context_line":""},{"line_number":9009,"context_line":"        for mdev_cap in cap.mdev_capability:"},{"line_number":9010,"context_line":"            for cap in mdev_cap.mdev_types:"}],"source_content_type":"text/x-python","patch_set":15,"id":"625eb258_895c03c2","line":9007,"in_reply_to":"60189de5_b339f38b","updated":"2026-06-23 09:17:15.000000000","message":"I set it to None, but tbh I\u0027m not completely sure of what is the best way of handling this value","commit_id":"3f04d9aefd15716639492cee33d6322c4bd38eda"}]}
