mirror of
https://github.com/GOSTSec/sgminer
synced 2025-09-03 09:42:17 +00:00
Fix --scrypt being required before scrypt intensities on command line or not working at all via config files.
This commit is contained in:
parent
b423fe9de8
commit
3e84a19cda
@ -550,7 +550,7 @@ char *set_intensity(char *arg)
|
|||||||
else {
|
else {
|
||||||
gpus[device].dynamic = false;
|
gpus[device].dynamic = false;
|
||||||
val = atoi(nextptr);
|
val = atoi(nextptr);
|
||||||
if (val < MIN_INTENSITY || val > MAX_INTENSITY)
|
if (val < MIN_INTENSITY || val > MAX_GPU_INTENSITY)
|
||||||
return "Invalid value passed to set intensity";
|
return "Invalid value passed to set intensity";
|
||||||
tt = &gpus[device].intensity;
|
tt = &gpus[device].intensity;
|
||||||
*tt = val;
|
*tt = val;
|
||||||
@ -564,7 +564,7 @@ char *set_intensity(char *arg)
|
|||||||
else {
|
else {
|
||||||
gpus[device].dynamic = false;
|
gpus[device].dynamic = false;
|
||||||
val = atoi(nextptr);
|
val = atoi(nextptr);
|
||||||
if (val < MIN_INTENSITY || val > MAX_INTENSITY)
|
if (val < MIN_INTENSITY || val > MAX_GPU_INTENSITY)
|
||||||
return "Invalid value passed to set intensity";
|
return "Invalid value passed to set intensity";
|
||||||
|
|
||||||
tt = &gpus[device].intensity;
|
tt = &gpus[device].intensity;
|
||||||
|
2
miner.h
2
miner.h
@ -958,11 +958,13 @@ extern bool add_pool_details(struct pool *pool, bool live, char *url, char *user
|
|||||||
#define MIN_INTENSITY_STR (opt_scrypt ? MIN_SCRYPT_INTENSITY_STR : MIN_SHA_INTENSITY_STR)
|
#define MIN_INTENSITY_STR (opt_scrypt ? MIN_SCRYPT_INTENSITY_STR : MIN_SHA_INTENSITY_STR)
|
||||||
#define MAX_INTENSITY (opt_scrypt ? MAX_SCRYPT_INTENSITY : MAX_SHA_INTENSITY)
|
#define MAX_INTENSITY (opt_scrypt ? MAX_SCRYPT_INTENSITY : MAX_SHA_INTENSITY)
|
||||||
#define MAX_INTENSITY_STR (opt_scrypt ? MAX_SCRYPT_INTENSITY_STR : MAX_SHA_INTENSITY_STR)
|
#define MAX_INTENSITY_STR (opt_scrypt ? MAX_SCRYPT_INTENSITY_STR : MAX_SHA_INTENSITY_STR)
|
||||||
|
#define MAX_GPU_INTENSITY MAX_SCRYPT_INTENSITY
|
||||||
#else
|
#else
|
||||||
#define MIN_INTENSITY MIN_SHA_INTENSITY
|
#define MIN_INTENSITY MIN_SHA_INTENSITY
|
||||||
#define MIN_INTENSITY_STR MIN_SHA_INTENSITY_STR
|
#define MIN_INTENSITY_STR MIN_SHA_INTENSITY_STR
|
||||||
#define MAX_INTENSITY MAX_SHA_INTENSITY
|
#define MAX_INTENSITY MAX_SHA_INTENSITY
|
||||||
#define MAX_INTENSITY_STR MAX_SHA_INTENSITY_STR
|
#define MAX_INTENSITY_STR MAX_SHA_INTENSITY_STR
|
||||||
|
#define MAX_GPU_INTENSITY MAX_SHA_INTENSITY
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern bool hotplug_mode;
|
extern bool hotplug_mode;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user