| 196 | */ |
| 197 | |
| 198 | rt_inline int ttydev_enter(struct lwp_tty *tp) |
| 199 | { |
| 200 | rt_err_t error = tty_lock(tp); |
| 201 | if (error) |
| 202 | RT_ASSERT(0); |
| 203 | |
| 204 | if (tty_gone(tp) || !tty_opened(tp)) |
| 205 | { |
| 206 | /* Device is already gone. */ |
| 207 | tty_unlock(tp); |
| 208 | return -ENXIO; |
| 209 | } |
| 210 | |
| 211 | return 0; |
| 212 | } |
| 213 | |
| 214 | static void ttydev_leave(struct lwp_tty *tp) |
| 215 | { |
no outgoing calls
no test coverage detected