-static void
-serialize_vnet_hw_interface_set_class (serialize_main_t * m, va_list * va)
-{
- u32 hw_if_index = va_arg (*va, u32);
- char *hw_class_name = va_arg (*va, char *);
- serialize_integer (m, hw_if_index, sizeof (hw_if_index));
- serialize_cstring (m, hw_class_name);
-}
-
-static void
-unserialize_vnet_hw_interface_set_class (serialize_main_t * m, va_list * va)
-{
- CLIB_UNUSED (mc_main_t * mc) = va_arg (*va, mc_main_t *);
- vnet_main_t *vnm = vnet_get_main ();
- u32 hw_if_index;
- char *hw_class_name;
- uword *p;
- clib_error_t *error;
-
- unserialize_integer (m, &hw_if_index, sizeof (hw_if_index));
- unserialize_cstring (m, &hw_class_name);
- p =
- hash_get (vnm->interface_main.hw_interface_class_by_name, hw_class_name);
- ASSERT (p != 0);
- error = vnet_hw_interface_set_class_helper (vnm, hw_if_index, p[0],
- /* redistribute */ 0);
- if (error)
- clib_error_report (error);
-}
-
-MC_SERIALIZE_MSG (vnet_hw_interface_set_class_msg, static) =
-{
-.name = "vnet_hw_interface_set_class",.serialize =
- serialize_vnet_hw_interface_set_class,.unserialize =
- unserialize_vnet_hw_interface_set_class,};
-