Commit 6827c9a8 authored by Ben Skeggs's avatar Ben Skeggs

drm/nouveau/bios/pll: limits table 5.0

Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
parent 75e482ef
......@@ -193,7 +193,10 @@ pll_map_type(struct nvkm_bios *bios, u8 type, u32 *reg, u8 *ver, u8 *len)
data += hdr;
while (cnt--) {
if (nvbios_rd08(bios, data + 0) == type) {
if (*ver < 0x50)
*reg = nvbios_rd32(bios, data + 3);
else
*reg = 0;
return data;
}
data += *len;
......@@ -361,6 +364,20 @@ nvbios_pll_parse(struct nvkm_bios *bios, u32 type, struct nvbios_pll *info)
info->min_p = nvbios_rd08(bios, data + 12);
info->max_p = nvbios_rd08(bios, data + 13);
break;
case 0x50:
info->refclk = nvbios_rd16(bios, data + 1) * 1000;
/* info->refclk_alt = nvbios_rd16(bios, data + 3) * 1000; */
info->vco1.min_freq = nvbios_rd16(bios, data + 5) * 1000;
info->vco1.max_freq = nvbios_rd16(bios, data + 7) * 1000;
info->vco1.min_inputfreq = nvbios_rd16(bios, data + 9) * 1000;
info->vco1.max_inputfreq = nvbios_rd16(bios, data + 11) * 1000;
info->vco1.min_m = nvbios_rd08(bios, data + 13);
info->vco1.max_m = nvbios_rd08(bios, data + 14);
info->vco1.min_n = nvbios_rd08(bios, data + 15);
info->vco1.max_n = nvbios_rd08(bios, data + 16);
info->min_p = nvbios_rd08(bios, data + 17);
info->max_p = nvbios_rd08(bios, data + 18);
break;
default:
nvkm_error(subdev, "unknown pll limits version 0x%02x\n", ver);
return -EINVAL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment