diff options
| author | Ashish Chaudhari <ashish@ettus.com> | 2015-03-18 09:19:06 -0700 | 
|---|---|---|
| committer | Ashish Chaudhari <ashish@ettus.com> | 2015-03-18 09:19:06 -0700 | 
| commit | 0634323a51a32ebc288383856af4cd150eae1aa8 (patch) | |
| tree | b67b3a09818588f8c16b45fe0d35b12fbee7d35d /host/lib/usrp/b200 | |
| parent | 306b5243e12af0db493856ad8397abac9835db0c (diff) | |
| parent | f9740c893bc4235aba347bc7fec867c7d9024b3f (diff) | |
| download | uhd-0634323a51a32ebc288383856af4cd150eae1aa8.tar.gz uhd-0634323a51a32ebc288383856af4cd150eae1aa8.tar.bz2 uhd-0634323a51a32ebc288383856af4cd150eae1aa8.zip | |
Merge branch 'maint'
Diffstat (limited to 'host/lib/usrp/b200')
| -rw-r--r-- | host/lib/usrp/b200/b200_iface.cpp | 8 | ||||
| -rw-r--r-- | host/lib/usrp/b200/b200_impl.cpp | 2 | 
2 files changed, 6 insertions, 4 deletions
| diff --git a/host/lib/usrp/b200/b200_iface.cpp b/host/lib/usrp/b200/b200_iface.cpp index 820090959..0f799e571 100644 --- a/host/lib/usrp/b200/b200_iface.cpp +++ b/host/lib/usrp/b200/b200_iface.cpp @@ -89,7 +89,7 @@ typedef boost::uint32_t hash_type;   * Create a file hash   * The hash will be used to identify the loaded firmware and fpga image   * \param filename file used to generate hash value - * \return hash value in a size_t type + * \return hash value in a uint32_t type   */  static hash_type generate_hash(const char *filename)  { @@ -101,13 +101,15 @@ static hash_type generate_hash(const char *filename)          throw uhd::io_error(std::string("cannot open input file ") + filename);      } -    size_t hash = 0; +    hash_type hash = 0;      char ch;      long long count = 0;      while (file.get(ch)) {          count++; -        boost::hash_combine(hash, ch); +        //hash algorithm derived from boost hash_combine +        //http://www.boost.org/doc/libs/1_35_0/doc/html/boost/hash_combine_id241013.html +        hash ^= ch + 0x9e3779b9 + (hash<<6) + (hash>>2);      }      if (count == 0){ diff --git a/host/lib/usrp/b200/b200_impl.cpp b/host/lib/usrp/b200/b200_impl.cpp index 647c64695..e0a5e2c2b 100644 --- a/host/lib/usrp/b200/b200_impl.cpp +++ b/host/lib/usrp/b200/b200_impl.cpp @@ -1025,7 +1025,7 @@ void b200_impl::update_gpio_state(void)          | (_gpio_state.ref_sel << 0)      ; -    _local_ctrl->poke32(TOREG(RB32_CORE_MISC), misc_word); +    _local_ctrl->poke32(TOREG(SR_CORE_MISC), misc_word);  }  void b200_impl::reset_codec_dcm(void) | 
