Fix RTIO exception messages
Signed-off-by: Egor Savkin <es@m-labs.hk>
This commit is contained in:
parent
527189ab6a
commit
3238ad2ef0
|
@ -199,7 +199,7 @@ pub extern fn dma_playback(timestamp: i64, ptr: i32) {
|
||||||
csr::rtio_dma::error_write(1);
|
csr::rtio_dma::error_write(1);
|
||||||
if error & 1 != 0 {
|
if error & 1 != 0 {
|
||||||
artiq_raise!("RTIOUnderflow",
|
artiq_raise!("RTIOUnderflow",
|
||||||
format!("RTIO underflow at channel {}:{}, {{0}} mu", channel, resolve_channel_name(channel as u32)),
|
format!("RTIO underflow at {{0}} mu, channel {}:{}", channel, resolve_channel_name(channel as u32)),
|
||||||
timestamp as i64, channel as i64, 0);
|
timestamp as i64, channel as i64, 0);
|
||||||
}
|
}
|
||||||
if error & 2 != 0 {
|
if error & 2 != 0 {
|
||||||
|
|
|
@ -88,7 +88,7 @@ unsafe fn process_exceptional_status(channel: i32, status: i32) {
|
||||||
}
|
}
|
||||||
if status & RTIO_O_STATUS_UNDERFLOW != 0 {
|
if status & RTIO_O_STATUS_UNDERFLOW != 0 {
|
||||||
artiq_raise!("RTIOUnderflow",
|
artiq_raise!("RTIOUnderflow",
|
||||||
format!("RTIO underflow at channel {}:{}, {{1}} mu, slack {{2}} mu", channel, resolve_channel_name(channel as u32)),
|
format!("RTIO underflow at {{1}} mu, channel {}:{}, slack {{2}} mu", channel, resolve_channel_name(channel as u32)),
|
||||||
channel as i64, timestamp, timestamp - get_counter());
|
channel as i64, timestamp, timestamp - get_counter());
|
||||||
}
|
}
|
||||||
if status & RTIO_O_STATUS_DESTINATION_UNREACHABLE != 0 {
|
if status & RTIO_O_STATUS_DESTINATION_UNREACHABLE != 0 {
|
||||||
|
|
|
@ -73,7 +73,7 @@ unsafe fn process_exceptional_status(channel: i32, status: u8) {
|
||||||
}
|
}
|
||||||
if status & RTIO_O_STATUS_UNDERFLOW != 0 {
|
if status & RTIO_O_STATUS_UNDERFLOW != 0 {
|
||||||
artiq_raise!("RTIOUnderflow",
|
artiq_raise!("RTIOUnderflow",
|
||||||
format!("RTIO underflow at channel {}:{}, {{1}} mu, slack {{2}} mu", channel, resolve_channel_name(channel as u32)),
|
format!("RTIO underflow at {{1}} mu, channel {}:{}, slack {{2}} mu", channel, resolve_channel_name(channel as u32)),
|
||||||
channel as i64, timestamp, timestamp - get_counter());
|
channel as i64, timestamp, timestamp - get_counter());
|
||||||
}
|
}
|
||||||
if status & RTIO_O_STATUS_DESTINATION_UNREACHABLE != 0 {
|
if status & RTIO_O_STATUS_DESTINATION_UNREACHABLE != 0 {
|
||||||
|
|
|
@ -348,7 +348,7 @@ fn read_device_map(cfg: &Config) -> BTreeMap<u32, String> {
|
||||||
let channel = bytes_cr.read_u32().unwrap();
|
let channel = bytes_cr.read_u32().unwrap();
|
||||||
let device_name = bytes_cr.read_string().unwrap();
|
let device_name = bytes_cr.read_string().unwrap();
|
||||||
if let Some(old_entry) = device_map.insert(channel, device_name.clone()) {
|
if let Some(old_entry) = device_map.insert(channel, device_name.clone()) {
|
||||||
error!("conflicting entries for channel {}: `{}` and `{}`",
|
error!("read_device_map: conflicting entries for channel {}: `{}` and `{}`",
|
||||||
channel, old_entry, device_name);
|
channel, old_entry, device_name);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue