diff mbox

[RFC,v2,13/20,trivial] edu: Move edu_info outside function

Message ID 1480111556-32586-14-git-send-email-ehabkost@redhat.com
State New
Headers show

Commit Message

Eduardo Habkost Nov. 25, 2016, 10:05 p.m. UTC
Follow the same style as other classes. Declaring the struct
inside the function doesn't allow us to use the same type of
declaration to set the interfaces array.

Cc: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
Changes series v1 -> v2:
* (new patch added to series)
---
 hw/misc/edu.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)
diff mbox

Patch

diff --git a/hw/misc/edu.c b/hw/misc/edu.c
index 401039c..529721a 100644
--- a/hw/misc/edu.c
+++ b/hw/misc/edu.c
@@ -406,16 +406,16 @@  static void edu_class_init(ObjectClass *class, void *data)
     k->class_id = PCI_CLASS_OTHERS;
 }
 
+static const TypeInfo edu_info = {
+    .name          = "edu",
+    .parent        = TYPE_PCI_DEVICE,
+    .instance_size = sizeof(EduState),
+    .instance_init = edu_instance_init,
+    .class_init    = edu_class_init,
+};
+
 static void pci_edu_register_types(void)
 {
-    static const TypeInfo edu_info = {
-        .name          = "edu",
-        .parent        = TYPE_PCI_DEVICE,
-        .instance_size = sizeof(EduState),
-        .instance_init = edu_instance_init,
-        .class_init    = edu_class_init,
-    };
-
     type_register_static(&edu_info);
 }
 type_init(pci_edu_register_types)