qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 28/63] tusb6010: Rename TYPE_TUSB6010 to TYPE_TUSB


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH 28/63] tusb6010: Rename TYPE_TUSB6010 to TYPE_TUSB
Date: Thu, 3 Sep 2020 14:56:20 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0

On 9/3/20 12:42 AM, Eduardo Habkost wrote:
> This will make the type name constant consistent with the name of
> the type checking macro.
> 
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> ---
> Cc: Gerd Hoffmann <kraxel@redhat.com>
> Cc: qemu-devel@nongnu.org
> ---
>  hw/usb/tusb6010.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/hw/usb/tusb6010.c b/hw/usb/tusb6010.c
> index 2bee3ae59f..9b35c1d4b8 100644
> --- a/hw/usb/tusb6010.c
> +++ b/hw/usb/tusb6010.c
> @@ -30,10 +30,10 @@
>  #include "hw/sysbus.h"
>  #include "qom/object.h"
>  
> -#define TYPE_TUSB6010 "tusb6010"
> +#define TYPE_TUSB "tusb6010"

We are loosing information helpful to reviewers.
Can we rename the type macro TUSB6010() instead?

>  typedef struct TUSBState TUSBState;
>  DECLARE_INSTANCE_CHECKER(TUSBState, TUSB,
> -                         TYPE_TUSB6010)
> +                         TYPE_TUSB)
>  
>  struct TUSBState {
>      SysBusDevice parent_obj;
> @@ -838,7 +838,7 @@ static void tusb6010_class_init(ObjectClass *klass, void 
> *data)
>  }
>  
>  static const TypeInfo tusb6010_info = {
> -    .name          = TYPE_TUSB6010,
> +    .name          = TYPE_TUSB,
>      .parent        = TYPE_SYS_BUS_DEVICE,
>      .instance_size = sizeof(TUSBState),
>      .class_init    = tusb6010_class_init,
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]