qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 4/4] net: convert NetClientState to QOM


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH 4/4] net: convert NetClientState to QOM
Date: Thu, 18 Oct 2012 17:06:33 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:16.0) Gecko/20121016 Thunderbird/16.0.1

Il 18/10/2012 16:56, Stefan Hajnoczi ha scritto:
>  
> -static NetClientInfo net_tap_win32_info = {
> -    .type = NET_CLIENT_OPTIONS_KIND_TAP,
> -    .size = sizeof(TAPState),
> -    .receive = tap_receive,
> -    .cleanup = tap_cleanup,
> +#define TYPE_TAP_WIN32_NET_CLIENT "tap-win32-net-client"
> +
> +static void tap_win32_net_client_class_init(ObjectClass *klass,
> +                                            void *class_data)
> +{
> +    NetClientClass *ncc = NET_CLIENT_CLASS(klass);
> +
> +    ncc->type_str = "tap";
> +    ncc->receive = tap_receive;
> +    ncc->cleanup = tap_cleanup;
> +}
> +
> +static TypeInfo tap_win32_net_client_info = {
> +    .name = TYPE_TAP_WIN32_NET_CLIENT,
> +    .parent = TYPE_NET_CLIENT,

Why a separate type name than TYPE_NET_CLIENT?  It doesn't really matter
if the client is Unix or Win32.

Paolo




reply via email to

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