From: Szymon Janc <szymon.janc@tieto.com>
To: Lukasz Rymanowski <lukasz.rymanowski@tieto.com>
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: [PATCH] android: Add possibility to start android daemon on PC in single mode
Date: Wed, 07 May 2014 16:15:13 +0200 [thread overview]
Message-ID: <6364532.x448p36TxV@uw000953> (raw)
In-Reply-To: <1399420934-30409-1-git-send-email-lukasz.rymanowski@tieto.com>
Hi Łukasz,
On Wednesday 07 of May 2014 02:02:14 Lukasz Rymanowski wrote:
> With this patch it is possible to start android daemon on PC in
> BREDR or LE or BREDR/LE mode by setting system environment variable
> named BLUETOOTH_MODE to appropriate value according to README.
>
> This is useful for testing purposes.
> ---
> android/cutils/properties.h | 13 +++++++++++++
> 1 file changed, 13 insertions(+)
>
> diff --git a/android/cutils/properties.h b/android/cutils/properties.h
> index 66a4a84..b9c59a5 100644
> --- a/android/cutils/properties.h
> +++ b/android/cutils/properties.h
> @@ -29,9 +29,22 @@
>
> #define PROPERTY_VALUE_MAX 32
>
> +#define BLUETOOTH_MODE_PROPERTY_NAME "persist.sys.bluetooth.mode"
> +
> static inline int property_get(const char *key, char *value,
> const char *default_value)
> {
> + if (!strcmp(key, BLUETOOTH_MODE_PROPERTY_NAME)) {
> + char *mode;
> +
> + mode = getenv("BLUETOOTH_MODE");
> + if (!mode)
> + return 0;
> +
> + memcpy(value, mode, strlen(mode));
> + return 1;
> + }
> +
> return 0;
> }
>
>
Pushed with changes we discussed offline, thanks.
--
Best regards,
Szymon Janc
prev parent reply other threads:[~2014-05-07 14:15 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-07 0:02 [PATCH] android: Add possibility to start android daemon on PC in single mode Lukasz Rymanowski
2014-05-07 14:15 ` Szymon Janc [this message]
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=6364532.x448p36TxV@uw000953 \
--to=szymon.janc@tieto.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=lukasz.rymanowski@tieto.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