Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed a issue where same client requested multiple times #7649

Closed

Conversation

saifuddin-xilinx
Copy link
Collaborator

Problem solved by the commit

-- There is a issue where same client requested the XRT driver multiple time.
-- In our XRT driver we haven't any check before creating a client or destroying a client.
-- In this PR I have added such checks based on the PID. If same PID is requested then it just increase a reference count and return, While deleting if the reference count is "0" then only it will cleanup that client.

Bug / issue (if any) fixed, which PR introduced the bug, how it was discovered

How problem was solved, alternative solutions (if any) and why they were rejected

Risks (if any) associated the changes in the commit

What has been tested and how, request additional testing if necessary

Documentation impact (if any)

Signed-off-by: Saifuddin <saifuddi@xilinx.com>
@gbuildx
Copy link
Collaborator

gbuildx commented Jul 31, 2023

Build failed :(

Signed-off-by: Saifuddin <saifuddi@xilinx.com>
@gbuildx
Copy link
Collaborator

gbuildx commented Jul 31, 2023

Build failed :(

@saifuddin-xilinx
Copy link
Collaborator Author

retest this please

@gbuildx
Copy link
Collaborator

gbuildx commented Jul 31, 2023

Build failed :(

@saifuddin-xilinx
Copy link
Collaborator Author

retest this please

@gbuildx
Copy link
Collaborator

gbuildx commented Aug 1, 2023

Build failed :(

Copy link
Collaborator

@maxzhen maxzhen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Conceptually, a client is mapped to a fd. Now after this change, multiple fd from same process will share the same client. What does not work before?

Is this change valid for other parts of XRT...Say, if a cu context is opened through one fd, it is considered as "opened" by any fd in that process?

@saifuddin-xilinx
Copy link
Collaborator Author

Conceptually, a client is mapped to a fd. Now after this change, multiple fd from same process will share the same client. What does not work before?

Is this change valid for other parts of XRT...Say, if a cu context is opened through one fd, it is considered as "opened" by any fd in that process?

Thanks for the feedback. I am checking with vvas team for the application.

@saifuddin-xilinx saifuddin-xilinx added the do not merge hold off on merging label Aug 3, 2023
@saifuddin-xilinx
Copy link
Collaborator Author

No longer required. Application has to take care of opening multiple clients.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do not merge hold off on merging
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants