summaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/usrp1
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2012-04-23 13:45:23 -0700
committerJosh Blum <josh@joshknows.com>2012-04-23 13:45:23 -0700
commit253be8f0da4a030e5060020e38afe6edcf927930 (patch)
treee16c8a4fcdaeb995f8e59342930e85f768e3d40a /host/lib/usrp/usrp1
parentae40e8f5cc10288391961f48c5e55a719f2f80d7 (diff)
downloaduhd-253be8f0da4a030e5060020e38afe6edcf927930.tar.gz
uhd-253be8f0da4a030e5060020e38afe6edcf927930.tar.bz2
uhd-253be8f0da4a030e5060020e38afe6edcf927930.zip
uhd: squashed transport work
Diffstat (limited to 'host/lib/usrp/usrp1')
-rw-r--r--host/lib/usrp/usrp1/io_impl.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/host/lib/usrp/usrp1/io_impl.cpp b/host/lib/usrp/usrp1/io_impl.cpp
index d256df660..1d8b9bd76 100644
--- a/host/lib/usrp/usrp1/io_impl.cpp
+++ b/host/lib/usrp/usrp1/io_impl.cpp
@@ -73,8 +73,8 @@ public:
/* NOP */
}
- void commit(size_t size){
- if (size != 0) this->_commit_cb(_curr_buff, _next_buff, size);
+ void release(void){
+ this->_commit_cb(_curr_buff, _next_buff, size());
}
sptr get_new(
@@ -83,13 +83,13 @@ public:
){
_curr_buff = curr_buff;
_next_buff = next_buff;
- return make_managed_buffer(this);
+ return make(this,
+ _curr_buff.buff->cast<char *>() + _curr_buff.offset,
+ _curr_buff.buff->size() - _curr_buff.offset
+ );
}
private:
- void *get_buff(void) const{return _curr_buff.buff->cast<char *>() + _curr_buff.offset;}
- size_t get_size(void) const{return _curr_buff.buff->size() - _curr_buff.offset;}
-
offset_send_buffer _curr_buff, _next_buff;
commit_cb_type _commit_cb;
};