qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Huth <thuth@redhat.com>
To: "Philippe Mathieu-Daudé" <philmd@redhat.com>, qemu-devel@nongnu.org
Cc: Peter Maydell <peter.maydell@linaro.org>,
	Miroslav Rezanina <mrezanin@redhat.com>,
	qemu-arm@nongnu.org, Gerd Hoffmann <kraxel@redhat.com>,
	Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [Qemu-devel] [PATCH-for-4.1? 7/7] hw/bt: Allow building with CONFIG_BLUETOOTH disabled
Date: Mon, 15 Jul 2019 15:08:43 +0200	[thread overview]
Message-ID: <fba3d5fc-4a5d-d967-5bb3-075159b93a0d@redhat.com> (raw)
In-Reply-To: <20190712133928.21394-8-philmd@redhat.com>

On 12/07/2019 15.39, Philippe Mathieu-Daudé wrote:
> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> ---
>  Makefile.objs       |  3 ++-
>  bt-stubs.c          | 18 ++++++++++++++++++
>  hw/bt/Makefile.objs |  4 ++--
>  3 files changed, 22 insertions(+), 3 deletions(-)
>  create mode 100644 bt-stubs.c
> 
> diff --git a/Makefile.objs b/Makefile.objs
> index c2845a0efc..98269e393a 100644
> --- a/Makefile.objs
> +++ b/Makefile.objs
> @@ -65,8 +65,9 @@ common-obj-y += replay/
>  
>  common-obj-y += ui/
>  common-obj-m += ui/
> -common-obj-y += bt-host.o bt-vhci.o bt-opts.o
>  bt-host.o-cflags := $(BLUEZ_CFLAGS)
> +common-obj-$(CONFIG_BLUETOOTH) += bt-host.o bt-vhci.o bt-opts.o
> +common-obj-$(call lnot,$(CONFIG_BLUETOOTH)) += bt-stubs.o
>  
>  common-obj-y += dma-helpers.o
>  common-obj-y += vl.o
> diff --git a/bt-stubs.c b/bt-stubs.c
> new file mode 100644
> index 0000000000..d3f5158d3b
> --- /dev/null
> +++ b/bt-stubs.c
> @@ -0,0 +1,18 @@
> +/*
> + * Bluetooth stubs.
> + *
> + * Copyright (c) 2019 Red Hat, Inc.
> + *
> + * SPDX-License-Identifier: GPL-2.0-or-later
> + */
> +
> +#include "qemu/osdep.h"
> +#include "qemu/error-report.h"
> +#include "sysemu/bt.h"
> +
> +int bt_parse(const char *opt)
> +{
> +    error_report("Bluetooth support is disabled");
> +
> +    return 1;
> +}
> diff --git a/hw/bt/Makefile.objs b/hw/bt/Makefile.objs
> index 867a7d2e8a..46aec8e38e 100644
> --- a/hw/bt/Makefile.objs
> +++ b/hw/bt/Makefile.objs
> @@ -1,3 +1,3 @@
> -common-obj-y += core.o l2cap.o sdp.o hci.o hid.o
> -common-obj-y += hci-csr.o
> +common-obj-$(CONFIG_BLUETOOTH) += core.o l2cap.o sdp.o hci.o hid.o
> +common-obj-$(CONFIG_BLUETOOTH) += hci-csr.o

... ok, so the BLUETOOTH switch gets used here. But I wonder whether we
should have separate switches for the backends (i.e. the files here) and
the guest devices (i.e. the ones in hw/bt/) ?

 Thomas


  reply	other threads:[~2019-07-15 13:09 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-12 13:39 [Qemu-devel] [PATCH-for-4.1? 0/7] vl: Allow building with CONFIG_BLUETOOTH disabled Philippe Mathieu-Daudé
2019-07-12 13:39 ` [Qemu-devel] [PATCH-for-4.1? 1/7] hw/arm: Nokia N-series tablet requires Bluetooth Philippe Mathieu-Daudé
2019-07-15 13:05   ` Thomas Huth
2019-07-12 13:39 ` [Qemu-devel] [PATCH-for-4.1 2/7] hw/usb: Bluetooth HCI USB depends on USB & BLUETOOTH Philippe Mathieu-Daudé
2019-07-12 13:58   ` Paolo Bonzini
2019-07-12 14:16     ` Philippe Mathieu-Daudé
2019-07-12 14:58       ` Paolo Bonzini
2019-07-12 16:45         ` Philippe Mathieu-Daudé
2019-07-12 17:31           ` Paolo Bonzini
2019-07-14 16:01             ` Philippe Mathieu-Daudé
2019-07-12 13:39 ` [Qemu-devel] [PATCH-for-4.1? 3/7] MAINTAINERS: Add an entry for the Bluetooth devices Philippe Mathieu-Daudé
2019-08-14 12:47   ` Philippe Mathieu-Daudé
2019-07-12 13:39 ` [Qemu-devel] [PATCH-for-4.1? 4/7] vl: Fix 'braces' coding style issues Philippe Mathieu-Daudé
2019-07-12 13:39 ` [Qemu-devel] [PATCH-for-4.1? 5/7] vl: Use qemu_strtoi() instead of strtol() Philippe Mathieu-Daudé
2019-07-12 13:39 ` [Qemu-devel] [PATCH-for-4.1? 6/7] vl: Extract bt_parse() into its own file Philippe Mathieu-Daudé
2019-07-12 13:39 ` [Qemu-devel] [PATCH-for-4.1? 7/7] hw/bt: Allow building with CONFIG_BLUETOOTH disabled Philippe Mathieu-Daudé
2019-07-15 13:08   ` Thomas Huth [this message]
2019-07-14 11:04 ` [Qemu-devel] [PATCH-for-4.1? 0/7] vl: " Richard Henderson
2019-07-15 13:13 ` Thomas Huth
2019-08-13 14:00   ` Philippe Mathieu-Daudé
2019-08-13 14:04     ` Peter Maydell
2019-08-14 12:45       ` Philippe Mathieu-Daudé
2019-11-07 19:09         ` Philippe Mathieu-Daudé
2019-11-07 19:31           ` Thomas Huth

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=fba3d5fc-4a5d-d967-5bb3-075159b93a0d@redhat.com \
    --to=thuth@redhat.com \
    --cc=kraxel@redhat.com \
    --cc=mrezanin@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@redhat.com \
    --cc=qemu-arm@nongnu.org \
    --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).