hw/net: Replace type_register() with type_register_static()
authorZhao Liu <zhao1.liu@intel.com>
Tue, 29 Oct 2024 08:59:21 +0000 (16:59 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Tue, 10 Dec 2024 17:49:24 +0000 (18:49 +0100)
Replace type_register() with type_register_static() because
type_register() will be deprecated.

Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Link: https://lore.kernel.org/r/20241029085934.2799066-4-zhao1.liu@intel.com
hw/net/e1000.c
hw/net/eepro100.c

index 5012b964640d8e1780de72ff79131914d1c7f94d..ab72236d18318c8df363520e5d73dd2401452360 100644 (file)
@@ -1774,7 +1774,7 @@ static void e1000_register_types(void)
         type_info.class_data = (void *)info;
         type_info.class_init = e1000_class_init;
 
-        type_register(&type_info);
+        type_register_static(&type_info);
     }
 }
 
index c8a88b9813f0d20b017d5e40a5f7a1fdb091a8c0..20b22d8e49cb3e35409180e60dd8ae6d5b6ffceb 100644 (file)
@@ -2102,7 +2102,7 @@ static void eepro100_register_types(void)
             { },
         };
 
-        type_register(&type_info);
+        type_register_static(&type_info);
     }
 }