---
 drivers/qmimodem/util.h | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/drivers/qmimodem/util.h b/drivers/qmimodem/util.h
index cf053f0fe840..974160234af5 100644
--- a/drivers/qmimodem/util.h
+++ b/drivers/qmimodem/util.h
@@ -39,6 +39,15 @@ static inline struct cb_data *cb_data_new(void *cb, void 
*data)
        return ret;
 }
 
+#define CALLBACK_WITH_CME_ERROR(cb, err, args...)      \
+       do {                                            \
+               struct ofono_error cb_e;                \
+               cb_e.type = OFONO_ERROR_TYPE_CME;       \
+               cb_e.error = err;                       \
+                                                       \
+               cb(&cb_e, ##args);                      \
+       } while (0)                                     \
+
 #define CALLBACK_WITH_FAILURE(cb, args...)             \
        do {                                            \
                struct ofono_error cb_e;                \
-- 
2.15.1

_______________________________________________
ofono mailing list
[email protected]
https://lists.ofono.org/mailman/listinfo/ofono

Reply via email to