From: Gerd Hoffmann <kraxel@redhat.com>
To: mrezanin@redhat.com
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCHv2] Make usb-bt-dongle configurable
Date: Tue, 03 Sep 2013 09:41:11 +0200 [thread overview]
Message-ID: <1378194071.3618.8.camel@nilsson.home.kraxel.org> (raw)
In-Reply-To: <fc4ad2cce7093425d113dd2d8f97048a990413cd.1378192732.git.mrezanin@redhat.com>
> diff --git a/hw/bt/core.c b/hw/bt/core.c
> index 49012e0..ef27b15 100644
> --- a/hw/bt/core.c
> +++ b/hw/bt/core.c
> @@ -119,3 +119,28 @@ void bt_device_done(struct bt_device_s *dev)
>
> *p = dev->next;
> }
> +
> +static struct bt_vlan_s {
> + struct bt_scatternet_s net;
> + int id;
> + struct bt_vlan_s *next;
> +} *first_bt_vlan;
> +
> +/* find or alloc a new bluetooth "VLAN" */
> +struct bt_scatternet_s *qemu_find_bt_vlan(int id)
> +{
> + struct bt_vlan_s **pvlan, *vlan;
> + for (vlan = first_bt_vlan; vlan != NULL; vlan = vlan->next) {
> + if (vlan->id == id) {
> + return &vlan->net;
> + }
> + }
> + vlan = g_malloc0(sizeof(struct bt_vlan_s));
> + vlan->id = id;
> + pvlan = &first_bt_vlan;
> + while (*pvlan != NULL) {
> + pvlan = &(*pvlan)->next;
> + }
> + *pvlan = vlan;
> + return &vlan->net;
> +}
This (and some other bits) are pure code motion from vl.c, correct?
Can you split this into a separate patch please? That'll simplify the
review o the actual code changes.
It also doesn't make much sense to compile hw/bt/ with
CONFIG_USB_BLUETOOTH=n. It's basically dead code then.
cheers,
Gerd
next prev parent reply other threads:[~2013-09-03 7:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-03 7:26 [Qemu-devel] [PATCHv2] Make usb-bt-dongle configurable mrezanin
2013-09-03 7:41 ` Gerd Hoffmann [this message]
2013-09-03 8:46 ` Miroslav Rezanina
2013-09-03 11:33 ` Gerd Hoffmann
2013-09-03 8:34 ` 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=1378194071.3618.8.camel@nilsson.home.kraxel.org \
--to=kraxel@redhat.com \
--cc=mrezanin@redhat.com \
--cc=qemu-devel@nongnu.org \
/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).