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

How to determine primary GPU? #171

Open
Ashark opened this issue Nov 24, 2022 · 0 comments
Open

How to determine primary GPU? #171

Ashark opened this issue Nov 24, 2022 · 0 comments

Comments

@Ashark
Copy link

Ashark commented Nov 24, 2022

Hello. Here I saw a log of gpu manager, and I am interested how it works. I am looking answer for the question https://stackoverflow.com/questions/19985131/how-identify-the-primary-video-card-on-linux-programmatically
This is needed for my project in which I detect many info about gpu on the user's system.
If user has multiple GPUs, I need to understand which is primary, because I need to do different things for different GPUs.

I am especially interested in theese parts of the log:

Vendor/Device Id: 8086:1902
BusID "PCI:0@0:2:0"
Is boot vga? no  # <-- How ?
Vendor/Device Id: 10de:1c81
BusID "PCI:1@0:0:0"
Is boot vga? yes  # <-- How ?
Does it require offloading? yes # <-- How?

I would be glad if you point me in the right direction. How do I identify the gpu that is used as main/primary/boot?
Is it possible with drm_info? I tried to manually make another card as a primary at boot, and the order of gpus list in drm_info did not changed. I need some way to say if particular gpu is currently primary.

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

No branches or pull requests

1 participant