public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
From: David Sainty <david.sainty@dtsp.co.nz>
To: "Li, Zhigang" <zhigang.li@intel.com>
Cc: "linux-bluetooth@vger.kernel.org" <linux-bluetooth@vger.kernel.org>
Subject: Re: To enablue DID in coming bluez release
Date: Wed, 17 Dec 2008 15:25:02 +1300	[thread overview]
Message-ID: <494862FE.8060805@dtsp.co.nz> (raw)
In-Reply-To: <B94C62E7C2870743865418621F040C1303B80C0F@pdsmsx502.ccr.corp.intel.com>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=gb2312, Size: 2687 bytes --]

Typo in main.conf: "verndor"


Li, Zhigang wrote:
> Please check it again.
> Marcel mention it in IRC for VID/PID/VER
>
> --- a/main.c	Tue Dec 16 17:43:24 2008 +0800
> +++ b/main.c	Wed Dec 17 09:57:37 2008 +0800
> @@ -174,6 +174,17 @@ static void parse_config(GKeyFile *confi
>  		main_opts.inqmode = val;
>  	}
>  
> +	str = g_key_file_get_string(config, "General",
> +					"VID/PID/VER", &err);
> +	if (err) {
> +		debug("%s", err->message);
> +		g_clear_error(&err);
> +	} else {
> +		debug("vid/pid/ver=%s", str);
> +		strncpy(main_opts.deviceid, str, sizeof(main_opts.deviceid));
> +		g_free(str);
> +	}
> +
>  	main_opts.link_mode = HCI_LM_ACCEPT;
>  
>  	main_opts.link_policy = HCI_LP_RSWITCH | HCI_LP_SNIFF |
> diff -r 65556502911d main.conf
> --- a/main.conf	Tue Dec 16 17:43:24 2008 +0800
> +++ b/main.conf	Tue Dec 16 17:50:31 2008 +0800
> @@ -28,3 +28,9 @@ OffMode = NoScan
>  # Discover scheduler interval used in Adapter.DiscoverDevices
>  # The value is in seconds. Defaults is 0 to use controller scheduler
>  DiscoverSchedulerInterval = 0
> +
> +
> +# User verndor and product and version information are used in DID profile
> +# ":" to identify the value. FFFF is reserved for VendorId by default.
> +VID/PID/VER = 1234:5678:abcd
> +
>
> Thanks
>
> -----Original Message-----
> From: linux-bluetooth-owner@vger.kernel.org [mailto:linux-bluetooth-owner@vger.kernel.org] On Behalf Of Johan Hedberg
> Sent: 2008Äê12ÔÂ16ÈÕ 18:29
> To: linux-bluetooth@vger.kernel.org
> Subject: Re: To enablue DID in coming bluez release
>
> Hi,
>
> Couple of comments:
>
> On Tue, Dec 16, 2008, Li, Zhigang wrote:
>   
>>  		main_opts.inqmode = val;
>>  	}
>> +	str = g_key_file_get_string(config, "General",
>>     
>
> Coding style: add empty line after the closing bracket.
>
>   
>> +					"VID/PID/VER", &err);
>>     
>
> Did you agree with this "VID/PID/VER" name with Marcel? I'd have used
> something like "DeviceID", "DeviceIDInfo" or "DIDInfo".
>
>   
>> +		strcpy( main_opts.deviceid,str);
>>     
>
> First, coding style: remove the extra space after the opening
> parenthesis and add the missing one after the comma. Second, you're
> overflowing main_opts.deviceid if the string provided in main.conf is
> longer than 14 characters. So the call should be:
> strncpy(main_opts.deviceid, src, sizeof(main_opts.deviceid));
>
> Johan
> --
> To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> N‹§²æìr¸›yúèšØb²X¬¶Ç§vØ^\x7f\x7f)Þº{.n\x7f\x7f+‰·¥Š{±n[ž¶\x7f\x7f-\x7f\x7f)í…æèw*\x1fjg¬±\x7f\x7f\x1e¶‰šŽŠÝ¢j/êäz¹Þ–Ё\x7f\x7f™¨è­\x7f\x7f&\x7f\x7f)ß¡«a¶Ú\x7fþø\x1e®G«éh\x7f\x7f\x0fæj:+v‰¨Šwè†Ù¥


  reply	other threads:[~2008-12-17  2:25 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-12  1:52 To enablue DID in coming bluez release Li, Zhigang
2008-12-12  1:55 ` Marcel Holtmann
2008-12-16  7:55   ` Li, Zhigang
2008-12-16  9:59     ` Li, Zhigang
2008-12-16 10:29       ` Johan Hedberg
2008-12-17  2:17         ` Li, Zhigang
2008-12-17  2:25           ` David Sainty [this message]
2008-12-17  2:38         ` Marcel Holtmann
2008-12-17  3:10           ` Li, Zhigang
2008-12-17 19:59             ` Marcel Holtmann
2008-12-18  5:55               ` Li, Zhigang
2008-12-19 19:01                 ` Marcel Holtmann

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=494862FE.8060805@dtsp.co.nz \
    --to=david.sainty@dtsp.co.nz \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=zhigang.li@intel.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