From b9280e8d5fd8e045c484d2396229312dea33dd54 Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Mon, 27 Jun 2011 11:30:49 -0700 Subject: uhd: fixed sse2 conversion bounds check --- host/lib/convert/convert_with_sse2.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/host/lib/convert/convert_with_sse2.cpp b/host/lib/convert/convert_with_sse2.cpp index 9772028dc..0cbb2c444 100644 --- a/host/lib/convert/convert_with_sse2.cpp +++ b/host/lib/convert/convert_with_sse2.cpp @@ -28,7 +28,7 @@ DECLARE_CONVERTER(convert_fc32_1_to_item32_1_nswap, PRIORITY_CUSTOM){ const __m128 scalar = _mm_set_ps1(float(scale_factor)); #define convert_fc32_1_to_item32_1_nswap_guts(_al_) \ - for (; i < (nsamps & ~0x3); i+=4){ \ + for (; i+4 < nsamps; i+=4){ \ /* load from input */ \ __m128 tmplo = _mm_load ## _al_ ## _ps(reinterpret_cast(input+i+0)); \ __m128 tmphi = _mm_load ## _al_ ## _ps(reinterpret_cast(input+i+2)); \ @@ -71,7 +71,7 @@ DECLARE_CONVERTER(convert_fc32_1_to_item32_1_bswap, PRIORITY_CUSTOM){ const __m128 scalar = _mm_set_ps1(float(scale_factor)); #define convert_fc32_1_to_item32_1_bswap_guts(_al_) \ - for (; i < (nsamps & ~0x3); i+=4){ \ + for (; i+4 < nsamps; i+=4){ \ /* load from input */ \ __m128 tmplo = _mm_load ## _al_ ## _ps(reinterpret_cast(input+i+0)); \ __m128 tmphi = _mm_load ## _al_ ## _ps(reinterpret_cast(input+i+2)); \ @@ -114,7 +114,7 @@ DECLARE_CONVERTER(convert_item32_1_to_fc32_1_nswap, PRIORITY_CUSTOM){ const __m128i zeroi = _mm_setzero_si128(); #define convert_item32_1_to_fc32_1_nswap_guts(_al_) \ - for (; i < (nsamps & ~0x3); i+=4){ \ + for (; i+4 < nsamps; i+=4){ \ /* load from input */ \ __m128i tmpi = _mm_loadu_si128(reinterpret_cast(input+i)); \ \ @@ -159,7 +159,7 @@ DECLARE_CONVERTER(convert_item32_1_to_fc32_1_bswap, PRIORITY_CUSTOM){ const __m128i zeroi = _mm_setzero_si128(); #define convert_item32_1_to_fc32_1_bswap_guts(_al_) \ - for (; i < (nsamps & ~0x3); i+=4){ \ + for (; i+4 < nsamps; i+=4){ \ /* load from input */ \ __m128i tmpi = _mm_loadu_si128(reinterpret_cast(input+i)); \ \ -- cgit v1.2.3 From a3e1cb78b4c9791fbd3703d632cf22fa4005ee6c Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Tue, 28 Jun 2011 15:06:37 -0700 Subject: e100: disable eeprom read so double open can work for now --- host/lib/usrp/usrp_e100/usrp_e100_impl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/host/lib/usrp/usrp_e100/usrp_e100_impl.cpp b/host/lib/usrp/usrp_e100/usrp_e100_impl.cpp index 5b039aafc..ae0c0b1b7 100644 --- a/host/lib/usrp/usrp_e100/usrp_e100_impl.cpp +++ b/host/lib/usrp/usrp_e100/usrp_e100_impl.cpp @@ -55,8 +55,8 @@ static device_addrs_t usrp_e100_find(const device_addr_t &hint){ new_addr["node"] = fs::system_complete(fs::path(hint["node"])).string(); try{ usrp_e100_iface::sptr iface = usrp_e100_iface::make(new_addr["node"]); - new_addr["name"] = iface->mb_eeprom["name"]; - new_addr["serial"] = iface->mb_eeprom["serial"]; + new_addr["name"] = "";//FIXME for double open on next branch iface->mb_eeprom["name"]; + new_addr["serial"] = "";//FIXME for double open on next branch iface->mb_eeprom["serial"]; } catch(const std::exception &e){ new_addr["name"] = ""; -- cgit v1.2.3