Searched refs:TtyError (Results 1 – 2 of 2) sorted by relevance
/DragonOS-0.1.8/kernel/src/driver/tty/ |
D | mod.rs | 65 pub enum TtyError { enum 105 pub fn input(&self, buf: &[u8], block: bool) -> Result<usize, TtyError> { in input() argument 122 pub fn output(&self, buf: &mut [u8], block: bool) -> Result<usize, TtyError> { in output() argument 133 pub fn stdout(&self, buf: &[u8], block: bool) -> Result<usize, TtyError> { in stdout() argument 144 pub fn stderr(&self, buf: &[u8], block: bool) -> Result<usize, TtyError> { in stderr() argument 155 pub fn read_stdin(&self, buf: &mut [u8], block: bool) -> Result<usize, TtyError> { in read_stdin() argument 162 TryRecvError::Closed => return Err(TtyError::Closed), in read_stdin() 170 _ => return Err(TtyError::Unknown(format!("{err:?}"))), in read_stdin() 199 fn write_stdin(&self, buf: &[u8], block: bool) -> Result<usize, TtyError> { in write_stdin() argument 205 TrySendError::Closed(_) => return Err(TtyError::Closed), in write_stdin() [all …]
|
D | tty_device.rs | 18 use super::{TtyCore, TtyError, TtyFileFlag, TtyFilePrivateData}; 87 let r: Result<usize, TtyError> = self.core.input(buf, false); in input() 94 TtyError::BufferFull(x) => return Ok(x), in input() 95 TtyError::Closed => return Err(SystemError::ENODEV), in input() 159 let r: Result<usize, TtyError> = self.core.read_stdin(&mut buf[0..len], true); in read_at() 165 TtyError::EOF(n) => { in read_at() 194 let r: Result<usize, TtyError> = if data.flags.contains(TtyFileFlag::STDOUT) { in write_at() 207 let r: TtyError = r.unwrap_err(); in write_at() 242 let r: Result<usize, TtyError> = self.core.output(&mut buf[0..511], false); in sync() 248 Err(TtyError::EOF(x)) | Err(TtyError::BufferEmpty(x)) => { in sync()
|