41 const int mem_width[] = { 0x10, 0x00, 0x20 };
42 const int mem_width_count = nv_device(priv)->chipset >= 0x17 ? 3 : 2;
44 struct io_mapping *
fb;
48 fb = fbmem_init(nv_device(priv)->pdev);
50 nv_error(priv,
"failed to map fb\n");
57 for (i = 0; i < mem_width_count; i++) {
60 for (j = 0; j < 4; j++) {
61 for (k = 0; k < 4; k++)
62 fbmem_poke(fb, 0x1c, 0);
64 fbmem_poke(fb, 0x1c, patt);
65 fbmem_poke(fb, 0x3c, 0);
67 if (fbmem_peek(fb, 0x1c) == patt)
76 for (i = 0; i < 4; i++) {
77 int off = nv_rd32(priv, 0x10020c) - 0x100000;
79 fbmem_poke(fb, off, patt);
87 if (fbmem_peek(fb, off) == patt)
107 *pobject = nv_object(priv);
111 priv->
base.meminit = nv10_devinit_meminit;
119 .ctor = nv10_devinit_ctor,