summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorXin Long <lucien.xin@gmail.com>2017-08-11 10:23:51 +0800
committerDavid S. Miller <davem@davemloft.net>2017-08-11 10:02:44 -0700
commite2c3108ab25b4dbab3821e8b6084bfb73afb655c (patch)
tree190beef860c49bec18b10abe1cc54a673a6c9f1c /include
parentb7ef2618a0bf75c1e480b05739b0c5f2a42081cd (diff)
downloadlinux-e2c3108ab25b4dbab3821e8b6084bfb73afb655c.tar.bz2
sctp: remove the typedef sctp_cmd_t
This patch is to remove the typedef sctp_cmd_t, and replace with enum sctp_cmd in the places where it's using this typedef. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r--include/net/sctp/command.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/include/net/sctp/command.h b/include/net/sctp/command.h
index 376cb78b6247..4e9e589b8f18 100644
--- a/include/net/sctp/command.h
+++ b/include/net/sctp/command.h
@@ -196,15 +196,15 @@ static inline sctp_arg_t SCTP_NULL(void)
return retval;
}
-typedef struct {
+struct sctp_cmd {
sctp_arg_t obj;
sctp_verb_t verb;
-} sctp_cmd_t;
+};
typedef struct {
- sctp_cmd_t cmds[SCTP_MAX_NUM_COMMANDS];
- sctp_cmd_t *last_used_slot;
- sctp_cmd_t *next_cmd;
+ struct sctp_cmd cmds[SCTP_MAX_NUM_COMMANDS];
+ struct sctp_cmd *last_used_slot;
+ struct sctp_cmd *next_cmd;
} sctp_cmd_seq_t;
@@ -228,7 +228,7 @@ static inline int sctp_init_cmd_seq(sctp_cmd_seq_t *seq)
static inline void sctp_add_cmd_sf(sctp_cmd_seq_t *seq, sctp_verb_t verb,
sctp_arg_t obj)
{
- sctp_cmd_t *cmd = seq->last_used_slot - 1;
+ struct sctp_cmd *cmd = seq->last_used_slot - 1;
BUG_ON(cmd < seq->cmds);
@@ -240,7 +240,7 @@ static inline void sctp_add_cmd_sf(sctp_cmd_seq_t *seq, sctp_verb_t verb,
/* Return the next command structure in an sctp_cmd_seq.
* Return NULL at the end of the sequence.
*/
-static inline sctp_cmd_t *sctp_next_cmd(sctp_cmd_seq_t *seq)
+static inline struct sctp_cmd *sctp_next_cmd(sctp_cmd_seq_t *seq)
{
if (seq->next_cmd <= seq->last_used_slot)
return NULL;