Skip to contentSkip to conversation

Categorize some uncategorized devices

PATCH Superseded Gan Qixin 1 participant 5 messages Nov 11, 2020

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore

Gan Qixin

author
#0 lore raw

cover Categorize some uncategorized devices

Hi all,

I categorize some uncategorized devices,could someone help me check it?

Thanks,
Gan Qixin

Gan Qixin (4):
ssd0323: put it into the 'dispaly' category
ads7846: put it into the 'dispaly' category
nand: put it into the 'storage' category
max111x: put it into the 'misc' category

 hw/block/nand.c      | 1 +
 hw/display/ads7846.c | 2 ++
 hw/display/ssd0323.c | 1 +
 hw/misc/max111x.c    | 1 +
 4 files changed, 5 insertions(+)
Signature · 1 line
2.23.0
author
#1 lore raw

PATCH 1/4 ssd0323: put it into the 'dispaly' category

The category of the ssd0323 device is not set, put it into the 'dispaly' category.

---
 hw/display/ssd0323.c | 1 +
 1 file changed, 1 insertion(+)
hw/display/ssd0323.c +1 -0
index 17d4b32ae3..cbfd21dfd5 100644
@@ -370,6 +370,7 @@ static void ssd0323_class_init(ObjectClass *klass, void *data)
     k->transfer = ssd0323_transfer;
     k->cs_polarity = SSI_CS_HIGH;
     dc->vmsd = &vmstate_ssd0323;
+    set_bit(DEVICE_CATEGORY_DISPLAY, dc->categories);
 }
 
 static const TypeInfo ssd0323_info = {
Signature · 1 line
2.23.0
author
#2 lore raw

PATCH 2/4 ads7846: put it into the 'dispaly' category

In reply to Gan Qixin

The category of the ads7846 device is not set, put it into the 'dispaly' category.

---
 hw/display/ads7846.c | 2 ++
 1 file changed, 2 insertions(+)
hw/display/ads7846.c +2 -0
index 023165b2a3..b455cb5acd 100644
@@ -163,10 +163,12 @@ static void ads7846_realize(SSISlave *d, Error **errp)
 
 static void ads7846_class_init(ObjectClass *klass, void *data)
 {
+    DeviceClass *dc = DEVICE_CLASS(klass);
     SSISlaveClass *k = SSI_SLAVE_CLASS(klass);
 
     k->realize = ads7846_realize;
     k->transfer = ads7846_transfer;
+    set_bit(DEVICE_CATEGORY_DISPLAY, dc->categories);
 }
 
 static const TypeInfo ads7846_info = {
Signature · 1 line
2.23.0
author
#3 lore raw

PATCH 3/4 nand: put it into the 'storage' category

In reply to Gan Qixin

The category of the nand device is not set, put it into the 'storage' category.

---
 hw/block/nand.c | 1 +
 1 file changed, 1 insertion(+)
hw/block/nand.c +1 -0
index bcceb64ebb..1d7a48a2ec 100644
@@ -449,6 +449,7 @@ static void nand_class_init(ObjectClass *klass, void *data)
     dc->reset = nand_reset;
     dc->vmsd = &vmstate_nand;
     device_class_set_props(dc, nand_properties);
+    set_bit(DEVICE_CATEGORY_STORAGE, dc->categories);
 }
 
 static const TypeInfo nand_info = {
Signature · 1 line
2.23.0
author
#4 lore raw

PATCH 4/4 max111x: put it into the 'misc' category

In reply to Gan Qixin

The category of the max111x device is not set, put it into the 'misc' category.

---
 hw/misc/max111x.c | 1 +
 1 file changed, 1 insertion(+)
hw/misc/max111x.c +1 -0
index 7e6723f343..eae0f9b598 100644
@@ -185,6 +185,7 @@ static void max111x_class_init(ObjectClass *klass, void *data)
     k->transfer = max111x_transfer;
     dc->reset = max111x_reset;
     dc->vmsd = &vmstate_max111x;
+    set_bit(DEVICE_CATEGORY_MISC, dc->categories);
 }
 
 static const TypeInfo max111x_info = {
Signature · 1 line
2.23.0