fventuri / gr-osmosdr

gr-osmosdr GnuRadio OOT module for SDRplay API 3.x - supports RSPduo (all modes) and RSPdx
GNU General Public License v3.0
3 stars 1 forks source link

Segfault crash when changing frequency-correction #2

Open Dieter9 opened 3 years ago

Dieter9 commented 3 years ago

I am using gr-osmosdr with my SDRplay RSP1A and Gqrx Software. Things are going very well, with one exception: When Gqrx is started and the device is running, I can change the frequency-correction as I like. But when the device is not running and I change this value, gqrx crashes with segfault. The problem is, if the frequency-correction is added to the Gqrx configuration file, this will happen every time Gqrx is started. :(

latest software revisions installed:

The system-dump points to a problem in libgnuradio-osmosdr.so - sdrplay_source_c - set_freq_corr :

sdrplay_apiService[8733]: [8733]: sdrplay_apiService: sdrplay_apiServiceWorkerThread: Entry
Jan 20 11:36:27 linux1 kernel: audit: type=1130 audit(1611138987.001:180): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=sdrplay comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jan 20 11:36:27 linux1 kernel: audit: type=1106 audit(1611138987.001:181): pid=8727 uid=1000 auid=1000 ses=3 msg='op=PAM:session_close grantors=pam_limits,pam_unix,pam_permit acct="root" exe="/usr/bin/sudo" hostname=? addr=? terminal=/dev/pts/0 res=success'
Jan 20 11:36:27 linux1 kernel: audit: type=1104 audit(1611138987.001:182): pid=8727 uid=1000 auid=1000 ses=3 msg='op=PAM:setcred grantors=pam_faillock,pam_permit,pam_faillock acct="root" exe="/usr/bin/sudo" hostname=? addr=? terminal=/dev/pts/0 res=success'
Jan 20 11:36:27 linux1 sdrplay_apiService[8733]: [8734]: sdrplay_apiService_device: heartBeatThread: Entry
Jan 20 11:36:29 linux1 gqrx[8745]: [8745]: sdrplay_api_Open
Jan 20 11:36:54 linux1 audit[8745]: ANOM_ABEND auid=1000 uid=1000 gid=100 ses=3 pid=8745 comm="gqrx" exe="/usr/local/bin/gqrx" sig=11 res=1
Jan 20 11:36:54 linux1 kernel: gqrx[8745]: segfault at 0 ip 00007f360359147f sp 00007ffca8b44750 error 4 in libgnuradio-osmosdr.so.0.2.0.0[7f360353d000+88000]
Jan 20 11:36:54 linux1 kernel: Code: 68 fd ff ff 48 8d 15 c0 dd ff ff 48 8b 80 f8 00 00 00 48 39 d0 75 5c 5b 66 0f 28 c1 5d 41 5c c3 0f 1f 00 48 8b 90 20 01 00 00 <48> 8b 12 48 85 d2 74 cb 80 bb 81 00 00 00 00 f2 0f 11 40 78 75 43
Jan 20 11:36:54 linux1 kernel: audit: type=1701 audit(1611139014.637:183): auid=1000 uid=1000 gid=100 ses=3 pid=8745 comm="gqrx" exe="/usr/local/bin/gqrx" sig=11 res=1
Jan 20 11:36:54 linux1 audit: BPF prog-id=29 op=LOAD
Jan 20 11:36:54 linux1 audit: BPF prog-id=30 op=LOAD
Jan 20 11:36:54 linux1 systemd[1]: Started Process Core Dump (PID 8772/UID 0).
Jan 20 11:36:54 linux1 audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump@2-8772-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jan 20 11:36:54 linux1 kernel: audit: type=1334 audit(1611139014.647:184): prog-id=29 op=LOAD
Jan 20 11:36:54 linux1 kernel: audit: type=1334 audit(1611139014.647:185): prog-id=30 op=LOAD
Jan 20 11:36:54 linux1 kernel: audit: type=1130 audit(1611139014.647:186): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump@2-8772-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jan 20 11:36:55 linux1 systemd-coredump[8773]: [] Process 8745 (gqrx) of user 1000 dumped core.

                                              Stack trace of thread 8745:
                                              #0  0x00007f360359147f _ZThn664_N16sdrplay_source_c13set_freq_corrEdm (libgnuradio-osmosdr.so.0.2.0 + 0x6f47f)
                                              #1  0x00007f3603555602 _ZN11source_impl13set_freq_corrEdm (libgnuradio-osmosdr.so.0.2.0 + 0x33602)
                                              #2  0x000056412940c293 _ZN8receiver13set_freq_corrEd (gqrx + 0xb7293)
                                              #3  0x00007f360237de10 n/a (libQt5Core.so.5 + 0x2ece10)
                                              #4  0x00005641293edb13 _ZN12DockInputCtl15freqCorrChangedEd (gqrx + 0x98b13)
                                              #5  0x00005641293f5293 _ZN12DockInputCtl11qt_metacallEN11QMetaObject4CallEiPPv (gqrx + 0xa0293)
                                              #6  0x00007f360237db12 n/a (libQt5Core.so.5 + 0x2ecb12)
                                              #7  0x00007f3602fb5931 _ZN14QDoubleSpinBox12valueChangedEd (libQt5Widgets.so.5 + 0x301931)
                                              #8  0x00007f3602fb25a2 n/a (libQt5Widgets.so.5 + 0x2fe5a2)
                                              #9  0x00007f3602fb26ed n/a (libQt5Widgets.so.5 + 0x2fe6ed)
                                              #10 0x00007f360237de10 n/a (libQt5Core.so.5 + 0x2ece10)
                                              #11 0x00007f3602f52583 _ZN9QLineEdit11textChangedERK7QString (libQt5Widgets.so.5 + 0x29e583)
                                              #12 0x00007f360237de10 n/a (libQt5Core.so.5 + 0x2ece10)
                                              #13 0x00007f3602f59326 _ZN18QWidgetLineControl11textChangedERK7QString (libQt5Widgets.so.5 + 0x2a5326)
                                              #14 0x00007f3602f5c8be _ZN18QWidgetLineControl12finishChangeEibb (libQt5Widgets.so.5 + 0x2a88be)
                                              #15 0x00007f3602f5f1e7 _ZN18QWidgetLineControl15processKeyEventEP9QKeyEvent (libQt5Widgets.so.5 + 0x2ab1e7)
                                              #16 0x00007f3602f526dc _ZN9QLineEdit13keyPressEventEP9QKeyEvent (libQt5Widgets.so.5 + 0x29e6dc)
                                              #17 0x00007f3602e509c5 _ZN7QWidget5eventEP6QEvent (libQt5Widgets.so.5 + 0x19c9c5)
                                              #18 0x00007f3602fb1680 _ZN16QAbstractSpinBox13keyPressEventEP9QKeyEvent (libQt5Widgets.so.5 + 0x2fd680)
                                              #19 0x00007f3602e509c5 _ZN7QWidget5eventEP6QEvent (libQt5Widgets.so.5 + 0x19c9c5)
                                              #20 0x00007f3602e0e752 _ZN19QApplicationPrivate13notify_helperEP7QObjectP6QEvent (libQt5Widgets.so.5 + 0x15a752)
                                              #21 0x00007f3602e15db8 _ZN12QApplication6notifyEP7QObjectP6QEvent (libQt5Widgets.so.5 + 0x161db8)
                                              #22 0x00007f3602346a7a _ZN16QCoreApplication15notifyInternal2EP7QObjectP6QEvent (libQt5Core.so.5 + 0x2b5a7a)
                                              #23 0x00007f3602e6b69a n/a (libQt5Widgets.so.5 + 0x1b769a)
                                              #24 0x00007f3602e0e752 _ZN19QApplicationPrivate13notify_helperEP7QObjectP6QEvent (libQt5Widgets.so.5 + 0x15a752)
                                              #25 0x00007f3602346a7a _ZN16QCoreApplication15notifyInternal2EP7QObjectP6QEvent (libQt5Core.so.5 + 0x2b5a7a)
                                              #26 0x00007f360271c474 _ZN22QGuiApplicationPrivate15processKeyEventEPN29QWindowSystemInterfacePrivate8KeyEventE (libQt5Gui.so.5 + 0x136474)
                                              #27 0x00007f36026f5bb5 _ZN22QWindowSystemInterface22sendWindowSystemEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Gui.so.5 + 0x10fbb5)
                                              #28 0x00007f35fbfff16c n/a (libQt5XcbQpa.so.5 + 0x5f16c)
                                              #29 0x00007f35fd067a84 g_main_context_dispatch (libglib-2.0.so.0 + 0x52a84)
                                              #30 0x00007f35fd0bb9b1 n/a (libglib-2.0.so.0 + 0xa69b1)
                                              #31 0x00007f35fd0662b1 g_main_context_iteration (libglib-2.0.so.0 + 0x512b1)
                                              #32 0x00007f360239f6e1 _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Core.so.5 + 0x30e6e1)
                                              #33 0x00007f36023453fc _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5 + 0x2b43fc)
                                              #34 0x00007f360234d894 _ZN16QCoreApplication4execEv (libQt5Core.so.5 + 0x2bc894)
                                              #35 0x00005641293e72dd main (gqrx + 0x922dd)
                                              #36 0x00007f35feab2152 __libc_start_main (libc.so.6 + 0x28152)
                                              #37 0x00005641293ecd7e _start (gqrx + 0x97d7e)

Maybe it is possible to find a solution for this.

srs4511351 commented 7 months ago

I am having the seg fault using gr-osmosdr with my SDRplay RSP1A and Gqrx on a Raspberry Pi. It occurs when I change Freq correction without the DSP/SDR running and when I start gqrx with a freq correction value in place. See https://github.com/gqrx-sdr/gqrx/issues/1345