staging: r8188eu: Replace ATOMIC_T with atomic_t
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
2bf9820beb
commit
6fe58d6855
|
@ -191,7 +191,7 @@ struct dvobj_priv {
|
||||||
struct usb_interface *pusbintf;
|
struct usb_interface *pusbintf;
|
||||||
struct usb_device *pusbdev;
|
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)
|
static inline struct device *dvobj_to_dev(struct dvobj_priv *dvobj)
|
||||||
|
|
|
@ -358,18 +358,16 @@ static inline u32 bitshift(u32 bitmask)
|
||||||
#define PATH_LENGTH_MAX PATH_MAX
|
#define PATH_LENGTH_MAX PATH_MAX
|
||||||
|
|
||||||
/* Atomic integer operations */
|
/* Atomic integer operations */
|
||||||
#define ATOMIC_T atomic_t
|
void ATOMIC_SET(atomic_t *v, int i);
|
||||||
|
int ATOMIC_READ(atomic_t *v);
|
||||||
void ATOMIC_SET(ATOMIC_T *v, int i);
|
void ATOMIC_ADD(atomic_t *v, int i);
|
||||||
int ATOMIC_READ(ATOMIC_T *v);
|
void ATOMIC_SUB(atomic_t *v, int i);
|
||||||
void ATOMIC_ADD(ATOMIC_T *v, int i);
|
void ATOMIC_INC(atomic_t *v);
|
||||||
void ATOMIC_SUB(ATOMIC_T *v, int i);
|
void ATOMIC_DEC(atomic_t *v);
|
||||||
void ATOMIC_INC(ATOMIC_T *v);
|
int ATOMIC_ADD_RETURN(atomic_t *v, int i);
|
||||||
void ATOMIC_DEC(ATOMIC_T *v);
|
int ATOMIC_SUB_RETURN(atomic_t *v, int i);
|
||||||
int ATOMIC_ADD_RETURN(ATOMIC_T *v, int i);
|
int ATOMIC_INC_RETURN(atomic_t *v);
|
||||||
int ATOMIC_SUB_RETURN(ATOMIC_T *v, int i);
|
int ATOMIC_DEC_RETURN(atomic_t *v);
|
||||||
int ATOMIC_INC_RETURN(ATOMIC_T *v);
|
|
||||||
int ATOMIC_DEC_RETURN(ATOMIC_T *v);
|
|
||||||
|
|
||||||
struct rtw_netdev_priv_indicator {
|
struct rtw_netdev_priv_indicator {
|
||||||
void *priv;
|
void *priv;
|
||||||
|
|
|
@ -69,7 +69,7 @@ struct evt_priv {
|
||||||
bool c2h_wk_alive;
|
bool c2h_wk_alive;
|
||||||
struct rtw_cbuf *c2h_queue;
|
struct rtw_cbuf *c2h_queue;
|
||||||
#define C2H_QUEUE_MAX_LEN 10
|
#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_buf; /* shall be non-paged, and 4 bytes aligned */
|
||||||
u8 *evt_allocated_buf;
|
u8 *evt_allocated_buf;
|
||||||
u32 evt_done_cnt;
|
u32 evt_done_cnt;
|
||||||
|
|
|
@ -401,7 +401,7 @@ struct p2p_oper_class_map {
|
||||||
struct mlme_ext_priv {
|
struct mlme_ext_priv {
|
||||||
struct adapter *padapter;
|
struct adapter *padapter;
|
||||||
u8 mlmeext_init;
|
u8 mlmeext_init;
|
||||||
ATOMIC_T event_seq;
|
atomic_t event_seq;
|
||||||
u16 mgnt_seq;
|
u16 mgnt_seq;
|
||||||
|
|
||||||
unsigned char cur_channel;
|
unsigned char cur_channel;
|
||||||
|
|
|
@ -247,52 +247,52 @@ void rtw_sleep_schedulable(int ms)
|
||||||
|
|
||||||
#define RTW_SUSPEND_LOCK_NAME "rtw_wifi"
|
#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);
|
atomic_set(v, i);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int ATOMIC_READ(ATOMIC_T *v)
|
inline int ATOMIC_READ(atomic_t *v)
|
||||||
{
|
{
|
||||||
return atomic_read(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);
|
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);
|
atomic_sub(i, v);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void ATOMIC_INC(ATOMIC_T *v)
|
inline void ATOMIC_INC(atomic_t *v)
|
||||||
{
|
{
|
||||||
atomic_inc(v);
|
atomic_inc(v);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void ATOMIC_DEC(ATOMIC_T *v)
|
inline void ATOMIC_DEC(atomic_t *v)
|
||||||
{
|
{
|
||||||
atomic_dec(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);
|
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);
|
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);
|
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);
|
return atomic_dec_return(v);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue