28 Jun 2011 09:47
[PATCH v3 openobex 1/3] Add transport format member in fdobex_data struct. Support STREAM and SEQPACKET transport format.
Nami <nami.li <at> atheros.com>
2011-06-28 07:47:50 GMT
2011-06-28 07:47:50 GMT
These patches enable fd obex transport to support SEQPACKET format to read entire packet at a time.
Add fmt member to indicate transport format, the init value is STREAM format.
Create a new api for upper layer to set transport format when using OBEX over L2CAP.
---
include/openobex/obex_const.h | 5 +++++
lib/fdobex.c | 1 +
lib/fdobex.h | 1 +
3 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/include/openobex/obex_const.h b/include/openobex/obex_const.h
index cb7afeb..700bacb 100644
--- a/include/openobex/obex_const.h
+++ b/include/openobex/obex_const.h
<at> <at> -302,6 +302,11 <at> <at> enum obex_rsp_mode {
OBEX_RSP_MODE_SINGLE = 1, /**≤ single response mode (SRM) */
};
+enum fdobex_transport_format {
+ FDOBEX_MT_STREAM = 0, /**≤ stream transport format */
+ FDOBEX_MT_SEQPACKET = 1, /**≤ seqpacket transport format */
+};
+
/* Min, Max and default transport MTU */
#define OBEX_DEFAULT_MTU 1024
#define OBEX_MINIMUM_MTU 255
diff --git a/lib/fdobex.c b/lib/fdobex.c
index 45c56ff..7fa4a21 100644
--- a/lib/fdobex.c
+++ b/lib/fdobex.c
(Continue reading)
RSS Feed