summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorDenis Kenzior <denkenz@gmail.com>2012-06-16 08:10:55 -0500
committerDenis Kenzior <denkenz@gmail.com>2012-06-16 09:50:05 -0500
commit6c7cf451a4ad047702b214f0c7f409975328260e (patch)
treeefe3ea9405b43f9d2bfd55bf3d16f7fbdeeab637 /include
parent13a5df6c59c477220138974fa6fe1f495fdc058b (diff)
downloadofono-6c7cf451a4ad047702b214f0c7f409975328260e.tar.bz2
modem: Conform to coding style item M9
Diffstat (limited to 'include')
-rw-r--r--include/modem.h68
1 files changed, 34 insertions, 34 deletions
diff --git a/include/modem.h b/include/modem.h
index 4efb2da9..87c84414 100644
--- a/include/modem.h
+++ b/include/modem.h
@@ -36,6 +36,40 @@ enum ofono_modem_type {
OFONO_MODEM_TYPE_SAP,
};
+typedef void (*ofono_modem_online_cb_t)(const struct ofono_error *error,
+ void *data);
+
+struct ofono_modem_driver {
+ const char *name;
+ enum ofono_modem_type modem_type;
+
+ /* Detect existence of device and initialize any device-specific data
+ * structures */
+ int (*probe)(struct ofono_modem *modem);
+
+ /* Destroy data structures allocated during probe and cleanup */
+ void (*remove)(struct ofono_modem *modem);
+
+ /* Power up device */
+ int (*enable)(struct ofono_modem *modem);
+
+ /* Power down device */
+ int (*disable)(struct ofono_modem *modem);
+
+ /* Enable or disable cellular radio */
+ void (*set_online)(struct ofono_modem *modem, ofono_bool_t online,
+ ofono_modem_online_cb_t callback, void *data);
+
+ /* Populate the atoms available without SIM / Locked SIM */
+ void (*pre_sim)(struct ofono_modem *modem);
+
+ /* Populate the atoms that are available with SIM / Unlocked SIM*/
+ void (*post_sim)(struct ofono_modem *modem);
+
+ /* Populate the atoms available online */
+ void (*post_online)(struct ofono_modem *modem);
+};
+
void ofono_modem_add_interface(struct ofono_modem *modem,
const char *interface);
void ofono_modem_remove_interface(struct ofono_modem *modem,
@@ -77,40 +111,6 @@ int ofono_modem_set_boolean(struct ofono_modem *modem,
ofono_bool_t ofono_modem_get_boolean(struct ofono_modem *modem,
const char *key);
-typedef void (*ofono_modem_online_cb_t)(const struct ofono_error *error,
- void *data);
-
-struct ofono_modem_driver {
- const char *name;
- enum ofono_modem_type modem_type;
-
- /* Detect existence of device and initialize any device-specific data
- * structures */
- int (*probe)(struct ofono_modem *modem);
-
- /* Destroy data structures allocated during probe and cleanup */
- void (*remove)(struct ofono_modem *modem);
-
- /* Power up device */
- int (*enable)(struct ofono_modem *modem);
-
- /* Power down device */
- int (*disable)(struct ofono_modem *modem);
-
- /* Enable or disable cellular radio */
- void (*set_online)(struct ofono_modem *modem, ofono_bool_t online,
- ofono_modem_online_cb_t callback, void *data);
-
- /* Populate the atoms available without SIM / Locked SIM */
- void (*pre_sim)(struct ofono_modem *modem);
-
- /* Populate the atoms that are available with SIM / Unlocked SIM*/
- void (*post_sim)(struct ofono_modem *modem);
-
- /* Populate the atoms available online */
- void (*post_online)(struct ofono_modem *modem);
-};
-
int ofono_modem_driver_register(const struct ofono_modem_driver *);
void ofono_modem_driver_unregister(const struct ofono_modem_driver *);