X-Git-Url: https://www.flypig.org.uk/git/?a=blobdiff_plain;f=src%2Fshared.c;h=8cfa46ef9a22fce39ddcf7d6cccef3312f2db26c;hb=de1d1da4549d5a9bbeffa094dcf044e2177280e9;hp=4aedad78cb87fa1b9eb1f209c6d695edb26dba59;hpb=a5baa829c5bb911d2a83d7194df291563c89e60f;p=hashcat.git diff --git a/src/shared.c b/src/shared.c index 4aedad7..8cfa46e 100644 --- a/src/shared.c +++ b/src/shared.c @@ -3402,11 +3402,17 @@ int hm_get_throttle_with_device_id (const uint device_id) if (hm_NVML_nvmlDeviceGetCurrentClocksThrottleReasons (data.hm_nvml, 1, data.hm_device[device_id].nvml, &clocksThrottleReasons) != NVML_SUCCESS) return -1; if (hm_NVML_nvmlDeviceGetSupportedClocksThrottleReasons (data.hm_nvml, 1, data.hm_device[device_id].nvml, &supportedThrottleReasons) != NVML_SUCCESS) return -1; - clocksThrottleReasons &= supportedThrottleReasons; - + clocksThrottleReasons &= supportedThrottleReasons; + clocksThrottleReasons &= ~nvmlClocksThrottleReasonGpuIdle; + clocksThrottleReasons &= ~nvmlClocksThrottleReasonApplicationsClocksSetting; clocksThrottleReasons &= ~nvmlClocksThrottleReasonUnknown; - return (clocksThrottleReasons > 0); + if (data.kernel_power_final) + { + clocksThrottleReasons &= ~nvmlClocksThrottleReasonHwSlowdown; + } + + return (clocksThrottleReasons != nvmlClocksThrottleReasonNone); } return -1;