Lines Matching refs:at
45 #define vtb_wrap(vtb, at, offset) \ argument
46 (((at) + (offset) + (vtb)->vtb_size)%(vtb)->vtb_size)
118 sc_vtb_getc(sc_vtb_t *vtb, int at) in sc_vtb_getc() argument
121 return (readw(sc_vtb_pointer(vtb, at)) & 0x00ff); in sc_vtb_getc()
123 return (*(u_int16_t *)sc_vtb_pointer(vtb, at) & 0x00ff); in sc_vtb_getc()
127 sc_vtb_geta(sc_vtb_t *vtb, int at) in sc_vtb_geta() argument
130 return (readw(sc_vtb_pointer(vtb, at)) & 0xff00); in sc_vtb_geta()
132 return (*(u_int16_t *)sc_vtb_pointer(vtb, at) & 0xff00); in sc_vtb_geta()
136 sc_vtb_putc(sc_vtb_t *vtb, int at, int c, int a) in sc_vtb_putc() argument
139 writew(sc_vtb_pointer(vtb, at), a | c); in sc_vtb_putc()
141 *(u_int16_t *)sc_vtb_pointer(vtb, at) = a | c; in sc_vtb_putc()
155 sc_vtb_pointer(sc_vtb_t *vtb, int at) in sc_vtb_pointer() argument
157 return (vtb->vtb_buffer + sizeof(u_int16_t)*(at)); in sc_vtb_pointer()
224 sc_vtb_erase(sc_vtb_t *vtb, int at, int count, int c, int attr) in sc_vtb_erase() argument
226 if (at + count > vtb->vtb_size) in sc_vtb_erase()
227 count = vtb->vtb_size - at; in sc_vtb_erase()
229 fillw_io(attr | c, sc_vtb_pointer(vtb, at), count); in sc_vtb_erase()
231 fillw(attr | c, (void *)sc_vtb_pointer(vtb, at), count); in sc_vtb_erase()
252 sc_vtb_delete(sc_vtb_t *vtb, int at, int count, int c, int attr) in sc_vtb_delete() argument
256 if (at + count > vtb->vtb_size) in sc_vtb_delete()
257 count = vtb->vtb_size - at; in sc_vtb_delete()
258 len = vtb->vtb_size - at - count; in sc_vtb_delete()
261 bcopy_io(sc_vtb_pointer(vtb, at + count), in sc_vtb_delete()
262 sc_vtb_pointer(vtb, at), in sc_vtb_delete()
265 bcopy((void *)sc_vtb_pointer(vtb, at + count), in sc_vtb_delete()
266 (void *)sc_vtb_pointer(vtb, at), in sc_vtb_delete()
270 fillw_io(attr | c, sc_vtb_pointer(vtb, at + len), in sc_vtb_delete()
271 vtb->vtb_size - at - len); in sc_vtb_delete()
273 fillw(attr | c, (void *)sc_vtb_pointer(vtb, at + len), in sc_vtb_delete()
274 vtb->vtb_size - at - len); in sc_vtb_delete()
278 sc_vtb_ins(sc_vtb_t *vtb, int at, int count, int c, int attr) in sc_vtb_ins() argument
280 if (at + count > vtb->vtb_size) in sc_vtb_ins()
281 count = vtb->vtb_size - at; in sc_vtb_ins()
284 bcopy_io(sc_vtb_pointer(vtb, at), in sc_vtb_ins()
285 sc_vtb_pointer(vtb, at + count), in sc_vtb_ins()
286 (vtb->vtb_size - at - count)*sizeof(u_int16_t)); in sc_vtb_ins()
288 bcopy((void *)sc_vtb_pointer(vtb, at), in sc_vtb_ins()
289 (void *)sc_vtb_pointer(vtb, at + count), in sc_vtb_ins()
290 (vtb->vtb_size - at - count)*sizeof(u_int16_t)); in sc_vtb_ins()
293 fillw_io(attr | c, sc_vtb_pointer(vtb, at), count); in sc_vtb_ins()
295 fillw(attr | c, (void *)sc_vtb_pointer(vtb, at), count); in sc_vtb_ins()