From ebdb08180d09c4aa36d26d6f45ca5436c6d74444 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Wed, 16 Mar 2022 21:04:12 +0800 Subject: [PATCH] drtio: demote default routing table message to info --- src/libboard_artiq/src/drtio_routing.rs | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/src/libboard_artiq/src/drtio_routing.rs b/src/libboard_artiq/src/drtio_routing.rs index 9688ee35..e4d6b4f9 100644 --- a/src/libboard_artiq/src/drtio_routing.rs +++ b/src/libboard_artiq/src/drtio_routing.rs @@ -58,20 +58,17 @@ impl fmt::Display for RoutingTable { pub fn config_routing_table(default_n_links: usize, cfg: &Config) -> RoutingTable { let mut ret = RoutingTable::default_master(default_n_links); if let Ok(data) = cfg.read("routing_table") { - if data.len() == DEST_COUNT*MAX_HOPS - { + if data.len() == DEST_COUNT*MAX_HOPS { for i in 0..DEST_COUNT { for j in 0..MAX_HOPS { ret.0[i][j] = data[i*MAX_HOPS+j]; } } + } else { + warn!("length of the configured routing table is incorrect, using default"); } - else { - warn!("length of the routing table is incorrect, using default"); - } - } - else { - warn!("could not read routing table from configuration, using default"); + } else { + info!("could not read routing table from configuration, using default"); } info!("routing table: {}", ret); ret