Lines Matching refs:index

104 static struct hvc_struct *hvc_get_by_index(int index)  in hvc_get_by_index()  argument
113 if (hp->index == index) { in hvc_get_by_index()
148 int r, donecr = 0, index = co->index; in hvc_console_print() local
151 if (index >= MAX_NR_HVC_CONSOLES) in hvc_console_print()
155 if (vtermnos[index] == -1) in hvc_console_print()
169 r = cons_ops[index]->put_chars(vtermnos[index], c, i); in hvc_console_print()
184 static struct tty_driver *hvc_console_device(struct console *c, int *index) in hvc_console_device() argument
186 if (vtermnos[c->index] == -1) in hvc_console_device()
189 *index = c->index; in hvc_console_device()
195 if (co->index < 0 || co->index >= MAX_NR_HVC_CONSOLES) in hvc_console_setup()
198 if (vtermnos[co->index] == -1) in hvc_console_setup()
210 .index = -1,
252 static void hvc_check_console(int index) in hvc_check_console() argument
262 if (index == hvc_console.index) in hvc_check_console()
272 int hvc_instantiate(uint32_t vtermno, int index, const struct hv_ops *ops) in hvc_instantiate() argument
276 if (index < 0 || index >= MAX_NR_HVC_CONSOLES) in hvc_instantiate()
279 if (vtermnos[index] != -1) in hvc_instantiate()
283 hp = hvc_get_by_index(index); in hvc_instantiate()
289 vtermnos[index] = vtermno; in hvc_instantiate()
290 cons_ops[index] = ops; in hvc_instantiate()
293 if (last_hvc < index) in hvc_instantiate()
294 last_hvc = index; in hvc_instantiate()
297 hvc_check_console(index); in hvc_instantiate()
322 hp = hvc_get_by_index(tty->index); in hvc_install()
673 if (hp->index == hvc_console.index) { in hvc_poll()
903 hp->index = i; in hvc_alloc()
925 if (hp->index < MAX_NR_HVC_CONSOLES) { in hvc_remove()
927 vtermnos[hp->index] = -1; in hvc_remove()
928 cons_ops[hp->index] = NULL; in hvc_remove()