aboutsummaryrefslogtreecommitdiffstats
path: root/net/sctp/sm_statefuns.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2006-11-20 20:00:44 -0500
committerDavid S. Miller <davem@sunset.davemloft.net>2006-12-03 00:26:20 -0500
commitdc251b2b1c4bfea51903cb9fbc141a5b33f6aca7 (patch)
tree6eee6336f8613abb5bce93d882ec2e73d15881b0 /net/sctp/sm_statefuns.c
parentf94c0198dd98c2ca66a7a44e9ad310a3eb21ad31 (diff)
[SCTP]: SCTP_CMD_INIT_FAILED annotations.
argument stored for SCTP_CMD_INIT_FAILED is always __be16 (protocol error). Introduced new field and accessor for it (SCTP_PERR()); switched to their use (from SCTP_U32() and .u32) Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sctp/sm_statefuns.c')
-rw-r--r--net/sctp/sm_statefuns.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/net/sctp/sm_statefuns.c b/net/sctp/sm_statefuns.c
index b9063ed2a659..f462a227c7ae 100644
--- a/net/sctp/sm_statefuns.c
+++ b/net/sctp/sm_statefuns.c
@@ -2138,7 +2138,7 @@ static sctp_disposition_t sctp_sf_do_5_2_6_stale(const struct sctp_endpoint *ep,
2138 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR, 2138 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR,
2139 SCTP_ERROR(ETIMEDOUT)); 2139 SCTP_ERROR(ETIMEDOUT));
2140 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED, 2140 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED,
2141 SCTP_U32(SCTP_ERROR_STALE_COOKIE)); 2141 SCTP_PERR(SCTP_ERROR_STALE_COOKIE));
2142 return SCTP_DISPOSITION_DELETE_TCB; 2142 return SCTP_DISPOSITION_DELETE_TCB;
2143 } 2143 }
2144 2144
@@ -2370,7 +2370,7 @@ static sctp_disposition_t sctp_stop_t1_and_abort(sctp_cmd_seq_t *commands,
2370 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR, SCTP_ERROR(sk_err)); 2370 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR, SCTP_ERROR(sk_err));
2371 /* CMD_INIT_FAILED will DELETE_TCB. */ 2371 /* CMD_INIT_FAILED will DELETE_TCB. */
2372 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED, 2372 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED,
2373 SCTP_U32(error)); 2373 SCTP_PERR(error));
2374 return SCTP_DISPOSITION_ABORT; 2374 return SCTP_DISPOSITION_ABORT;
2375} 2375}
2376 2376
@@ -3743,7 +3743,7 @@ static sctp_disposition_t sctp_sf_violation_chunklen(
3743 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR, 3743 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR,
3744 SCTP_ERROR(ECONNREFUSED)); 3744 SCTP_ERROR(ECONNREFUSED));
3745 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED, 3745 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED,
3746 SCTP_U32(SCTP_ERROR_PROTO_VIOLATION)); 3746 SCTP_PERR(SCTP_ERROR_PROTO_VIOLATION));
3747 } else { 3747 } else {
3748 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR, 3748 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR,
3749 SCTP_ERROR(ECONNABORTED)); 3749 SCTP_ERROR(ECONNABORTED));
@@ -4199,7 +4199,7 @@ sctp_disposition_t sctp_sf_cookie_wait_prm_abort(
4199 SCTP_ERROR(ECONNREFUSED)); 4199 SCTP_ERROR(ECONNREFUSED));
4200 /* Delete the established association. */ 4200 /* Delete the established association. */
4201 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED, 4201 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED,
4202 SCTP_U32(SCTP_ERROR_USER_ABORT)); 4202 SCTP_PERR(SCTP_ERROR_USER_ABORT));
4203 4203
4204 return retval; 4204 return retval;
4205} 4205}
@@ -4693,7 +4693,7 @@ sctp_disposition_t sctp_sf_t1_init_timer_expire(const struct sctp_endpoint *ep,
4693 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR, 4693 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR,
4694 SCTP_ERROR(ETIMEDOUT)); 4694 SCTP_ERROR(ETIMEDOUT));
4695 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED, 4695 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED,
4696 SCTP_U32(SCTP_ERROR_NO_ERROR)); 4696 SCTP_PERR(SCTP_ERROR_NO_ERROR));
4697 return SCTP_DISPOSITION_DELETE_TCB; 4697 return SCTP_DISPOSITION_DELETE_TCB;
4698 } 4698 }
4699 4699
@@ -4745,7 +4745,7 @@ sctp_disposition_t sctp_sf_t1_cookie_timer_expire(const struct sctp_endpoint *ep
4745 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR, 4745 sctp_add_cmd_sf(commands, SCTP_CMD_SET_SK_ERR,
4746 SCTP_ERROR(ETIMEDOUT)); 4746 SCTP_ERROR(ETIMEDOUT));
4747 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED, 4747 sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED,
4748 SCTP_U32(SCTP_ERROR_NO_ERROR)); 4748 SCTP_PERR(SCTP_ERROR_NO_ERROR));
4749 return SCTP_DISPOSITION_DELETE_TCB; 4749 return SCTP_DISPOSITION_DELETE_TCB;
4750 } 4750 }
4751 4751