/* Signal reader that data is available. */
- wake_up_interruptible(cf_sk->sk.sk_sleep);
+ wake_up_interruptible(sk_sleep(&cf_sk->sk));
return 0;
}
dbfs_atomic_inc(&cnt.num_tx_flow_on_ind);
/* Signal reader that data is available. */
SET_TX_FLOW_ON(cf_sk);
- wake_up_interruptible(cf_sk->sk.sk_sleep);
+ wake_up_interruptible(sk_sleep(&cf_sk->sk));
break;
case CAIF_CTRLCMD_FLOW_OFF_IND:
caif_assert(STATE_IS_OPEN(cf_sk));
SET_PENDING_OFF(cf_sk);
SET_TX_FLOW_ON(cf_sk);
- wake_up_interruptible(cf_sk->sk.sk_sleep);
+ wake_up_interruptible(sk_sleep(&cf_sk->sk));
break;
case CAIF_CTRLCMD_DEINIT_RSP:
caif_assert(!STATE_IS_OPEN(cf_sk));
SET_PENDING_OFF(cf_sk);
if (!STATE_IS_PENDING_DESTROY(cf_sk)) {
- if (cf_sk->sk.sk_sleep != NULL)
- wake_up_interruptible(cf_sk->sk.sk_sleep);
+ if (sk_sleep(&cf_sk->sk) != NULL)
+ wake_up_interruptible(sk_sleep(&cf_sk->sk));
}
dbfs_atomic_inc(&cnt.num_deinit);
sock_put(&cf_sk->sk);
SET_STATE_CLOSED(cf_sk);
SET_PENDING_OFF(cf_sk);
SET_TX_FLOW_OFF(cf_sk);
- wake_up_interruptible(cf_sk->sk.sk_sleep);
+ wake_up_interruptible(sk_sleep(&cf_sk->sk));
break;
case CAIF_CTRLCMD_REMOTE_SHUTDOWN_IND:
/* Use sk_shutdown to indicate remote shutdown indication */
cf_sk->sk.sk_shutdown |= RCV_SHUTDOWN;
cf_sk->file_mode = 0;
- wake_up_interruptible(cf_sk->sk.sk_sleep);
+ wake_up_interruptible(sk_sleep(&cf_sk->sk));
break;
default:
release_sock(&cf_sk->sk);
result =
- wait_event_interruptible(*cf_sk->sk.sk_sleep,
+ wait_event_interruptible(*sk_sleep(&cf_sk->sk),
!STATE_IS_PENDING(cf_sk));
lock_sock(&(cf_sk->sk));
release_sock(&cf_sk->sk);
/* Block reader until data arrives or socket is closed. */
- if (wait_event_interruptible(*cf_sk->sk.sk_sleep,
+ if (wait_event_interruptible(*sk_sleep(&cf_sk->sk),
cfpkt_qpeek(cf_sk->pktq)
|| STATE_IS_REMOTE_SHUTDOWN(cf_sk)
|| !STATE_IS_OPEN(cf_sk)) ==
* for its conclusion.
*/
result =
- wait_event_interruptible(*cf_sk->sk.sk_sleep,
+ wait_event_interruptible(*sk_sleep(&cf_sk->sk),
!STATE_IS_PENDING(cf_sk));
/* I want to be alone on cf_sk (except status and queue) */
lock_sock(&(cf_sk->sk));
release_sock(&cf_sk->sk);
/* Wait until flow is on or socket is closed */
- if (wait_event_interruptible(*cf_sk->sk.sk_sleep,
+ if (wait_event_interruptible(*sk_sleep(&cf_sk->sk),
TX_FLOW_IS_ON(cf_sk)
|| !STATE_IS_OPEN(cf_sk)
|| STATE_IS_REMOTE_SHUTDOWN(cf_sk)
release_sock(&cf_sk->sk);
/* Wait until flow is on or socket is closed */
- if (wait_event_interruptible(*cf_sk->sk.sk_sleep,
+ if (wait_event_interruptible(*sk_sleep(&cf_sk->sk),
TX_FLOW_IS_ON(cf_sk)
|| !STATE_IS_OPEN(cf_sk)
|| STATE_IS_REMOTE_SHUTDOWN(cf_sk)
* for its conclusion.
*/
result =
- wait_event_interruptible(*cf_sk->sk.sk_sleep,
+ wait_event_interruptible(*sk_sleep(&cf_sk->sk),
!STATE_IS_PENDING(cf_sk));
lock_sock(&(cf_sk->sk));
release_sock(&cf_sk->sk);
result =
- wait_event_interruptible(*cf_sk->sk.sk_sleep,
+ wait_event_interruptible(*sk_sleep(&cf_sk->sk),
!STATE_IS_PENDING(cf_sk));
lock_sock(&(cf_sk->sk));
* CAIF stack.
*/
if (!(sock->file->f_flags & O_NONBLOCK)) {
- res = wait_event_interruptible(*cf_sk->sk.sk_sleep,
+ res = wait_event_interruptible(*sk_sleep(&cf_sk->sk),
!STATE_IS_PENDING(cf_sk));
if (res == -ERESTARTSYS) {
/* wait for a message to turn up */
release_sock(&rx->sk);
- prepare_to_wait_exclusive(rx->sk.sk_sleep, &wait,
+ prepare_to_wait_exclusive(sk_sleep(&rx->sk), &wait,
TASK_INTERRUPTIBLE);
ret = sock_error(&rx->sk);
if (ret)
goto wait_interrupted;
timeo = schedule_timeout(timeo);
}
- finish_wait(rx->sk.sk_sleep, &wait);
+ finish_wait(sk_sleep(&rx->sk), &wait);
lock_sock(&rx->sk);
continue;
}
wait_interrupted:
ret = sock_intr_errno(timeo);
wait_error:
- finish_wait(rx->sk.sk_sleep, &wait);
+ finish_wait(sk_sleep(&rx->sk), &wait);
if (continue_call)
rxrpc_put_call(continue_call);
if (copied)