Lines Matching refs:index
38 for (index, driver) in drivers_guard.iter().enumerate() { in lookup_tty_driver()
43 return Some((index, driver.clone())); in lookup_tty_driver()
140 pub fn tty_line_name(&self, index: usize) -> String { in tty_line_name()
147 return format!("{}{}", self.name, index + self.name_base); in tty_line_name()
152 self.ttys.lock().insert(tty_core.core().index(), tty_core); in add_tty()
166 fn lockup_tty(&self, index: usize) -> Option<Arc<TtyCore>> { in lockup_tty()
168 return match device_guard.get(&index) { in lockup_tty()
176 let tty_index = tty.index(); in standard_install()
212 fn init_tty_device(driver: Arc<TtyDriver>, index: usize) -> Result<Arc<TtyCore>, SystemError> { in init_tty_device()
213 let tty = TtyCore::new(driver.clone(), index); in init_tty_device()
220 TTY_PORTS[core.index()].setup_tty(Arc::downgrade(&tty)); in init_tty_device()
221 tty.set_port(TTY_PORTS[core.index()].clone()); in init_tty_device()
231 let (index, driver) = in open_tty()
234 let tty = match driver.lockup_tty(index) { in open_tty()
248 None => Self::init_tty_device(driver, index)?, in open_tty()
251 CURRENT_VCNUM.store(index as isize, Ordering::SeqCst); in open_tty()