Lines Matching +full:device +full:- +full:addr
33 struct nvkm_device *device = bios->subdev.device; in pramin_read() local
37 *(u32 *)&bios->data[i] = nvkm_rd32(device, 0x700000 + i); in pramin_read()
48 struct nvkm_device *device = priv->bios->subdev.device; in pramin_fini() local
49 nvkm_wr32(device, 0x001700, priv->bar0); in pramin_fini()
57 struct nvkm_subdev *subdev = &bios->subdev; in pramin_init()
58 struct nvkm_device *device = subdev->device; in pramin_init() local
60 u64 addr = 0; in pramin_init() local
63 if (device->card_type < NV_50) in pramin_init()
67 if (device->card_type >= GA100) in pramin_init()
68 addr = device->chipset == 0x170; /*XXX: find the fuse reg for this */ in pramin_init()
70 if (device->card_type >= GM100) in pramin_init()
71 addr = nvkm_rd32(device, 0x021c04); in pramin_init()
73 if (device->card_type >= NV_C0) in pramin_init()
74 addr = nvkm_rd32(device, 0x022500); in pramin_init()
75 if (addr & 0x00000001) { in pramin_init()
77 return ERR_PTR(-ENODEV); in pramin_init()
84 if (device->card_type >= GV100) in pramin_init()
85 addr = nvkm_rd32(device, 0x625f04); in pramin_init()
87 addr = nvkm_rd32(device, 0x619f04); in pramin_init()
88 if (!(addr & 0x00000008)) { in pramin_init()
90 return ERR_PTR(-ENODEV); in pramin_init()
92 if ( (addr & 0x00000003) != 1) { in pramin_init()
94 return ERR_PTR(-ENODEV); in pramin_init()
97 /* some alternate method inherited from xf86-video-nv... */ in pramin_init()
98 addr = (addr & 0xffffff00) << 8; in pramin_init()
99 if (!addr) { in pramin_init()
100 addr = (u64)nvkm_rd32(device, 0x001700) << 16; in pramin_init()
101 addr += 0xf0000; in pramin_init()
107 return ERR_PTR(-ENOMEM); in pramin_init()
110 priv->bios = bios; in pramin_init()
111 priv->bar0 = nvkm_rd32(device, 0x001700); in pramin_init()
112 nvkm_wr32(device, 0x001700, addr >> 16); in pramin_init()