Lines Matching refs:par
127 struct tcx_par *par = info->par; in __tcx_set_control_plane() local
130 if (par->lowdepth) in __tcx_set_control_plane()
133 p = par->cplane; in __tcx_set_control_plane()
146 struct tcx_par *par = (struct tcx_par *) info->par; in tcx_reset() local
149 spin_lock_irqsave(&par->lock, flags); in tcx_reset()
151 spin_unlock_irqrestore(&par->lock, flags); in tcx_reset()
173 struct tcx_par *par = (struct tcx_par *) info->par; in tcx_setcolreg() local
174 struct bt_regs __iomem *bt = par->bt; in tcx_setcolreg()
184 spin_lock_irqsave(&par->lock, flags); in tcx_setcolreg()
191 spin_unlock_irqrestore(&par->lock, flags); in tcx_setcolreg()
204 struct tcx_par *par = (struct tcx_par *) info->par; in tcx_blank() local
205 struct tcx_thc __iomem *thc = par->thc; in tcx_blank()
209 spin_lock_irqsave(&par->lock, flags); in tcx_blank()
218 par->flags &= ~TCX_FLAG_BLANKED; in tcx_blank()
223 par->flags |= TCX_FLAG_BLANKED; in tcx_blank()
239 spin_unlock_irqrestore(&par->lock, flags); in tcx_blank()
302 struct tcx_par *par = (struct tcx_par *)info->par; in tcx_mmap() local
304 return sbusfb_mmap_helper(par->mmap_map, in tcx_mmap()
306 par->which_io, vma); in tcx_mmap()
312 struct tcx_par *par = (struct tcx_par *) info->par; in tcx_ioctl() local
316 (par->lowdepth ? 8 : 24), in tcx_ioctl()
327 struct tcx_par *par = (struct tcx_par *)info->par; in tcx_init_fix() local
330 if (par->lowdepth) in tcx_init_fix()
346 struct tcx_par *par) in tcx_unmap_regs() argument
348 if (par->tec) in tcx_unmap_regs()
350 par->tec, sizeof(struct tcx_tec)); in tcx_unmap_regs()
351 if (par->thc) in tcx_unmap_regs()
353 par->thc, sizeof(struct tcx_thc)); in tcx_unmap_regs()
354 if (par->bt) in tcx_unmap_regs()
356 par->bt, sizeof(struct bt_regs)); in tcx_unmap_regs()
357 if (par->cplane) in tcx_unmap_regs()
359 par->cplane, info->fix.smem_len * sizeof(u32)); in tcx_unmap_regs()
369 struct tcx_par *par; in tcx_probe() local
377 par = info->par; in tcx_probe()
379 spin_lock_init(&par->lock); in tcx_probe()
381 par->lowdepth = in tcx_probe()
393 par->tec = of_ioremap(&op->resource[7], 0, in tcx_probe()
395 par->thc = of_ioremap(&op->resource[9], 0, in tcx_probe()
397 par->bt = of_ioremap(&op->resource[8], 0, in tcx_probe()
401 if (!par->tec || !par->thc || in tcx_probe()
402 !par->bt || !info->screen_base) in tcx_probe()
405 memcpy(&par->mmap_map, &__tcx_mmap_map, sizeof(par->mmap_map)); in tcx_probe()
406 if (!par->lowdepth) { in tcx_probe()
407 par->cplane = of_ioremap(&op->resource[4], 0, in tcx_probe()
410 if (!par->cplane) in tcx_probe()
413 par->mmap_map[1].size = SBUS_MMAP_EMPTY; in tcx_probe()
414 par->mmap_map[4].size = SBUS_MMAP_EMPTY; in tcx_probe()
415 par->mmap_map[5].size = SBUS_MMAP_EMPTY; in tcx_probe()
416 par->mmap_map[6].size = SBUS_MMAP_EMPTY; in tcx_probe()
420 par->which_io = op->resource[0].flags & IORESOURCE_BITS; in tcx_probe()
438 par->mmap_map[i].poff = op->resource[j].start; in tcx_probe()
445 sbus_writel(0x04 << 24, &par->bt->addr); /* color planes */ in tcx_probe()
446 sbus_writel(0xff << 24, &par->bt->control); in tcx_probe()
447 sbus_writel(0x05 << 24, &par->bt->addr); in tcx_probe()
448 sbus_writel(0x00 << 24, &par->bt->control); in tcx_probe()
449 sbus_writel(0x06 << 24, &par->bt->addr); /* overlay plane */ in tcx_probe()
450 sbus_writel(0x73 << 24, &par->bt->control); in tcx_probe()
451 sbus_writel(0x07 << 24, &par->bt->addr); in tcx_probe()
452 sbus_writel(0x00 << 24, &par->bt->control); in tcx_probe()
472 par->which_io, in tcx_probe()
474 par->lowdepth ? "8-bit only" : "24-bit depth"); in tcx_probe()
482 tcx_unmap_regs(op, info, par); in tcx_probe()
492 struct tcx_par *par = info->par; in tcx_remove() local
497 tcx_unmap_regs(op, info, par); in tcx_remove()