moninj: log link down at debug level

pull/190/head
mwojcik 2022-05-20 17:32:43 +08:00
parent 24df52268e
commit 4f457d9c24
1 changed files with 3 additions and 4 deletions

View File

@ -20,8 +20,7 @@ use crate::proto_async::*;
pub enum Error { pub enum Error {
NetworkError(smoltcp::Error), NetworkError(smoltcp::Error),
UnexpectedPattern, UnexpectedPattern,
UnrecognizedPacket, UnrecognizedPacket
} }
pub type Result<T> = core::result::Result<T, Error>; pub type Result<T> = core::result::Result<T, Error>;
@ -72,7 +71,7 @@ mod remote_moninj {
match reply { match reply {
Ok(drtioaux_async::Packet::MonitorReply { value }) => return value as i64, Ok(drtioaux_async::Packet::MonitorReply { value }) => return value as i64,
Ok(packet) => error!("received unexpected aux packet: {:?}", packet), Ok(packet) => error!("received unexpected aux packet: {:?}", packet),
Err("link went down") => {}, Err("link went down") => { debug!("link is down"); },
Err(e) => error!("aux packet error ({})", e) Err(e) => error!("aux packet error ({})", e)
} }
0 0
@ -99,7 +98,7 @@ mod remote_moninj {
match reply { match reply {
Ok(drtioaux_async::Packet::InjectionStatusReply { value }) => return value as i8, Ok(drtioaux_async::Packet::InjectionStatusReply { value }) => return value as i8,
Ok(packet) => error!("received unexpected aux packet: {:?}", packet), Ok(packet) => error!("received unexpected aux packet: {:?}", packet),
Err("link went down") => {}, Err("link went down") => { debug!("link is down"); },
Err(e) => error!("aux packet error ({})", e) Err(e) => error!("aux packet error ({})", e)
} }
0 0