summaryrefslogtreecommitdiffstats
path: root/src/simutil.c
diff options
context:
space:
mode:
authorYang Gu <yang.gu@intel.com>2010-08-19 14:05:35 +0800
committerDenis Kenzior <denkenz@gmail.com>2010-08-23 14:29:21 -0500
commitc679babdc5c288a02bea8ff095e9ecccbe8b693a (patch)
tree7219dc91c02a325e9519d6428a265f03377a5746 /src/simutil.c
parent8ca72b9706103d82f06e67da6a0ff5982d0eaf1c (diff)
downloadofono-c679babdc5c288a02bea8ff095e9ecccbe8b693a.tar.bz2
sim: Read EFust and EFest
Diffstat (limited to 'src/simutil.c')
-rw-r--r--src/simutil.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/simutil.c b/src/simutil.c
index 4b49b006..2d0764cc 100644
--- a/src/simutil.c
+++ b/src/simutil.c
@@ -1416,3 +1416,21 @@ gboolean sim_parse_2g_get_response(const unsigned char *response, int len,
return TRUE;
}
+
+gboolean sim_ust_is_available(unsigned char *efust, unsigned char len,
+ enum sim_ust_service index)
+{
+ if (index >= len * 8)
+ return FALSE;
+
+ return (efust[index / 8] >> (index % 8)) & 1;
+}
+
+gboolean sim_est_is_active(unsigned char *efest, unsigned char len,
+ enum sim_est_service index)
+{
+ if (index >= len * 8)
+ return FALSE;
+
+ return (efest[index / 8] >> (index % 8)) & 1;
+}