Lines Matching refs:p
67 static void riowd_writereg(struct riowd *p, u8 val, int index) in riowd_writereg() argument
71 spin_lock_irqsave(&p->lock, flags); in riowd_writereg()
72 writeb(index, p->regs + 0); in riowd_writereg()
73 writeb(val, p->regs + 1); in riowd_writereg()
74 spin_unlock_irqrestore(&p->lock, flags); in riowd_writereg()
96 struct riowd *p = riowd_device; in riowd_ioctl() local
113 riowd_writereg(p, riowd_timeout, WDTO_INDEX); in riowd_ioctl()
121 riowd_writereg(p, 0, WDTO_INDEX); in riowd_ioctl()
123 riowd_writereg(p, riowd_timeout, WDTO_INDEX); in riowd_ioctl()
135 riowd_writereg(p, riowd_timeout, WDTO_INDEX); in riowd_ioctl()
151 struct riowd *p = riowd_device; in riowd_write() local
154 riowd_writereg(p, riowd_timeout, WDTO_INDEX); in riowd_write()
179 struct riowd *p; in riowd_probe() local
186 p = devm_kzalloc(&op->dev, sizeof(*p), GFP_KERNEL); in riowd_probe()
187 if (!p) in riowd_probe()
190 spin_lock_init(&p->lock); in riowd_probe()
192 p->regs = of_ioremap(&op->resource[0], 0, 2, DRIVER_NAME); in riowd_probe()
193 if (!p->regs) { in riowd_probe()
198 riowd_device = p; in riowd_probe()
207 riowd_timeout, p->regs); in riowd_probe()
209 platform_set_drvdata(op, p); in riowd_probe()
214 of_iounmap(&op->resource[0], p->regs, 2); in riowd_probe()
222 struct riowd *p = platform_get_drvdata(op); in riowd_remove() local
225 of_iounmap(&op->resource[0], p->regs, 2); in riowd_remove()