Skip to contentSkip to conversation

hw/display/macfb: Classify the "nubus-macfb" as display device

PATCH Applied Thomas Huth 3 participants 4 messages May 31, 2021 – Jun 5, 2021

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 hw/display/macfb: Classify the "nubus-macfb" as display device

The "nubus-macfb" currently shows up as uncategorized device in the output of "-device help". Put it into the display category to fix this ugliness.

---
 hw/display/macfb.c | 1 +
 1 file changed, 1 insertion(+)
hw/display/macfb.c +1 -0
index ff8bdb846b..d8183b9bbd 100644
@@ -450,6 +450,7 @@ static void macfb_nubus_class_init(ObjectClass *klass, void *data)
     dc->desc = "Nubus Macintosh framebuffer";
     dc->reset = macfb_nubus_reset;
     dc->vmsd = &vmstate_macfb;
+    set_bit(DEVICE_CATEGORY_DISPLAY, dc->categories);
     device_class_set_props(dc, macfb_nubus_properties);
 }
 
Signature · 1 line
2.27.0
Reviewed-by on v1 1/1
#1 lore raw

Le 31/05/2021 à 09:32, Thomas Huth a écrit :

Quoted 15 lines

The "nubus-macfb" currently shows up as uncategorized device in the output of "-device help". Put it into the display category to fix this ugliness.

---
 hw/display/macfb.c | 1 +
 1 file changed, 1 insertion(+)
hw/display/macfb.c +0 -0
index ff8bdb846b..d8183b9bbd 100644

hw/display/macfb.c static void macfb_nubus_class_init(ObjectClass *klass, void *data) · line 456

Quoted 7 lines
hw/display/macfb.c +1 -0
@@ -450,6 +450,7 @@ static void macfb_nubus_class_init(ObjectClass *klass, void *data)
     dc->desc = "Nubus Macintosh framebuffer";
     dc->reset = macfb_nubus_reset;
     dc->vmsd = &vmstate_macfb;
+    set_bit(DEVICE_CATEGORY_DISPLAY, dc->categories);
     device_class_set_props(dc, macfb_nubus_properties);
 }
 
#3 lore raw
In reply to Thomas Huth

Le 31/05/2021 à 09:32, Thomas Huth a écrit :

Quoted 15 lines

The "nubus-macfb" currently shows up as uncategorized device in the output of "-device help". Put it into the display category to fix this ugliness.

---
 hw/display/macfb.c | 1 +
 1 file changed, 1 insertion(+)
hw/display/macfb.c +0 -0
index ff8bdb846b..d8183b9bbd 100644

hw/display/macfb.c static void macfb_nubus_class_init(ObjectClass *klass, void *data) · line 456

Quoted 7 lines
hw/display/macfb.c +1 -0
@@ -450,6 +450,7 @@ static void macfb_nubus_class_init(ObjectClass *klass, void *data)
     dc->desc = "Nubus Macintosh framebuffer";
     dc->reset = macfb_nubus_reset;
     dc->vmsd = &vmstate_macfb;
+    set_bit(DEVICE_CATEGORY_DISPLAY, dc->categories);
     device_class_set_props(dc, macfb_nubus_properties);
 }
 

Applied to my trivial-patches branch.

Thanks,
Laurent