-
Notifications
You must be signed in to change notification settings - Fork 645
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
uhd_tx_streamer_send, uhd_tx_streamer_recv_async_msg - Crashes #171
Comments
@nitha2000 Yes, this looks like a duplicate of #134. It looks like srsLTE may be passing in a bad parameter to the functions or there is some problem with the uhd_tx_streamer_handle (i.e. race condition between initialization and use). If you compile the Debug version of UHD, it should give a much better stack trace. Is that possible for you to do? |
I recompiled the UHD driver with this option "cmake -DCMAKE_BUILD_TYPE=Debug ../", When it crashed i'm still getting the same output, not much better stack trace as you mentioned. Am I missing anything ?
|
With gdb. I got this as bt. Program received signal SIGABRT, Aborted. #0 0x00007ffff622bc37 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56 |
@nitha2000 That is extremely helpful. It looks like the exception is thrown when the managed_send_buffer is dereferenced. Looking over the source code (specifically host/lib/transport/super_send_packet_handler.hpp), it looks like the only way that can happen is if multiple threads are calling send() on the same streamer object. Is your application calling rf_uhd_send_timed() or rf_uhd_send_timed_multi() from multiple threads? |
From the points #10 and #11 below, it looks like srsLte is calling rf_uhd_send_timed_multi (). #10 0x00007ffff71f9619 in rf_uhd_send_timed_multi (h=0x7308750, data=0x7fffd52c16f0, nsamples=11520, secs=91, frac_secs=0.38894716530721063, has_time_spec=true, blocking=true, is_start_of_burst=false, #11 0x00007ffff71f70b4 in srslte_rf_send_timed_multi (rf=0x7fffde561080, data=0x7fffd52c16f0, nsamples=11520, secs=91, frac_secs=0.38894716530721063, blocking=true, is_start_of_burst=false, is_end_of_burst=false) |
Those are 2 different function calls. the function srslte_rf_send_timed_multi(#11) calls rf_uhd_send_timed_multi(#10). That is OK and is probably what is supposed to happen. The backtrace is only looking at one thread. I suspect a concurrent thread also called into a send function. It's really the only way this type of error can occur. |
I meant to ask what was the diff. btw these two calls; rf_uhd_send_timed() or rf_uhd_send_timed_multi(). |
The uhd_tx_streamer_send() and uhd_tx_streamer_recv_async_msg() functions are not thread safe, so it is up to the application to do serialization where necessary. I would recommend putting a lock/mutex in the srsLTE code where those functions are called. |
Hi,
It looks like this issue is related or somewhat similar to the issues addressed by #134 , #144.
I can reproduce this issue with very little effort and I can provide more info as needed.
CLUES:
I see this issue very often when the freq difference between TX and RX is higher (Non. standard band)
Ex: 1600MHz (DL) 700MHz (UL).
When the BW is 20MHz it happens very often.
ENV:
B210 with "linux; GNU C++ version 4.8.4; Boost_105400; UHD_003.010.003.000-0-unknown
Ubuntu 14.04.5 LTS
CPU:
x64, Intel(R) Core(TM) i7-5557U CPU @ 3.10GHz, Quad-core
The text was updated successfully, but these errors were encountered: