Age | Commit message (Collapse) | Author | Files | Lines |
|
Otherwise, it could happen that underrun events are lost:
TxLower (isUnderrun): RxLower (pullBuffer):
read(underrun)
read(underrun)
write(underrun, |val) [maybe underrun becomes TRUE]
write(underrun, false)
Similary, it could happen the other direction if atomic was only applied
to isUnderrun:
TxLower (isUnderrun): RxLower (pullBuffer):
read(underrun) -> true
read(underrun)-> true
write(underrun, false)
write(underrun, true|val) where val=false
So in here isUnderrun would return true twice while it should only
return one.
Change-Id: I684e0a5d2a9583a161d5a6593559b3a9e7cd57e3
|
|
This way switch is applied correctly to parent structures and features
can be used later by other children classes (other devices).
Change-Id: I24d6c66bb3195ba2513b4a67daa14cdfbacdce6d
|
|
Otherwise the parent function is always called even if the iface is
radioInterfaceMult.
Change-Id: Ie41efab1e60b88677bbd1ec333ea656794503a5a
|
|
In multi arfcn mode, osmo-trx would drop some bursts because it couldn't detect it
and would emit idle burst instead. Specificaly detection of peak in correlation
vector failed. Correcting copying of history in pullBuffer method fixes this issue.
[Re-worked by Pau Espin Pedrol <pespin@sysmocom.de>]
Fixes: 57df2362f0eca0a330aad3e18906046dfadb9c8b
Change-Id: I93e43f6868cd67e69fc59d2980a03550d2505bf8
|
|
from readSamples()
The only who should be setting class instance value "underrun" to false
is isUnderrun().
Similar fixes were already applied lately to radioInterface.cpp.
Change-Id: I3239b1df4536c080365106b3e4daa523b57f5dff
|
|
After previous changes, radioInterfaceMulti is expected to handle channel
conversion correctly, so it will always use chan 0 for all these
functions. This simplifies code in radioDevice avoiding need to add
checks to all devices supporting multi-arfcn in the future.
Change-Id: Ib2cd50a6ceaeedc6aaf3e1bb51d33b52911b6eba
|
|
Change-Id: I7e67f660c3b0b009db59b405de603f6058021802
|
|
It will be used in later commits by radioInterfaceMulti.
Change-Id: Ie3caca8971ed1e5370dfed6fb60716a24e7d82a5
|
|
Only the radioDevice->getRxGain() is called from inside
radioInterfaceMulti, so the API in radioInterface is not used at all.
Change-Id: Icc4e9a7ebfdafe7c72c535752a5e379d12592c9a
|
|
Change-Id: I11e853e11bec99fc88e81642f9b2cd87d5815398
|
|
Change-Id: I0d8fd51586ef01141d4e5896f0fc3029a22743f8
|
|
field rxGain is set to 0 during constructor and never set after that
point.
Change-Id: I7fae7a315e5ab98a15c27628a88a92226ef89469
|
|
It's not a pointer check or a boolean expression, in here we really
check chan index is 0, so it's more clear doing so this way like it's
done in all other places.
Change-Id: I83b14487d14ba8272f58796f640f58a88891e532
|
|
Previous naming is ready confusing, because "Radio" is actually the
common term between radioInterface and radioDevice, and it looks like
it's referring to radioInterface rather than radioDevice. On the other
hand, mDevice cleary states it refers to the radioDevice item.
Change-Id: I708bb1992a156fb63334f5590f2c6648ca27495e
|
|
BTS may have any timeslot disabled, or may have not yet sent initial
SETSLOT cmd to properly configure the timeslot.
Change-Id: Icf62e5d1200c7a440f255bb46023cdbf61532b7f
|
|
Change-Id: Ia0f2b5a51040663d7e8219e6ed51e0513b876548
|
|
Change-Id: I4f180cc852582b131ba28a8139215335f7ba567d
|
|
Change-Id: Iec33ab73a9bf90fd0bff9ba453c32ea11bf0670e
|
|
Since tn is declared as uint8_t, it's actually a char, and by default
c++'s ostream& operator<<(ostream&, unsigned char) tries to print chars
with its ASCII visible character instead of numeric value.
Change-Id: I534158e8e1719ad19a9cde7c747a8f8ad5a01a2b
|
|
Change-Id: I3099498e3a3f26b53d55a96a36cc056f7b25b27a
|
|
Related: OS#3343
Change-Id: Icd328e85b0a75ef67f371a7ed72638053b1854f9
|
|
Related: OS#3664
Change-Id: Id16248a1c03f9bc9f323c707857cdf3bf34c4e3e
|
|
We don't want to keep osmo-trx running in a started state once the BTS
controlling it becomes unavailable. If a socket towards the BTS fails,
it means the BTS is gone and the best thing to do is to stop the process
(alternatively we could go back to stopped state instead, and wait for
BTS to re-connect, fur so far this action is good enough).
Related: OS#4170
Change-Id: I2ccbe3c17b39fb792ea7810f840235c348054d66
|
|
pullRadioVector() should return true on idle frames because those
indications may be handled by upper layers (TRXDv1). Clarify return code
in function documentation.
Change-Id: If592ed1c04cf7e995f656b313f60edd4d40d1bfd
|
|
Use a packed structure to clearly indicate what is contained in the
received buffer.
Change-Id: I4d8c0e3c0c717699889f79e50c778d14b6058f2d
|
|
No need to continue further since anyway we'll end up exiting.
Change-Id: Id8b38b40df5744beb705d560defb06532cf0fd44
|
|
If osmo-trx is started and IP addr binding fails (ie because the IP
address is not assigned in the system), it will try to access a
heap-allocated Thread instance which was not initialized (because init()
function returned earlier).
Fixes: OS#4147
Change-Id: I19f9745cd026c0ff6581895a66bf91b40113b07d
|
|
This code is not needed anymore since we are setting SCHED_RR scheduler
with a real time priority in main thread during startup, so all threads
will inherit same rt priority, which should be enough to keep the
process working reliably even on high system loads (from non rt
processes).
osmo-trx was tested to be reliable during test with stress-ng as
explained in related ticket below.
Related: OS#2344
Change-Id: I3a88946dd71e9aeeaac9d19d396e2236c302b608
|
|
Since osmo-trx it's a big multithreaded process and shutdown sequence
can be complex, better use stderr to log signal received events to make
sure log is outputted straigh away and not buffered. In general stdout
is usually line-buffered, but buffering strategy can be more
conservative if output is for instance redirected to a file.
Change-Id: I70ba86919d1f7df41ef3db4916317d27697a025c
|
|
Previous commit started using IPPROTO_UDP without including required
include. Newer versions of libosmocore's osmocom/core/socket.h include
that header so the define is present, but older versions of libosmocore
(such as 0.12.0) don't, so let's include it explicitly (the correct
thing to do).
Fixes: b9d2515704ac83cacd88d0a73ecba30323df0b2d
Change-Id: I67ddf550f3a7fc6a650e1e1d9bde0bbb28785104
|
|
This file is only used by USRP1, so let's move it there and avoid
processing it in Makefiles if build for USRP1 is not requested at
configure time.
Change-Id: Ibb40ba487581e76d2ae3e8a420d631670f876cf0
|
|
Change-Id: Icccc18688ee54e669cf3452b08747b3509042fa2
|
|
Change-Id: Ib5a56cfe0c27d027bc0c60abda89e646a80849de
|
|
Change-Id: I15b687fbf436d662b264cb00f72b367ccd64b962
|
|
Change-Id: I4d6ef1f54f3d6c5a73ce00dc4640bd698f96842b
|
|
After discussion in [1] and further look at the code, it became obvios
rx_underrun events are not happening in general for any SDR (don't
exist), so let's drop that counter. Instead, add Tx Dropped Packet counters,
which were not accounted prior to this commit.
[1] https://github.com/osmocom/osmo-trx/commit/bde55afd29fc9aae10eb11f6515821afa39b772d
Change-Id: Iff1535c219a4695a511d383d7c4b06ef6eff959d
|
|
The pointer can't never be null, so avoid checking it.
Change-Id: I12e14641713a6494bc89570f02cecfc6f8fd4b5e
|
|
The underrun parameter in radioDevice's readSamples() is not a "Rx
Underrun" event, but rather it's used to retrieve a "Tx Underrun" which
on some SDRs (like USRP1) seems to be (so far) available only at
readSamples() times.
Thus, underrun parameter for both readSamples() and writeSamples() is
actually flagging the same event, and should be ORed in pushBuffer() as
it's already done in pullBuffer(). Otherwise if implementation is
setting the underrun pointer to false, it could erase the flag being
marked by the counterpart function before isUnderrun() is called (which
is the one responsible to clear the flag).
Change-Id: Id549489fc1485e0d762818c8e682aaddd5041f1c
|
|
TransceiverChannel naming was misleading there. It's simply a data type
used to pass 2 parameters through the void* of the thread entry
function, so let's clearly specify is a storage for thread params.
Furthermore, we don't need a full C++ class for that, let's simply use a
struct.
Change-Id: I6e3898a8a66520cc5b2a7df9b9ae01b0b272387f
|
|
The setting is negotiatied by osmo-bts-trx on each channel, so let's
keep and use state per channel instead of overwriting the state from
different channels.
Take the chance to change related log lines to also print the channel
number.
Change-Id: If9cf95e89d38d0155ab48b8c0977ca5f381c2aad
|
|
Before this commit, osmo-trx was always setting its CTRL socket to
listen on 127.0.0.1.
Change-Id: I61a06c1b9c20a906e7030f824a93370d041be7b9
|
|
Related: OS#3515
Change-Id: I3719bd8dc015569ecd81928fc079e27593cdca09
|
|
Change-Id: Ifafb68353960fc5046661854ccfb8d783b0efb14
|
|
Change-Id: I7264ef35dbe6d3522858eae5b47d150aa1ffe334
Closes: CID#169594
|
|
Change-Id: Ia72395f8805e9e2cd700ad1e559a8aa62124aaec
Closes: CID#149371
|
|
Change-Id: I8c047c8f98e928a62dca1d7b8c003502727c086e
Closes: CID#149374
|
|
The header version field is 4 bit long, so the mask 0x07 == 0b111
is wrong, it should actually be 0x0f == 0b1111.
Change-Id: I290931559ce01cf6e43470b18855c46808d6c2a5
|
|
Change-Id: I974c91be7cc119b44c2fb0c53d08009c87de7bf1
Related: CID#202038
|
|
Doing so should make Coverity happy:
>>> CID 200212: Uninitialized members (UNINIT_CTOR)
>>> Non-static class member "mExtRACH" is not initialized in this constructor nor in any functions that it calls.
The current status is actually harmless since the field will be set
during init() time, and the variable is never used before init() is
called.
Fixes: Coverity CID#200212
Change-Id: I17286570a9a6db695a75147e5cbb18c9da7d0fe6
|
|
Change-Id: If25c2171f7d1ab98d65f0dbf93d0d8a5a635caf7
|