aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/rfnoc
diff options
context:
space:
mode:
authorKevin Gilbert (kegilbert) <kevin.gilbert@ni.com>2016-12-07 15:09:34 -0600
committerMartin Braun <martin.braun@ettus.com>2016-12-08 14:23:37 -0800
commitccd681e45937216b400f6bda326f11627a7e6def (patch)
tree1c1145ab3451d847cc323bb1102116c7a4fb7d6b /host/lib/rfnoc
parenteb2ba5ea16445c1cef1fb8dbef72d78dcf8c68a3 (diff)
downloaduhd-ccd681e45937216b400f6bda326f11627a7e6def.tar.gz
uhd-ccd681e45937216b400f6bda326f11627a7e6def.tar.bz2
uhd-ccd681e45937216b400f6bda326f11627a7e6def.zip
Move motherboard index increment to after channel map index. This will
properly map the channel index to the motherboard in chan_to_mcp(...).
Diffstat (limited to 'host/lib/rfnoc')
-rw-r--r--host/lib/rfnoc/legacy_compat.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/host/lib/rfnoc/legacy_compat.cpp b/host/lib/rfnoc/legacy_compat.cpp
index 631e89273..e235bdbbd 100644
--- a/host/lib/rfnoc/legacy_compat.cpp
+++ b/host/lib/rfnoc/legacy_compat.cpp
@@ -446,8 +446,7 @@ private: // methods
mboard_idx = 0;
mb_chan_idx = chan;
while (mb_chan_idx >= chan_map[mboard_idx].size()) {
- mboard_idx++;
- mb_chan_idx -= chan_map[mboard_idx].size();
+ mb_chan_idx -= chan_map[mboard_idx++].size();
}
if (mboard_idx >= chan_map.size()) {
throw uhd::index_error(str(