qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@gmail.com>
To: sfeldma@gmail.com
Cc: jiri@resnulli.us, qemu-devel@nongnu.org, dsahern@gmail.com
Subject: Re: [Qemu-devel] [PATCH 4/4] qmp/hmp: add rocker device support
Date: Tue, 19 May 2015 14:59:59 +0100	[thread overview]
Message-ID: <20150519135959.GG9338@stefanha-thinkpad.redhat.com> (raw)
In-Reply-To: <1431583614-20100-5-git-send-email-sfeldma@gmail.com>

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

On Wed, May 13, 2015 at 11:06:54PM -0700, sfeldma@gmail.com wrote:
> diff --git a/Makefile.target b/Makefile.target
> index 1083377..f11dba4 100644
> --- a/Makefile.target
> +++ b/Makefile.target
> @@ -131,6 +131,7 @@ obj-y += qtest.o bootdevice.o
>  obj-y += hw/
>  obj-$(CONFIG_FDT) += device_tree.o
>  obj-$(CONFIG_KVM) += kvm-all.o
> +obj-$(call lnot,$(CONFIG_ROCKER)) += hw/net/rocker/qmp-norocker.o

Is there a reason for putting this in Makefile.target instead of
hw/Makefile.objs alongside the other rocker object file references?

> +void hmp_rocker(Monitor *mon, const QDict *qdict)
> +{
> +    const char *name = qdict_get_str(qdict, "name");
> +    RockerSwitch *rocker;
> +    Error *errp = NULL;
> +
> +    rocker = qmp_query_rocker(name, &errp);
> +    if (errp != NULL) {
> +        hmp_handle_error(mon, &errp);
> +        return;
> +    }
> +
> +    monitor_printf(mon, "name: %s\n", rocker->name);
> +    monitor_printf(mon, "id: 0x%016lx\n", rocker->id);

The format specifier probably needs to be PRIx64 since long is only
32-bit on 32-bit builds.

> diff --git a/qapi-schema.json b/qapi-schema.json
> index 9c92482..5c47a4f 100644
> --- a/qapi-schema.json
> +++ b/qapi-schema.json
> @@ -3759,3 +3759,6 @@
>  # Since: 2.1
>  ##
>  { 'command': 'rtc-reset-reinjection' }
> +
> +# Rocker ethernet network switch
> +{ 'include': 'qapi/rocker.json' }

I don't see qapi/rocker.json, did you forget to git add the file?

[-- Attachment #2: Type: application/pgp-signature, Size: 473 bytes --]

  reply	other threads:[~2015-05-19 14:00 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-14  6:06 [Qemu-devel] [PATCH 0/4] rocker device updates sfeldma
2015-05-14  6:06 ` [Qemu-devel] [PATCH 1/4] rocker: Add support for phys name sfeldma
2015-05-19 13:37   ` Stefan Hajnoczi
2015-05-14  6:06 ` [Qemu-devel] [PATCH 2/4] rocker: update tests using hw-derived interface names sfeldma
2015-05-19 13:38   ` Stefan Hajnoczi
2015-05-14  6:06 ` [Qemu-devel] [PATCH 3/4] rocker: bring link up/down on PHY enable/disable sfeldma
2015-05-19 13:38   ` Stefan Hajnoczi
2015-05-14  6:06 ` [Qemu-devel] [PATCH 4/4] qmp/hmp: add rocker device support sfeldma
2015-05-19 13:59   ` Stefan Hajnoczi [this message]
2015-06-20 21:16   ` Paolo Bonzini

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=20150519135959.GG9338@stefanha-thinkpad.redhat.com \
    --to=stefanha@gmail.com \
    --cc=dsahern@gmail.com \
    --cc=jiri@resnulli.us \
    --cc=qemu-devel@nongnu.org \
    --cc=sfeldma@gmail.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).