mirror of
https://github.com/apache/nuttx.git
synced 2025-05-07 22:01:55 +08:00
wireless/ieee802154: Replace direct access to semaphore value with nxsem_get_value
Use the defined interface to fetch the semaphore count in DEBUGASSERT Signed-off-by: Jukka Laitinen <jukka.laitinen@tii.ae>
This commit is contained in:
parent
de12b6ae82
commit
1658ee4abf
@ -2018,7 +2018,9 @@ static void mac802154_rxbeaconframe(FAR struct ieee802154_privmac_s *priv,
|
||||
}
|
||||
else if (priv->curr_op == MAC802154_OP_NONE)
|
||||
{
|
||||
DEBUGASSERT(priv->opsem.semcount == 1);
|
||||
int sval;
|
||||
DEBUGASSERT(nxsem_get_value(&priv->opsem, &sval) == 0
|
||||
&& sval == 1);
|
||||
nxsem_wait_uninterruptible(&priv->opsem);
|
||||
priv->curr_op = MAC802154_OP_AUTOEXTRACT;
|
||||
priv->curr_cmd = IEEE802154_CMD_DATA_REQ;
|
||||
|
Loading…
x
Reference in New Issue
Block a user