qmimodem: Add support for network registration handling
[platform/upstream/ofono.git] / drivers / qmimodem / qmimodem.c
1 /*
2  *
3  *  oFono - Open Source Telephony
4  *
5  *  Copyright (C) 2011-2012  Intel Corporation. All rights reserved.
6  *
7  *  This program is free software; you can redistribute it and/or modify
8  *  it under the terms of the GNU General Public License version 2 as
9  *  published by the Free Software Foundation.
10  *
11  *  This program is distributed in the hope that it will be useful,
12  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  *  GNU General Public License for more details.
15  *
16  *  You should have received a copy of the GNU General Public License
17  *  along with this program; if not, write to the Free Software
18  *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
19  *
20  */
21
22 #ifdef HAVE_CONFIG_H
23 #include <config.h>
24 #endif
25
26 #define OFONO_API_SUBJECT_TO_CHANGE
27 #include <ofono/plugin.h>
28
29 #include "qmimodem.h"
30
31 static int qmimodem_init(void)
32 {
33         qmi_devinfo_init();
34         qmi_netreg_init();
35         qmi_sim_legacy_init();
36
37         return 0;
38 }
39
40 static void qmimodem_exit(void)
41 {
42         qmi_sim_legacy_exit();
43         qmi_netreg_exit();
44         qmi_devinfo_exit();
45 }
46
47 OFONO_PLUGIN_DEFINE(qmimodem, "Qualcomm QMI modem driver", VERSION,
48                 OFONO_PLUGIN_PRIORITY_DEFAULT, qmimodem_init, qmimodem_exit)