diff options
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_volt.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nouveau_volt.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_volt.c b/drivers/gpu/drm/nouveau/nouveau_volt.c index 04fdc00a67d5..75e872741d92 100644 --- a/drivers/gpu/drm/nouveau/nouveau_volt.c +++ b/drivers/gpu/drm/nouveau/nouveau_volt.c | |||
@@ -159,8 +159,16 @@ nouveau_volt_init(struct drm_device *dev) | |||
159 | headerlen = volt[1]; | 159 | headerlen = volt[1]; |
160 | recordlen = volt[2]; | 160 | recordlen = volt[2]; |
161 | entries = volt[3]; | 161 | entries = volt[3]; |
162 | vidshift = hweight8(volt[5]); | ||
163 | vidmask = volt[4]; | 162 | vidmask = volt[4]; |
163 | /* no longer certain what volt[5] is, if it's related to | ||
164 | * the vid shift then it's definitely not a function of | ||
165 | * how many bits are set. | ||
166 | * | ||
167 | * after looking at a number of nva3+ vbios images, they | ||
168 | * all seem likely to have a static shift of 2.. lets | ||
169 | * go with that for now until proven otherwise. | ||
170 | */ | ||
171 | vidshift = 2; | ||
164 | break; | 172 | break; |
165 | default: | 173 | default: |
166 | NV_WARN(dev, "voltage table 0x%02x unknown\n", volt[0]); | 174 | NV_WARN(dev, "voltage table 0x%02x unknown\n", volt[0]); |