aboutsummaryrefslogtreecommitdiffstats
path: root/host
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2020-04-14 22:38:56 -0700
committerAaron Rossetto <aaron.rossetto@ni.com>2020-04-17 14:36:44 -0500
commiteb44ce6f4bef11659baed3f7e55b54871b6ba043 (patch)
tree568a58771e47dac1dec3eb5621f00c0c681d744f /host
parent0f105cca21d5337ec7d6a711b25fe0507612de76 (diff)
downloaduhd-eb44ce6f4bef11659baed3f7e55b54871b6ba043.tar.gz
uhd-eb44ce6f4bef11659baed3f7e55b54871b6ba043.tar.bz2
uhd-eb44ce6f4bef11659baed3f7e55b54871b6ba043.zip
rh: Remove compiler warning
Adds UHD_UNUSED() to tag variables that is only used in a UHD_LOG_TRACE() macro. Note this would be also be possible by tagging the local functions {rx,tx}_band_to_log as unused, but g++ does not support that specific kind of attribute, at least in the current versions.
Diffstat (limited to 'host')
-rw-r--r--host/lib/usrp/dboard/rhodium/rhodium_radio_control_cpld.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/host/lib/usrp/dboard/rhodium/rhodium_radio_control_cpld.cpp b/host/lib/usrp/dboard/rhodium/rhodium_radio_control_cpld.cpp
index f4f17e8ab..8316f0a04 100644
--- a/host/lib/usrp/dboard/rhodium/rhodium_radio_control_cpld.cpp
+++ b/host/lib/usrp/dboard/rhodium/rhodium_radio_control_cpld.cpp
@@ -73,7 +73,8 @@ void rhodium_radio_control_impl::_update_rx_freq_switches(const double freq)
{
RFNOC_LOG_TRACE("Update all RX freq related switches. f=" << freq << " Hz");
const auto band = _map_freq_to_rx_band(freq);
- RFNOC_LOG_TRACE("Selected band " << rx_band_to_log(band));
+ const auto UHD_UNUSED(log_band) = rx_band_to_log(band);
+ RFNOC_LOG_TRACE("Selected band " << log_band);
// select values for lowband/highband switches
const bool is_lowband = (band == rx_band::RX_BAND_0);
@@ -139,7 +140,8 @@ void rhodium_radio_control_impl::_update_tx_freq_switches(const double freq)
{
RFNOC_LOG_TRACE("Update all TX freq related switches. f=" << freq << " Hz");
const auto band = _map_freq_to_tx_band(freq);
- RFNOC_LOG_TRACE("Selected band " << tx_band_to_log(band));
+ const auto UHD_UNUSED(log_band) = tx_band_to_log(band);
+ RFNOC_LOG_TRACE("Selected band " << log_band);
// select values for lowband/highband switches
const bool is_lowband = (band == tx_band::TX_BAND_0);