From: Andrei Emeltchenko <Andrei.Emeltchenko.news@gmail.com>
To: Szymon Janc <szymon.janc@tieto.com>
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: [RFCv2 06/14] android: Create HAL API header skeleton
Date: Fri, 4 Oct 2013 10:16:30 +0300 [thread overview]
Message-ID: <20131004071628.GD2804@aemeltch-MOBL1> (raw)
In-Reply-To: <4501039.OZxtA2WV21@uw000953>
Hi All,
On Thu, Oct 03, 2013 at 04:07:08PM +0200, Szymon Janc wrote:
> > +
> > +/* Core Service */
> > +
> > +struct hal_msg_rsp {
> > + struct hal_msg_hdr hdr;
> > + uint8_t status;
> > +} __packed;
>
> Non-error response to request has no status field, just header.
I have removed the structure in the following patches but I still have
doubts that this is a good approach.
So in a case of error we get:
struct error_rsp {
struct hal_msg_hdr hdr;
uint8_t status;
}
and in a case of success we get:
struct rsp {
struct hal_msg_hdr hdr;
}
Does it make sense to omit status? We could read error_rsp and check
status for error while in the current design we have to check for size
received. Are we gonna save uint8_t?
Best regards
Andrei Emeltchenko
next prev parent reply other threads:[~2013-10-04 7:16 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-01 15:03 [RFCv2 00/14] Basic code for Android BlueZ Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 01/14] android: Add Adapter Bluetooth HAL template Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 02/14] android: Add Socket " Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 03/14] android: Enable Socket interface Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 04/14] android: Start Android Bluetooth daemon Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 05/14] android: Add basic mgmt initialization sequence Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 06/14] android: Create HAL API header skeleton Andrei Emeltchenko
2013-10-03 14:07 ` Szymon Janc
2013-10-04 7:16 ` Andrei Emeltchenko [this message]
2013-10-01 15:03 ` [RFCv2 07/14] android: Add adapter and device struct for BlueZ daemon Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 08/14] android: Add Android Makefile for libbluetooth Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 09/14] android: sdp: Reuse BlueZ SDP server in Android Andrei Emeltchenko
2013-10-03 11:23 ` Szymon Janc
2013-10-03 11:35 ` Andrei Emeltchenko
2013-10-03 11:47 ` Szymon Janc
2013-10-01 15:03 ` [RFCv2 10/14] android: Add cap to bind to port < 1024 Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 11/14] android: Implement read_info_complete callback Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 12/14] android: Handle mgmt changed events Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 13/14] android: Add makefile for hciconfig Andrei Emeltchenko
2013-10-01 15:03 ` [RFCv2 14/14] android: Add makefile for hcitool Andrei Emeltchenko
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=20131004071628.GD2804@aemeltch-MOBL1 \
--to=andrei.emeltchenko.news@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=szymon.janc@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