mirror of
https://github.com/Mange/rtl8192eu-linux-driver
synced 2025-12-10 00:04:17 +00:00
Remove wrappers for atomic operations
These wrappers were useful when this driver had the hooks for Windows, but are no longer needed. Link: https://lore.kernel.org/r/20210802192721.23110-4-Larry.Finger@lwfinger.net
This commit is contained in:
committed by
Carlos Garcés
parent
e8b235e056
commit
d7c3737cd5
@@ -42,12 +42,12 @@ void rm_timer_callback(void *data)
|
||||
for (i=0;i<RM_TIMER_NUM;i++) {
|
||||
pclock = &prmpriv->clock[i];
|
||||
if (pclock->prm == NULL
|
||||
||(ATOMIC_READ(&(pclock->counter)) == 0))
|
||||
||(atomic_read(&(pclock->counter)) == 0))
|
||||
continue;
|
||||
|
||||
ATOMIC_DEC(&(pclock->counter));
|
||||
atomic_dec(&(pclock->counter));
|
||||
|
||||
if (ATOMIC_READ(&(pclock->counter)) == 0)
|
||||
if (atomic_read(&(pclock->counter)) == 0)
|
||||
rm_post_event(pclock->prm->psta->padapter,
|
||||
pclock->prm->rmid, prmpriv->clock[i].evid);
|
||||
}
|
||||
@@ -176,7 +176,7 @@ static int rm_enqueue_ev(_queue *queue, struct rm_event *obj, bool to_head)
|
||||
|
||||
static void rm_set_clock(struct rm_obj *prm, u32 ms, enum RM_EV_ID evid)
|
||||
{
|
||||
ATOMIC_SET(&(prm->pclock->counter), (ms/CLOCK_UNIT));
|
||||
atomic_set(&(prm->pclock->counter), (ms/CLOCK_UNIT));
|
||||
prm->pclock->evid = evid;
|
||||
}
|
||||
|
||||
@@ -192,7 +192,7 @@ static struct rm_clock *rm_alloc_clock(_adapter *padapter, struct rm_obj *prm)
|
||||
|
||||
if (pclock->prm == NULL) {
|
||||
pclock->prm = prm;
|
||||
ATOMIC_SET(&(pclock->counter), 0);
|
||||
atomic_set(&(pclock->counter), 0);
|
||||
pclock->evid = RM_EV_max;
|
||||
break;
|
||||
}
|
||||
@@ -202,14 +202,14 @@ static struct rm_clock *rm_alloc_clock(_adapter *padapter, struct rm_obj *prm)
|
||||
|
||||
static void rm_cancel_clock(struct rm_obj *prm)
|
||||
{
|
||||
ATOMIC_SET(&(prm->pclock->counter), 0);
|
||||
atomic_set(&(prm->pclock->counter), 0);
|
||||
prm->pclock->evid = RM_EV_max;
|
||||
}
|
||||
|
||||
static void rm_free_clock(struct rm_clock *pclock)
|
||||
{
|
||||
pclock->prm = NULL;
|
||||
ATOMIC_SET(&(pclock->counter), 0);
|
||||
atomic_set(&(pclock->counter), 0);
|
||||
pclock->evid = RM_EV_max;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user