* [PATCH 0/2] Minor bug fixes from UPF38
@ 2011-02-19 20:45 Brian Gix
2011-02-19 20:45 ` [PATCH 1/2] Add missing UUID16 field to Included Svc Attribute Brian Gix
2011-02-19 20:45 ` [PATCH 2/2] Fix Crash where MTU allowed to be set too large Brian Gix
0 siblings, 2 replies; 4+ messages in thread
From: Brian Gix @ 2011-02-19 20:45 UTC (permalink / raw)
To: linux-bluetooth
--
Brian Gix
bgix@codeaurora.org
Employee of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH 1/2] Add missing UUID16 field to Included Svc Attribute
2011-02-19 20:45 [PATCH 0/2] Minor bug fixes from UPF38 Brian Gix
@ 2011-02-19 20:45 ` Brian Gix
2011-02-19 20:45 ` [PATCH 2/2] Fix Crash where MTU allowed to be set too large Brian Gix
1 sibling, 0 replies; 4+ messages in thread
From: Brian Gix @ 2011-02-19 20:45 UTC (permalink / raw)
To: linux-bluetooth; +Cc: Brian Gix
---
attrib/example.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/attrib/example.c b/attrib/example.c
index cd18168..395650a 100644
--- a/attrib/example.c
+++ b/attrib/example.c
@@ -124,7 +124,8 @@ static int register_attributes(void)
/* Thermometer: Include */
att_put_u16(0x0550, &atval[0]);
att_put_u16(0x0568, &atval[2]);
- attrib_db_add(0x0202, &uuid, ATT_NONE, ATT_NOT_PERMITTED, atval, 4);
+ att_put_u16(VENDOR_SPECIFIC_SVC_UUID, &atval[4]);
+ attrib_db_add(0x0202, &uuid, ATT_NONE, ATT_NOT_PERMITTED, atval, 6);
/* Thermometer: temperature characteristic */
sdp_uuid16_create(&uuid, GATT_CHARAC_UUID);
--
1.7.1
--
Brian Gix
bgix@codeaurora.org
Employee of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/2] Fix Crash where MTU allowed to be set too large
2011-02-19 20:45 [PATCH 0/2] Minor bug fixes from UPF38 Brian Gix
2011-02-19 20:45 ` [PATCH 1/2] Add missing UUID16 field to Included Svc Attribute Brian Gix
@ 2011-02-19 20:45 ` Brian Gix
2011-02-20 18:29 ` Johan Hedberg
1 sibling, 1 reply; 4+ messages in thread
From: Brian Gix @ 2011-02-19 20:45 UTC (permalink / raw)
To: linux-bluetooth; +Cc: Brian Gix
As previously written, a remote device could request, and we would
accept an MTU larger than what we could support.
---
src/attrib-server.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/attrib-server.c b/src/attrib-server.c
index 6966ad0..4285f6e 100644
--- a/src/attrib-server.c
+++ b/src/attrib-server.c
@@ -639,7 +639,7 @@ static uint16_t write_value(struct gatt_channel *channel, uint16_t handle,
static uint16_t mtu_exchange(struct gatt_channel *channel, uint16_t mtu,
uint8_t *pdu, int len)
{
- channel->mtu = MIN(mtu, ATT_MAX_MTU);
+ channel->mtu = MIN(mtu, channel->mtu);
return enc_mtu_resp(channel->mtu, pdu, len);
}
--
1.7.1
--
Brian Gix
bgix@codeaurora.org
Employee of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 2/2] Fix Crash where MTU allowed to be set too large
2011-02-19 20:45 ` [PATCH 2/2] Fix Crash where MTU allowed to be set too large Brian Gix
@ 2011-02-20 18:29 ` Johan Hedberg
0 siblings, 0 replies; 4+ messages in thread
From: Johan Hedberg @ 2011-02-20 18:29 UTC (permalink / raw)
To: Brian Gix; +Cc: linux-bluetooth
Hi Brian,
On Sat, Feb 19, 2011, Brian Gix wrote:
> As previously written, a remote device could request, and we would
> accept an MTU larger than what we could support.
> ---
> src/attrib-server.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
Both patches have been pushed upstream. Thanks.
Johan
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2011-02-20 18:29 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-19 20:45 [PATCH 0/2] Minor bug fixes from UPF38 Brian Gix
2011-02-19 20:45 ` [PATCH 1/2] Add missing UUID16 field to Included Svc Attribute Brian Gix
2011-02-19 20:45 ` [PATCH 2/2] Fix Crash where MTU allowed to be set too large Brian Gix
2011-02-20 18:29 ` Johan Hedberg
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).