[PATCH for-6.2 v2] s390-sclp-events-bus: Use OBJECT_DECLARE_SIMPLE_TYPE

Eduardo Habkost posted 1 patch 2 years, 9 months ago
Test checkpatch passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20210806024636.446074-1-ehabkost@redhat.com
Maintainers: Christian Borntraeger <borntraeger@de.ibm.com>, Richard Henderson <richard.henderson@linaro.org>, Halil Pasic <pasic@linux.ibm.com>, Cornelia Huck <cohuck@redhat.com>, David Hildenbrand <david@redhat.com>, Thomas Huth <thuth@redhat.com>
hw/s390x/event-facility.c | 1 +
1 file changed, 1 insertion(+)
[PATCH for-6.2 v2] s390-sclp-events-bus: Use OBJECT_DECLARE_SIMPLE_TYPE
Posted by Eduardo Habkost 2 years, 9 months ago
We have a SCLPEventsBus struct type defined, but no QOM type
checkers are declared for the type.

Use OBJECT_DECLARE_SIMPLE_TYPE to declare the struct type and
have a SCLP_EVENT_BUS typecast wrapper defined.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
Changes v1 -> v2:
* v1 was previously submitted as part of series:
  [PATCH for-6.2 0/6] qom: Fix broken OBJECT_CHECK usage
  at https://lore.kernel.org/qemu-devel/20210805193431.307761-5-ehabkost@redhat.com
* Fix typo (s/SCLP_EVENT_BUS/SCLP_EVENTS_BUS/)

Cc: Richard Henderson <richard.henderson@linaro.org>
Cc: David Hildenbrand <david@redhat.com>
Cc: Cornelia Huck <cohuck@redhat.com>
Cc: Halil Pasic <pasic@linux.ibm.com>
Cc: Christian Borntraeger <borntraeger@de.ibm.com>
Cc: Thomas Huth <thuth@redhat.com>
Cc: qemu-s390x@nongnu.org
Cc: qemu-devel@nongnu.org
---
 hw/s390x/event-facility.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/hw/s390x/event-facility.c b/hw/s390x/event-facility.c
index ed92ce510d9..4bfd0b194b4 100644
--- a/hw/s390x/event-facility.c
+++ b/hw/s390x/event-facility.c
@@ -328,6 +328,7 @@ static void write_event_mask(SCLPEventFacility *ef, SCCB *sccb)
 /* qemu object creation and initialization functions */
 
 #define TYPE_SCLP_EVENTS_BUS "s390-sclp-events-bus"
