From: Marcel Holtmann <marcel@holtmann.org>
To: Iain Hibbert <plunky@rya-online.net>
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: "packet types" wrong in libbluetooth
Date: Sat, 10 Jan 2009 17:13:25 +0100 [thread overview]
Message-ID: <1231604005.5229.5.camel@californication> (raw)
In-Reply-To: <1231603296.653256.942.nullmailer@galant.ukfsn.org>
Hi Iain,
> > > The HCI packet type functions ptypetostr() and strtoptype() in lib/hci.c
> > > don't work correctly. This is because the HCI spec is messed up wrt the 2
> > > and 3 Mbps packet types, which are indicated by inverted bit logic (see
> > > "Create Connection Command" in core spec document)
> >
> > current situation is perfectly fine. It follows the spec. closely and
> > this means for EDR the types are inverted.
>
> since the spec is somewhat twisty I don't see how it follows it at all :)
>
> > Trying to make them looks nice doesn't help. You should not mess with
> > packet types at all. It is the link managers' job to get this right.
>
> I am not messing with packet types at all. I apologise because I don't use
> Linux or the BlueZ tools in general but it seems that hcidump displays
> "Create Connection" packets (at least) incorrectly because of this. For
> instance
>
> hci_ptypetostr(HCI_DH1)
>
> will return
>
> "DH1 "
>
> which seems normal. But, when this is part of a HCI packet (eg Create
> Connection command), that result should actually be:
>
> "DH1 2-DH1 2-DH3 2-DH5 3-DH1 3-DH3 3-DH5 "
>
> Should it be handled in hcidump instead, as below?
the Create Connection displays the actual bits set. And that is how it
suppose to be. The above line means EDR disabled. You set the bitmask
and that the meaning of some bits is disabled instead of enabled is a
different story.
Regards
Marcel
next prev parent reply other threads:[~2009-01-10 16:13 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-10 13:50 "packet types" wrong in libbluetooth Iain Hibbert
2009-01-10 14:21 ` Marcel Holtmann
2009-01-10 16:01 ` Iain Hibbert
2009-01-10 16:13 ` Marcel Holtmann [this message]
2009-01-10 17:59 ` Iain Hibbert
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=1231604005.5229.5.camel@californication \
--to=marcel@holtmann.org \
--cc=linux-bluetooth@vger.kernel.org \
--cc=plunky@rya-online.net \
/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