@@ -536,27 +536,27 @@ static const char* detectPci(const FFGPUOptions* options, FFlist* gpus, FFstrbuf
536536 .name = & gpu -> name ,
537537 }, soName );
538538 }
539-
540- if (gpu -> type == FF_GPU_TYPE_UNKNOWN )
541- {
542- if (gpu -> vendor .chars == FF_GPU_VENDOR_NAME_NVIDIA )
543- {
544- if (ffStrbufStartsWithIgnCaseS (& gpu -> name , "GeForce" ) ||
545- ffStrbufStartsWithIgnCaseS (& gpu -> name , "Quadro" ) ||
546- ffStrbufStartsWithIgnCaseS (& gpu -> name , "Tesla" ))
547- gpu -> type = FF_GPU_TYPE_DISCRETE ;
548- }
549- else if (gpu -> vendor .chars == FF_GPU_VENDOR_NAME_MTHREADS )
550- {
551- if (ffStrbufStartsWithIgnCaseS (& gpu -> name , "MTT " ))
552- gpu -> type = FF_GPU_TYPE_DISCRETE ;
553- }
554- }
555539 }
556540
557541 if (gpu -> name .length == 0 )
558542 ffGPUFillVendorAndName (subclassId , (uint16_t ) vendorId , (uint16_t ) deviceId , gpu );
559543
544+ if (gpu -> type == FF_GPU_TYPE_UNKNOWN )
545+ {
546+ if (gpu -> vendor .chars == FF_GPU_VENDOR_NAME_NVIDIA )
547+ {
548+ if (ffStrbufStartsWithIgnCaseS (& gpu -> name , "GeForce" ) ||
549+ ffStrbufStartsWithIgnCaseS (& gpu -> name , "Quadro" ) ||
550+ ffStrbufStartsWithIgnCaseS (& gpu -> name , "Tesla" ))
551+ gpu -> type = FF_GPU_TYPE_DISCRETE ;
552+ }
553+ else if (gpu -> vendor .chars == FF_GPU_VENDOR_NAME_MTHREADS )
554+ {
555+ if (ffStrbufStartsWithIgnCaseS (& gpu -> name , "MTT " ))
556+ gpu -> type = FF_GPU_TYPE_DISCRETE ;
557+ }
558+ }
559+
560560 return NULL ;
561561}
562562
0 commit comments