From f09dc3e887bf0946975c1e78f01921827117ba50 Mon Sep 17 00:00:00 2001 From: tick Date: Mon, 3 Dec 2007 07:08:22 +0000 Subject: gsmd: Rewrite read, readrg and find of phonebook. (Sean Chiang) git-svn-id: http://svn.openmoko.org/trunk/src/target/gsm@3551 99fdad57-331a-0410-800a-d7fa5415bdb3 --- include/gsmd/gsmd.h | 3 --- include/gsmd/usock.h | 14 ++++++-------- 2 files changed, 6 insertions(+), 11 deletions(-) (limited to 'include') diff --git a/include/gsmd/gsmd.h b/include/gsmd/gsmd.h index 5b2a9e6..de99238 100644 --- a/include/gsmd/gsmd.h +++ b/include/gsmd/gsmd.h @@ -98,9 +98,6 @@ struct gsmd_user { struct gsmd *gsmd; struct gsmd_fd gfd; /* the socket */ u_int32_t subscriptions; /* bitmaks of subscribed event groups */ - - struct llist_head pb_readrg_list; /* our READRG phonebook list */ - struct llist_head pb_find_list; /* our FIND phonebook list */ }; #define GSMD_DEBUG 1 /* debugging information */ diff --git a/include/gsmd/usock.h b/include/gsmd/usock.h index a4e5e41..4f1da7a 100644 --- a/include/gsmd/usock.h +++ b/include/gsmd/usock.h @@ -254,8 +254,6 @@ enum gsmd_msg_phonebook { GSMD_PHONEBOOK_GET_SUPPORT = 6, GSMD_PHONEBOOK_LIST_STORAGE = 7, GSMD_PHONEBOOK_SET_STORAGE = 8, - GSMD_PHONEBOOK_RETRIEVE_READRG = 9, - GSMD_PHONEBOOK_RETRIEVE_FIND = 10, }; /* Type-of-Address, Numbering-Plan-Identification field, GSM 03.40, 9.1.2.5 */ @@ -496,12 +494,17 @@ struct gsmd_phonebook_readrg { #define GSMD_PB_NUMB_MAXLEN 44 #define GSMD_PB_TEXT_MAXLEN 14 struct gsmd_phonebook { - u_int8_t index; + int8_t index; char numb[GSMD_PB_NUMB_MAXLEN+1]; u_int8_t type; char text[GSMD_PB_TEXT_MAXLEN+1]; } __attribute__ ((packed)); +struct gsmd_phonebooks { + struct gsmd_phonebook pb; + int8_t is_last; +} __attribute__ ((packed)); + /* Refer to GSM 07.07 subclause 8.13 */ /* FIXME: the tlength depends on SIM, use +CPBR=? to get */ struct gsmd_phonebook_find { @@ -610,11 +613,6 @@ struct gsmd_ucmd { char buf[]; } __attribute__ ((packed)); -struct gsmd_phonebooks { - struct llist_head list; - struct gsmd_phonebook pb; -} __attribute__ ((packed)); - extern struct gsmd_ucmd *ucmd_alloc(int extra_size); extern int usock_init(struct gsmd *g); extern void usock_cmd_enqueue(struct gsmd_ucmd *ucmd, struct gsmd_user *gu); -- cgit v1.2.3