diff options
author | Bjoern A. Zeeb <bz@FreeBSD.org> | 2009-01-05 20:29:01 +0000 |
---|---|---|
committer | Bjoern A. Zeeb <bz@FreeBSD.org> | 2009-01-05 20:29:01 +0000 |
commit | 4b5c098fdf98bd15aeba2eec8e0f45340ac1dc7c (patch) | |
tree | c8cf8c207fc8f3d5554bda654200fb06dea2b084 /sys | |
parent | 065188a6300fb53e66c2f09af2d3974ef4067d77 (diff) |
Switch the last protosw* structs to C99 initializers.
Reviewed by: ed, julian, Christoph Mallon <christoph.mallon@gmx.de>
MFC after: 2 weeks
Notes
Notes:
svn path=/head/; revision=186791
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netinet6/in6_gif.c | 14 | ||||
-rw-r--r-- | sys/netipsec/xform_ipip.c | 28 |
2 files changed, 25 insertions, 17 deletions
diff --git a/sys/netinet6/in6_gif.c b/sys/netinet6/in6_gif.c index 3441f84bf281..3e17819598f6 100644 --- a/sys/netinet6/in6_gif.c +++ b/sys/netinet6/in6_gif.c @@ -75,11 +75,15 @@ static int gif_validate6(const struct ip6_hdr *, struct gif_softc *, struct ifnet *); extern struct domain inet6domain; -struct ip6protosw in6_gif_protosw = -{ SOCK_RAW, &inet6domain, 0/* IPPROTO_IPV[46] */, PR_ATOMIC|PR_ADDR, - in6_gif_input, rip6_output, 0, rip6_ctloutput, - 0, 0, 0, 0, - &rip6_usrreqs +struct ip6protosw in6_gif_protosw = { + .pr_type = SOCK_RAW, + .pr_domain = &inet6domain, + .pr_protocol = 0, /* IPPROTO_IPV[46] */ + .pr_flags = PR_ATOMIC|PR_ADDR, + .pr_input = in6_gif_input, + .pr_output = rip6_output, + .pr_ctloutput = rip6_ctloutput, + .pr_usrreqs = &rip6_usrreqs }; int diff --git a/sys/netipsec/xform_ipip.c b/sys/netipsec/xform_ipip.c index e7940e4d6c5c..7b8b92bb7340 100644 --- a/sys/netipsec/xform_ipip.c +++ b/sys/netipsec/xform_ipip.c @@ -660,20 +660,24 @@ static struct xformsw ipe4_xformsw = { }; extern struct domain inetdomain; -static struct protosw ipe4_protosw = -{ SOCK_RAW, &inetdomain, IPPROTO_IPV4, PR_ATOMIC|PR_ADDR|PR_LASTHDR, - ip4_input, - 0, 0, rip_ctloutput, - 0, 0, 0, 0, - &rip_usrreqs +static struct protosw ipe4_protosw = { + .pr_type = SOCK_RAW, + .pr_domain = &inetdomain, + .pr_protocol = IPPROTO_IPV4, + .pr_flags = PR_ATOMIC|PR_ADDR|PR_LASTHDR, + .pr_input = ip4_input, + .pr_ctloutput = rip_ctloutput, + .pr_usrreqs = &rip_usrreqs }; #ifdef INET6 -static struct ip6protosw ipe6_protosw = -{ SOCK_RAW, &inetdomain, IPPROTO_IPV6, PR_ATOMIC|PR_ADDR|PR_LASTHDR, - ip4_input6, - 0, 0, rip_ctloutput, - 0, 0, 0, 0, - &rip_usrreqs +static struct ip6protosw ipe6_protosw = { + .pr_type = SOCK_RAW, + .pr_domain = &inetdomain, + .pr_protocol = IPPROTO_IPV6, + .pr_flags = PR_ATOMIC|PR_ADDR|PR_LASTHDR, + .pr_input = ip4_input6, + .pr_ctloutput = rip_ctloutput, + .pr_usrreqs = &rip_usrreqs }; #endif |