Browse Source

Pass the correct GPU from the menu to the adl code.

nfactor-troky
Con Kolivas 13 years ago
parent
commit
7bcda9a28f
  1. 3
      adl.c
  2. 4
      adl.h

3
adl.c

@ -1153,8 +1153,9 @@ void change_autosettings(int gpu)
} }
} }
void change_gpusettings(int gpu) void change_gpusettings(int disp_gpu)
{ {
int gpu = gpus[disp_gpu].virtual_gpu;
struct gpu_adl *ga = &gpus[gpu].adl; struct gpu_adl *ga = &gpus[gpu].adl;
float fval, fmin = 0, fmax = 0; float fval, fmin = 0, fmax = 0;
int val, imin = 0, imax = 0; int val, imin = 0, imax = 0;

4
adl.h

@ -16,13 +16,13 @@ int gpu_fanspeed(int gpu);
int gpu_fanpercent(int gpu); int gpu_fanpercent(int gpu);
bool gpu_stats(int gpu, float *temp, int *engineclock, int *memclock, float *vddc, bool gpu_stats(int gpu, float *temp, int *engineclock, int *memclock, float *vddc,
int *activity, int *fanspeed, int *fanpercent, int *powertune); int *activity, int *fanspeed, int *fanpercent, int *powertune);
void change_gpusettings(int gpu); void change_gpusettings(int disp_gpu);
void gpu_autotune(int gpu, bool *enable); void gpu_autotune(int gpu, bool *enable);
void clear_adl(int nDevs); void clear_adl(int nDevs);
#else /* HAVE_ADL */ #else /* HAVE_ADL */
#define adl_active (0) #define adl_active (0)
static inline void init_adl(int nDevs) {} static inline void init_adl(int nDevs) {}
static inline void change_gpusettings(int gpu) { } static inline void change_gpusettings(int disp_gpu) { }
static inline void clear_adl(int nDevs) {} static inline void clear_adl(int nDevs) {}
#endif #endif
#endif #endif

Loading…
Cancel
Save