Commit Graph

148 Commits

Author SHA1 Message Date
Aki Niemi 876943e2b4 gisi: Add getter for sub-block data
Also fix indentation and change int->unsigned in the API.
2009-10-14 22:46:26 +03:00
Pekka Pessi d1d870ba7a Refactor subblock iterators.
Always initialize iterators.

Try to avoid pointer arithmetics on NULL; in other words, move all pointer
arithmetics inside g_isi_sb_iter_init().

There are 4 different ways for representing sub blocks in ISI message:
- 8-bit sub_blocks count, 8-bit sub_block_id/sub_block_len
- 16-bit sub_blocks count, 8-bit sub_block_id/sub_block_len
- 8-bit sub_blocks count, 16-bit sub_block_id/sub_block_len
- 16-bit sub_blocks count, 16-bit sub_block_id/sub_block_len

The compact form g_isi_sb_iter_init() supports 8-bit sub_block count before
start of the sub blocks themselves and 8-bit sub_block_id and sub_block_len.
The full form g_isi_sb_iter_init_full() with explicit longhdr and sub_block
count supports all other cases.
2009-10-09 12:54:04 +03:00
Pekka Pessi bc8031e2d7 gisi: use const and restrict in iter 2009-10-07 23:21:15 +03:00
Aki Niemi 0b28b05678 gisi: Make reachability detection more robust 2009-09-16 23:37:23 +03:00
Aki Niemi a34849599b Fix restrict keyword usage 2009-09-16 09:05:53 +03:00
Aki Niemi 8bbd9a8560 gisi: Add ISI version and reachability check API
This patch adds an API for querying the ISI version of the resource
with which the client is associated. This information is only
available after g_isi_verify() has been called on the client. This is
because we use the version query message as a vehicle for reachability
checking.
2009-09-15 15:35:47 +03:00
Aki Niemi 3cec9ac67b Add support for long sub-block header 2009-09-14 23:43:17 +03:00
Aki Niemi a1ca8a9afa Add and modify string getters
Add a getter for latin ASCII only tags, and change the alpha tag
getter. Turns out not all alpha tags in ISI are of the length-value
variety.
2009-09-14 16:21:06 +03:00
Aki Niemi dec66954b6 gisi: Add ISI sub-block iterator 2009-09-14 14:34:00 +03:00
Rémi Denis-Courmont 94a0c4e708 gisi: cannot do ioctl() with Netlink sockets, use local instead 2009-09-10 17:44:01 +03:00
Rémi Denis-Courmont 418dba1ec3 gisi: Fix embarrassing typo 2009-09-10 17:43:30 +03:00
Rémi Denis-Courmont 54f61961b5 gisi: bring Phonet interface up before telling upper layers about it
This should get kernel-assisted Phonet autoconfiguration to work (and it
shouldn't hurt in other cases). Otherwise, the upper layers will try to
send packets, which will fail. Then they will probably just time out.
2009-09-10 15:31:21 +03:00
Rémi Denis-Courmont 3feaacb6ce gisi: disable logging by default
The debug_func was not initialized.
2009-09-09 22:26:44 +02:00
Ismo Puustinen 3f5851f4e9 gisi: Getter function for pipe handle 2009-09-01 13:42:15 +03:00
Rémi Denis-Courmont aef72327c2 gisi: return GPRS interface index/name 2009-08-28 15:20:27 +03:00
Aki Niemi 373665cdd0 gisi: Fix indication debugging 2009-08-25 18:26:24 +03:00
Marcel Holtmann 70aab2a826 Convert to fully non-recursive build system 2009-08-24 23:49:40 -07:00
Aki Niemi 5086088458 gisi: Fix warning in g_isi_subscribe()
Save the GIsiModem instance in GIsiClient, so that calling
g_isi_subscribe() doesn't throw a warning.
2009-08-23 23:19:03 +03:00
Aki Niemi 197cefbba5 gisi: Add debugging hooks 2009-08-22 18:01:24 +03:00
Denis Kenzior 779851acec Fix control reaches end of non-void function 2009-08-20 15:39:11 -05:00
Denis Kenzior 63f3bc455f Fix unused variable err warning 2009-08-20 15:39:11 -05:00
Denis Kenzior d465d4c4a5 Fix implicit declaration of close warning 2009-08-20 15:39:11 -05:00
Rémi Denis-Courmont 89843ba662 gisi: PEP: use more portable non-blocking and close-on-exec 2009-08-20 11:08:25 +03:00
Denis Kenzior 1f45e1ed37 Fix make distcheck - gisi/modem.h
gisi/modem.h was not included in Makefile.am
2009-08-19 20:32:49 -05:00
Denis Kenzior b0009732dd Fix make distcheck
isicommon.h is no longer in the repository
2009-08-19 20:29:56 -05:00
Rémi Denis-Courmont a0973098a4 gisi: fix pipe create request endianess problems 2009-08-19 18:16:07 +03:00
Rémi Denis-Courmont 75f8148ab5 gisi: bind pipe end point *before* getting its handle 2009-08-19 18:16:06 +03:00
Rémi Denis-Courmont 5b0fffe66a Phonet: GPRS pipe end point low-level support 2009-08-19 17:07:16 +03:00
Rémi Denis-Courmont cf88062682 Phonet: missing SOL_PNPIPE definition 2009-08-19 17:07:16 +03:00
Rémi Denis-Courmont f32be53cd0 Phonet: add error handling for pipes 2009-08-19 17:07:15 +03:00
Rémi Denis-Courmont fa3c5f5ee1 Phonet: add modem parameter to ISI pipe API 2009-08-19 17:07:15 +03:00
Rémi Denis-Courmont 5e2a1745fb Phonet: add modem parameter to ISI client API 2009-08-19 17:07:15 +03:00
Rémi Denis-Courmont 20f73898ec gisi: provide modem identifier through Netlink API 2009-08-19 17:07:15 +03:00
Rémi Denis-Courmont ffcbb25105 gisi: warn if GIsiModem is missing rather than fail 2009-08-19 17:07:15 +03:00
Rémi Denis-Courmont b2ee53a99f gisi: low-level modem scoping for sockets 2009-08-19 17:07:15 +03:00
Rémi Denis-Courmont 2bfe1a24b9 Phonet: basic pipe owner support
This will be needed for GPRS support.
2009-08-14 16:56:52 +03:00
Rémi Denis-Courmont 360fd4b43b gisi: malloc -> free 2009-07-07 13:25:15 +03:00
Rémi Denis-Courmont a8138acce5 gisi: call to non existent function 2009-07-06 10:44:40 +03:00
Rémi Denis-Courmont 073261e507 Use phonet.h 2009-07-03 08:47:26 -07:00
Rémi Denis-Courmont e34e16b341 Replacement header for Phonet definitions 2009-07-03 08:32:14 -07:00
Rémi Denis-Courmont 6a2dd31a89 gisi: fix extracting Phonet address from Netlink 2009-06-29 21:03:09 +03:00
Aki Niemi 490840e011 gisi: Fix documentation and add API for resource ID 2009-06-25 09:42:06 +03:00
Aki Niemi 127b56bacc gisi: fix g_pn_netlink_start() return value 2009-06-24 13:21:32 +03:00
Aki Niemi 94f1fce8ee Add GISI_* build variables; remove unnecessary curly brackets 2009-06-22 21:43:56 +03:00
Aki Niemi f2f0fd0501 gisi: fixes to request/response handling and timeout registration 2009-06-22 21:17:14 +03:00
Rémi Denis-Courmont 841060da24 gisi: specify destination socket address
Kernel wants it, and returns an error on send otherwise.
2009-06-22 17:39:35 +03:00
Aki Niemi ede04ed8ca Fix to use negative error return in gisi/client.c 2009-06-15 11:33:34 +03:00
Aki Niemi e5f0290ddb Rename ISI client and PhoNet netlink APIs
- Add g_ prefix to functions
- Add G-prefix and use CamelCasing in types
2009-06-15 11:27:16 +03:00