struct usb_interface *pusbintf;
struct usb_device *pusbdev;
- ATOMIC_T continual_urb_error;
+ atomic_t continual_urb_error;
};
static inline struct device *dvobj_to_dev(struct dvobj_priv *dvobj)
#define PATH_LENGTH_MAX PATH_MAX
/* Atomic integer operations */
-#define ATOMIC_T atomic_t
-
-void ATOMIC_SET(ATOMIC_T *v, int i);
-int ATOMIC_READ(ATOMIC_T *v);
-void ATOMIC_ADD(ATOMIC_T *v, int i);
-void ATOMIC_SUB(ATOMIC_T *v, int i);
-void ATOMIC_INC(ATOMIC_T *v);
-void ATOMIC_DEC(ATOMIC_T *v);
-int ATOMIC_ADD_RETURN(ATOMIC_T *v, int i);
-int ATOMIC_SUB_RETURN(ATOMIC_T *v, int i);
-int ATOMIC_INC_RETURN(ATOMIC_T *v);
-int ATOMIC_DEC_RETURN(ATOMIC_T *v);
+void ATOMIC_SET(atomic_t *v, int i);
+int ATOMIC_READ(atomic_t *v);
+void ATOMIC_ADD(atomic_t *v, int i);
+void ATOMIC_SUB(atomic_t *v, int i);
+void ATOMIC_INC(atomic_t *v);
+void ATOMIC_DEC(atomic_t *v);
+int ATOMIC_ADD_RETURN(atomic_t *v, int i);
+int ATOMIC_SUB_RETURN(atomic_t *v, int i);
+int ATOMIC_INC_RETURN(atomic_t *v);
+int ATOMIC_DEC_RETURN(atomic_t *v);
struct rtw_netdev_priv_indicator {
void *priv;
bool c2h_wk_alive;
struct rtw_cbuf *c2h_queue;
#define C2H_QUEUE_MAX_LEN 10
- ATOMIC_T event_seq;
+ atomic_t event_seq;
u8 *evt_buf; /* shall be non-paged, and 4 bytes aligned */
u8 *evt_allocated_buf;
u32 evt_done_cnt;
struct mlme_ext_priv {
struct adapter *padapter;
u8 mlmeext_init;
- ATOMIC_T event_seq;
+ atomic_t event_seq;
u16 mgnt_seq;
unsigned char cur_channel;
#define RTW_SUSPEND_LOCK_NAME "rtw_wifi"
-inline void ATOMIC_SET(ATOMIC_T *v, int i)
+inline void ATOMIC_SET(atomic_t *v, int i)
{
atomic_set(v, i);
}
-inline int ATOMIC_READ(ATOMIC_T *v)
+inline int ATOMIC_READ(atomic_t *v)
{
return atomic_read(v);
}
-inline void ATOMIC_ADD(ATOMIC_T *v, int i)
+inline void ATOMIC_ADD(atomic_t *v, int i)
{
atomic_add(i, v);
}
-inline void ATOMIC_SUB(ATOMIC_T *v, int i)
+inline void ATOMIC_SUB(atomic_t *v, int i)
{
atomic_sub(i, v);
}
-inline void ATOMIC_INC(ATOMIC_T *v)
+inline void ATOMIC_INC(atomic_t *v)
{
atomic_inc(v);
}
-inline void ATOMIC_DEC(ATOMIC_T *v)
+inline void ATOMIC_DEC(atomic_t *v)
{
atomic_dec(v);
}
-inline int ATOMIC_ADD_RETURN(ATOMIC_T *v, int i)
+inline int ATOMIC_ADD_RETURN(atomic_t *v, int i)
{
return atomic_add_return(i, v);
}
-inline int ATOMIC_SUB_RETURN(ATOMIC_T *v, int i)
+inline int ATOMIC_SUB_RETURN(atomic_t *v, int i)
{
return atomic_sub_return(i, v);
}
-inline int ATOMIC_INC_RETURN(ATOMIC_T *v)
+inline int ATOMIC_INC_RETURN(atomic_t *v)
{
return atomic_inc_return(v);
}
-inline int ATOMIC_DEC_RETURN(ATOMIC_T *v)
+inline int ATOMIC_DEC_RETURN(atomic_t *v)
{
return atomic_dec_return(v);
}