Add GPUWU support

This commit is contained in:
Guaxinim5573 2021-03-14 18:51:25 -03:00
parent 28c4c7a59f
commit 6d71999d09

View file

@ -199,9 +199,10 @@ void get_info() { // get all necessary info
fclose(meminfo); fclose(meminfo);
// gpu // gpu
FILE *gpu = popen("lspci -vnn | grep 'VGA\\|DISPLAY\\|3D'", "r"); FILE *gpu = popen("lspci -mm | grep \"VGA\\|00:02\" | cut --fields=4,6 -d '\"' --output-delimiter=\" \" | sed \"s/ Controller.*//\"", "r");
if (gpu) { if (gpu) {
//fscanf(gpu, "%[^\n]", gpu_model); // Ignore error
if(fscanf(gpu, "%[^\n]", gpu_model) == 3) {};
fclose(gpu); fclose(gpu);
} }