Skip to content

samples/client: get BAR1 size from region info#873

Merged
tmakatos merged 1 commit into
nutanix:masterfrom
zp78256pxd-ux:fix/client-bar1-region-info
Jul 7, 2026
Merged

samples/client: get BAR1 size from region info#873
tmakatos merged 1 commit into
nutanix:masterfrom
zp78256pxd-ux:fix/client-bar1-region-info

Conversation

@zp78256pxd-ux

Copy link
Copy Markdown
Contributor

Summary

Replace the hardcoded BAR1 size in the sample client with the size reported by VFIO_USER_DEVICE_GET_REGION_INFO.

This removes the existing FIXME and ensures the client uses the BAR1 size provided by the server instead of relying on a hardcoded value.

Testing

  • Built the sample client with ninja -C build/asan samples/client
  • Ran the sample client/server migration workflow successfully

Retrieve the BAR1 size from VFIO_USER_DEVICE_GET_REGION_INFO
instead of relying on a hardcoded value. This removes the
existing FIXME and allows the client to use the size reported
by the server.

Signed-off-by: Siddharth C <siddharthcibi@icloud.com>
@zp78256pxd-ux

Copy link
Copy Markdown
Contributor Author

While testing this change with ASan enabled, I noticed a memory leak reported in the sample client. It appears to originate somewhere in the migration path (do_migrate()/migrate_from()) and I don't believe this change introduces it, but I'm not certain of the exact source.Is this a known issue? Happy to investigate and address it in
a follow-up PR.

@tmakatos

tmakatos commented Jul 7, 2026

Copy link
Copy Markdown
Collaborator

While testing this change with ASan enabled, I noticed a memory leak reported in the sample client. It appears to originate somewhere in the migration path (do_migrate()/migrate_from()) and I don't believe this change introduces it, but I'm not certain of the exact source.Is this a known issue? Happy to investigate and address it in a follow-up PR.

Not a known issue, feel free to fix.

@tmakatos tmakatos merged commit 15d294a into nutanix:master Jul 7, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants