summaryrefslogtreecommitdiffstats
path: root/sys/net/if_gre.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/net/if_gre.c')
-rw-r--r--sys/net/if_gre.c32
1 files changed, 20 insertions, 12 deletions
diff --git a/sys/net/if_gre.c b/sys/net/if_gre.c
index 22ceba5..f8165dc 100644
--- a/sys/net/if_gre.c
+++ b/sys/net/if_gre.c
@@ -118,19 +118,27 @@ static void greattach(void);
#ifdef INET
extern struct domain inetdomain;
-static const struct protosw in_gre_protosw =
-{ SOCK_RAW, &inetdomain, IPPROTO_GRE, PR_ATOMIC|PR_ADDR,
- (pr_input_t*)gre_input, (pr_output_t*)rip_output, rip_ctlinput, rip_ctloutput,
- 0,
- 0, 0, 0, 0,
- &rip_usrreqs
+static const struct protosw in_gre_protosw = {
+ .pr_type = SOCK_RAW,
+ .pr_domain = &inetdomain,
+ .pr_protocol = IPPROTO_GRE,
+ .pr_flags = PR_ATOMIC|PR_ADDR,
+ .pr_input = (pr_input_t *)gre_input,
+ .pr_output = (pr_output_t *)rip_output,
+ .pr_ctlinput = rip_ctlinput,
+ .pr_ctloutput = rip_ctloutput,
+ .pr_usrreqs = &rip_usrreqs
};
-static const struct protosw in_mobile_protosw =
-{ SOCK_RAW, &inetdomain, IPPROTO_MOBILE, PR_ATOMIC|PR_ADDR,
- (pr_input_t*)gre_mobile_input, (pr_output_t*)rip_output, rip_ctlinput, rip_ctloutput,
- 0,
- 0, 0, 0, 0,
- &rip_usrreqs
+static const struct protosw in_mobile_protosw = {
+ .pr_type = SOCK_RAW,
+ .pr_domain = &inetdomain,
+ .pr_protocol = IPPROTO_MOBILE,
+ .pr_flags = PR_ATOMIC|PR_ADDR,
+ .pr_input = (pr_input_t *)gre_mobile_input,
+ .pr_output = (pr_output_t *)rip_output,
+ .pr_ctlinput = rip_ctlinput,
+ .pr_ctloutput = rip_ctloutput,
+ .pr_usrreqs = &rip_usrreqs
};
#endif
OpenPOWER on IntegriCloud