qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eric Blake <eblake@redhat.com>
To: "Anton Ivanov (antivano)" <antivano@cisco.com>
Cc: "Qemu-devel@nongnu.org" <Qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] Contribution - L2TPv3 transport
Date: Fri, 28 Feb 2014 06:57:27 -0700	[thread overview]
Message-ID: <531095C7.3020500@redhat.com> (raw)
In-Reply-To: <531094A1.8000400@cisco.com>

[-- Attachment #1: Type: text/plain, Size: 1923 bytes --]

On 02/28/2014 06:52 AM, Anton Ivanov (antivano) wrote:
> On 28/02/14 13:40, Eric Blake wrote:
>> On 02/28/2014 01:28 AM, Anton Ivanov (antivano) wrote:
>>> Hi all,
>>>
>>> On behalf of Cisco Systems I am authorized to contribute a new transport
>>> to the network subsystem in qemu.
>>>

>>> +#
>>> +#
>>> +# Since 1.0
>> s/1.0/2.0/
> 
> OK - just to clarify, which version is this referring to - qemu, api, etc?

This field is the version of qemu that first contains the release.  If
your patch is on time to make the qemu 2.0 release, then 2.0 is
appropriate; but we're close to feature freeze so it may end up being 2.1.

> 
>>
>>> +##
>>> +##
>>> +{ 'type': 'NetdevL2TPv3Options',
>>> +  'data': {
>>> +    '*fd':        'str',
>>> +    '*src':	  'str', 
>> You didn't list 'src' as optional above.
> 
> That is intended. It is not optional for the ip command in Linux either.
> For L2TPv3 tunnels you have to specify the source address.

But listing it as '*src' means it is optional.  If it is mandatory, list
it as 'src'.

> 
>>
>> Trailing whitespace - run your submission through checkpatch.pl.
>>
>>> +    '*dst':	  'str', 
>>> +    '*mode':	  'str', 
>> As mentioned above, 'mode' should not be a string.
>>
>>> +    '*txcookie':  'str',
>>> +    '*rxcookie':  'str',
>>> +    '*txsession': 'str',
>>> +    '*rxsession': 'str'
>> These should probably be 'int', not 'str'.  If you have to hand-parse a
>> string into a numeric value, you encoded the QMP wrong.
> 
> These by spec are either 32 bit or 64 bit integers. I will fix them
> accordingly.

The qapi type 'int' is 64-bit.  You can further range check the values
in your C code and fail the command if the user passed values that don't
fit in 32 bits when they requested a 32-bit mode.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 604 bytes --]

  reply	other threads:[~2014-02-28 13:57 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-28  8:28 [Qemu-devel] Contribution - L2TPv3 transport Anton Ivanov (antivano)
2014-02-28 10:02 ` Paolo Bonzini
2014-02-28 11:17   ` Anton Ivanov (antivano)
2014-02-28 11:36     ` Paolo Bonzini
2014-02-28 12:59       ` Anton Ivanov (antivano)
2014-02-28 13:55   ` Anton Ivanov (antivano)
2014-03-04 15:19   ` Anton Ivanov (antivano)
2014-03-04 15:22     ` Anton Ivanov (antivano)
2014-03-04 15:53       ` Eric Blake
2014-03-04 16:05         ` Anton Ivanov (antivano)
2014-03-05  8:49         ` Anton Ivanov (antivano)
2014-03-05 11:38           ` Peter Maydell
2014-03-04 15:41     ` Eric Blake
2014-03-04 15:58       ` Anton Ivanov (antivano)
2014-03-04 16:04         ` Paolo Bonzini
2014-03-04 16:33     ` Eric Blake
2014-03-04 16:48       ` Anton Ivanov (antivano)
2014-03-04 16:55         ` Paolo Bonzini
2014-03-04 17:28           ` Anton Ivanov (antivano)
2014-03-04 17:30             ` Paolo Bonzini
2014-02-28 13:40 ` Eric Blake
2014-02-28 13:52   ` Anton Ivanov (antivano)
2014-02-28 13:57     ` Eric Blake [this message]
2014-02-28 14:03       ` Anton Ivanov (antivano)
2014-02-28 14:00   ` Paolo Bonzini
2014-02-28 15:06     ` Eric Blake
2014-02-28 15:20       ` Paolo Bonzini
2014-03-03 13:27 ` Stefan Hajnoczi
2014-03-03 14:01   ` Anton Ivanov (antivano)
2014-03-04  9:36     ` Stefan Hajnoczi
2014-03-04  9:47       ` Anton Ivanov (antivano)
2014-03-05  8:59         ` Stefan Hajnoczi
2014-03-05  9:13           ` Vincenzo Maffione
2014-03-03 14:53 ` Stefan Hajnoczi
2014-03-04 11:32   ` Anton Ivanov (antivano)
2014-03-05  9:07     ` Stefan Hajnoczi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=531095C7.3020500@redhat.com \
    --to=eblake@redhat.com \
    --cc=Qemu-devel@nongnu.org \
    --cc=antivano@cisco.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).