Remove failed attempt to integrate with ModemManager
authorMarcel Holtmann <marcel@holtmann.org>
Sun, 6 Dec 2009 23:29:04 +0000 (00:29 +0100)
committerMarcel Holtmann <marcel@holtmann.org>
Sun, 6 Dec 2009 23:29:04 +0000 (00:29 +0100)
Makefile.plugins
bootstrap-configure
configure.ac
plugins/modemmgr.c [deleted file]

index 93abe89080b5fceaad223a218906d3ebc3765de6..d774720f7c7a47cccfd2d139977a1fb344b58d16 100644 (file)
@@ -75,18 +75,6 @@ plugins_ofono_la_LDFLAGS = $(plugin_ldflags)
 endif
 endif
 
-if MODEMMGR
-if MODEMMGR_BUILTIN
-builtin_modules += modemmgr
-builtin_sources += plugins/modemmgr.c
-else
-plugin_LTLIBRARIES += plugins/modemmgr.la
-plugin_objects += $(plugins_modemmgr_la_OBJECTS)
-plugins_modemmgr_la_CFLAGS = $(plugin_cflags)
-plugins_modemmgr_la_LDFLAGS = $(plugin_ldflags)
-endif
-endif
-
 if HSO
 if HSO_BUILTIN
 builtin_modules += hso
index c14b420f9277055189c6e702cbd4ef52bf46dea1..c6ae4eb0725167bacda12f6a597d00770d388582 100755 (executable)
@@ -21,7 +21,6 @@ fi
                --enable-wifi=builtin \
                --enable-bluetooth=builtin \
                --enable-ofono=builtin \
-               --enable-modemmgr=builtin \
                --enable-udhcp=builtin \
                --enable-dhclient=builtin \
                --enable-resolvconf=builtin \
index e774687f4e566a18bf4889385e5061272286ecf4..b7e443c0e6dffab568f8e4262d4c6962b9bbc2c9 100644 (file)
@@ -92,12 +92,6 @@ AC_ARG_ENABLE(ofono,
 AM_CONDITIONAL(OFONO, test "${enable_ofono}" != "no")
 AM_CONDITIONAL(OFONO_BUILTIN, test "${enable_ofono}" = "builtin")
 
-AC_ARG_ENABLE(modemmgr,
-       AC_HELP_STRING([--enable-modemmgr], [enable Modem Manager support]),
-                       [enable_modemmgr=${enableval}], [enable_modemmgr="no"])
-AM_CONDITIONAL(MODEMMGR, test "${enable_modemmgr}" != "no")
-AM_CONDITIONAL(MODEMMGR_BUILTIN, test "${enable_modemmgr}" = "builtin")
-
 AC_ARG_WITH(udhcpc, AC_HELP_STRING([--with-udhcpc=PROGRAM],
        [specify location of udhcpc binary]), [path_udhcpc=${withval}])
 
diff --git a/plugins/modemmgr.c b/plugins/modemmgr.c
deleted file mode 100644 (file)
index 0950848..0000000
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- *
- *  Connection Manager
- *
- *  Copyright (C) 2007-2009  Intel Corporation. All rights reserved.
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License version 2 as
- *  published by the Free Software Foundation.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
- *
- */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <errno.h>
-
-#include <gdbus.h>
-
-#define CONNMAN_API_SUBJECT_TO_CHANGE
-#include <connman/plugin.h>
-#include <connman/dbus.h>
-#include <connman/log.h>
-
-#define MODEMMGR_SERVICE       "org.freedesktop.ModemManager"
-#define MODEMMGR_INTERFACE     MODEMMGR_SERVICE
-
-#define ENUMERATE_DEVICES      "EnumerateDevices"
-
-#define TIMEOUT 5000
-
-static void enumerate_devices_reply(DBusPendingCall *call, void *user_data)
-{
-       DBusMessage *reply;
-
-       DBG("");
-
-       reply = dbus_pending_call_steal_reply(call);
-
-       dbus_message_unref(reply);
-}
-
-static void modemmgr_connect(DBusConnection *connection, void *user_data)
-{
-       DBusMessage *message;
-       DBusPendingCall *call;
-
-       DBG("connection %p", connection);
-
-       message = dbus_message_new_method_call(MODEMMGR_SERVICE, "/",
-                               MODEMMGR_INTERFACE, ENUMERATE_DEVICES);
-       if (message == NULL)
-               return;
-
-       if (dbus_connection_send_with_reply(connection, message,
-                                               &call, TIMEOUT) == FALSE) {
-               connman_error("Failed to get modem devices");
-               goto done;
-       }
-
-       if (call == NULL) {
-               connman_error("D-Bus connection not available");
-               goto done;
-       }
-
-       dbus_pending_call_set_notify(call, enumerate_devices_reply,
-                                                       NULL, NULL);
-
-done:
-       dbus_message_unref(message);
-}
-
-static void modemmgr_disconnect(DBusConnection *connection, void *user_data)
-{
-       DBG("connection %p", connection);
-}
-
-static DBusConnection *connection;
-static guint watch;
-
-static int modemmgr_init(void)
-{
-       connection = connman_dbus_get_connection();
-       if (connection == NULL)
-               return -EIO;
-
-       watch = g_dbus_add_service_watch(connection, MODEMMGR_SERVICE,
-                       modemmgr_connect, modemmgr_disconnect, NULL, NULL);
-       if (watch == 0) {
-               dbus_connection_unref(connection);
-               return -EIO;
-       }
-
-       return 0;
-}
-
-static void modemmgr_exit(void)
-{
-       g_dbus_remove_watch(connection, watch);
-
-       dbus_connection_unref(connection);
-}
-
-CONNMAN_PLUGIN_DEFINE(modemmgr, "Modem Manager plugin", VERSION,
-               CONNMAN_PLUGIN_PRIORITY_DEFAULT, modemmgr_init, modemmgr_exit)