diff options
Diffstat (limited to 'src/vnet/unix')
-rw-r--r-- | src/vnet/unix/tuntap.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/vnet/unix/tuntap.c b/src/vnet/unix/tuntap.c index 103b6496a34..9d6f8992414 100644 --- a/src/vnet/unix/tuntap.c +++ b/src/vnet/unix/tuntap.c @@ -1011,7 +1011,6 @@ VNET_DEVICE_CLASS (tuntap_dev_class,static) = { static clib_error_t * tuntap_init (vlib_main_t * vm) { - clib_error_t *error; ip4_main_t *im4 = &ip4_main; ip6_main_t *im6 = &ip6_main; ip4_add_del_interface_address_callback_t cb4; @@ -1019,10 +1018,6 @@ tuntap_init (vlib_main_t * vm) tuntap_main_t *tm = &tuntap_main; vlib_thread_main_t *m = vlib_get_thread_main (); - error = vlib_call_init_function (vm, ip4_init); - if (error) - return error; - mhash_init (&tm->subif_mhash, sizeof (u32), sizeof (subif_address_t)); cb4.function = tuntap_ip4_add_del_interface_address; @@ -1038,7 +1033,12 @@ tuntap_init (vlib_main_t * vm) return 0; } -VLIB_INIT_FUNCTION (tuntap_init); +/* *INDENT-OFF* */ +VLIB_INIT_FUNCTION (tuntap_init) = +{ + .runs_after = VLIB_INITS("ip4_init"), +}; +/* *INDENT-ON* */ /* * fd.io coding-style-patch-verification: ON |