+OBJECT_DECLARE_SIMPLE_TYPE(SCLPEventsBus, SCLP_EVENTS_BUS)
 
 static const TypeInfo sclp_events_bus_info = {
     .name = TYPE_SCLP_EVENTS_BUS,
-- 
2.31.1


Re: [PATCH for-6.2 v2] s390-sclp-events-bus: Use OBJECT_DECLARE_SIMPLE_TYPE
Posted by Thomas Huth 2 years, 9 months ago
On 06/08/2021 04.46, Eduardo Habkost wrote:
> We have a SCLPEventsBus struct type defined, but no QOM type
> checkers are declared for the type.
> 
> Use OBJECT_DECLARE_SIMPLE_TYPE to declare the struct type and
> have a SCLP_EVENT_BUS typecast wrapper defined.
> 
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> ---
> Changes v1 -> v2:
> * v1 was previously submitted as part of series:
>    [PATCH for-6.2 0/6] qom: Fix broken OBJECT_CHECK usage
>    at https://lore.kernel.org/qemu-devel/20210805193431.307761-5-ehabkost@redhat.com
> * Fix typo (s/SCLP_EVENT_BUS/SCLP_EVENTS_BUS/)
> 
> Cc: Richard Henderson <richard.henderson@linaro.org>
> Cc: David Hildenbrand <david@redhat.com>
> Cc: Cornelia Huck <cohuck@redhat.com>
> Cc: Halil Pasic <pasic@linux.ibm.com>
> Cc: Christian Borntraeger <borntraeger@de.ibm.com>
> Cc: Thomas Huth <thuth@redhat.com>
> Cc: qemu-s390x@nongnu.org
> Cc: qemu-devel@nongnu.org
> ---
>   hw/s390x/event-facility.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/hw/s390x/event-facility.c b/hw/s390x/event-facility.c
> index ed92ce510d9..4bfd0b194b4 100644
> --- a/hw/s390x/event-facility.c
> +++ b/hw/s390x/event-facility.c
> @@ -328,6 +328,7 @@ static void write_event_mask(SCLPEventFacility *ef, SCCB *sccb)
>   /* qemu object creation and initialization functions */
>   
>   #define TYPE_SCLP_EVENTS_BUS "s390-sclp-events-bus"
> +OBJECT_DECLARE_SIMPLE_TYPE(SCLPEventsBus, SCLP_EVENTS_BUS)
>   
>   static const TypeInfo sclp_events_bus_info = {
>       .name = TYPE_SCLP_EVENTS_BUS,
> 

Reviewed-by: Thomas Huth <thuth@redhat.com>


Re: [PATCH for-6.2 v2] s390-sclp-events-bus: Use OBJECT_DECLARE_SIMPLE_TYPE
Posted by David Hildenbrand 2 years, 9 months ago
On 06.08.21 04:46, Eduardo Habkost wrote:
> We have a SCLPEventsBus struct type defined, but no QOM type
> checkers are declared for the type.
> 
> Use OBJECT_DECLARE_SIMPLE_TYPE to declare the struct type and
> have a SCLP_EVENT_BUS typecast wrapper defined.
> 
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> ---
> Changes v1 -> v2:
> * v1 was previously submitted as part of series:
>    [PATCH for-6.2 0/6] qom: Fix broken OBJECT_CHECK usage
>    at https://lore.kernel.org/qemu-devel/20210805193431.307761-5-ehabkost@redhat.com
> * Fix typo (s/SCLP_EVENT_BUS/SCLP_EVENTS_BUS/)
> 
> Cc: Richard Henderson <richard.henderson@linaro.org>
> Cc: David Hildenbrand <david@redhat.com>
> Cc: Cornelia Huck <cohuck@redhat.com>
> Cc: Halil Pasic <pasic@linux.ibm.com>
> Cc: Christian Borntraeger <borntraeger@de.ibm.com>
> Cc: Thomas Huth <thuth@redhat.com>
> Cc: qemu-s390x@nongnu.org
> Cc: qemu-devel@nongnu.org
> ---
>   hw/s390x/event-facility.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/hw/s390x/event-facility.c b/hw/s390x/event-facility.c
> index ed92ce510d9..4bfd0b194b4 100644
> --- a/hw/s390x/event-facility.c
> +++ b/hw/s390x/event-facility.c
> @@ -328,6 +328,7 @@ static void write_event_mask(SCLPEventFacility *ef, SCCB *sccb)
>   /* qemu object creation and initialization functions */
>   
>   #define TYPE_SCLP_EVENTS_BUS "s390-sclp-events-bus"
> +OBJECT_DECLARE_SIMPLE_TYPE(SCLPEventsBus, SCLP_EVENTS_BUS)
>   
>   static const TypeInfo sclp_events_bus_info = {
>       .name = TYPE_SCLP_EVENTS_BUS,
> 

Reviewed-by: David Hildenbrand <david@redhat.com>

-- 
Thanks,

David / dhildenb


Re: [PATCH for-6.2 v2] s390-sclp-events-bus: Use OBJECT_DECLARE_SIMPLE_TYPE
Posted by Cornelia Huck 2 years, 9 months ago
On Thu, Aug 05 2021, Eduardo Habkost <ehabkost@redhat.com> wrote:

> We have a SCLPEventsBus struct type defined, but no QOM type
> checkers are declared for the type.
>
> Use OBJECT_DECLARE_SIMPLE_TYPE to declare the struct type and
> have a SCLP_EVENT_BUS typecast wrapper defined.
>
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> ---
> Changes v1 -> v2:
> * v1 was previously submitted as part of series:
>   [PATCH for-6.2 0/6] qom: Fix broken OBJECT_CHECK usage
>   at https://lore.kernel.org/qemu-devel/20210805193431.307761-5-ehabkost@redhat.com
> * Fix typo (s/SCLP_EVENT_BUS/SCLP_EVENTS_BUS/)
>
> Cc: Richard Henderson <richard.henderson@linaro.org>
> Cc: David Hildenbrand <david@redhat.com>
> Cc: Cornelia Huck <cohuck@redhat.com>
> Cc: Halil Pasic <pasic@linux.ibm.com>
> Cc: Christian Borntraeger <borntraeger@de.ibm.com>
> Cc: Thomas Huth <thuth@redhat.com>
> Cc: qemu-s390x@nongnu.org
> Cc: qemu-devel@nongnu.org
> ---
>  hw/s390x/event-facility.c | 1 +
>  1 file changed, 1 insertion(+)

Reviewed-by: Cornelia Huck <cohuck@redhat.com>