From d1d6d441ff9b794477b693543ba7579f1491de58 Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Sun, 6 Dec 2009 10:45:04 +0100 Subject: [PATCH] Remove unused device specific connect/disconnect callbacks --- include/device.h | 4 ---- src/connman.h | 1 - src/device.c | 16 ---------------- 3 files changed, 21 deletions(-) diff --git a/include/device.h b/include/device.h index de2b2d6..9f12685 100644 --- a/include/device.h +++ b/include/device.h @@ -124,11 +124,7 @@ struct connman_device_driver { void (*remove) (struct connman_device *device); int (*enable) (struct connman_device *device); int (*disable) (struct connman_device *device); - int (*connect) (struct connman_device *device); - int (*disconnect) (struct connman_device *device); int (*scan) (struct connman_device *device); - int (*join) (struct connman_device *device, - struct connman_network *network); }; int connman_device_driver_register(struct connman_device_driver *driver); diff --git a/src/connman.h b/src/connman.h index 7f42a12..dba37d6 100644 --- a/src/connman.h +++ b/src/connman.h @@ -267,7 +267,6 @@ int __connman_device_enable(struct connman_device *device); int __connman_device_enable_persistent(struct connman_device *device); int __connman_device_disable(struct connman_device *device); int __connman_device_disable_persistent(struct connman_device *device); -int __connman_device_connect(struct connman_device *device); int __connman_device_disconnect(struct connman_device *device); connman_bool_t __connman_device_has_driver(struct connman_device *device); diff --git a/src/device.c b/src/device.c index f11ecf4..8d0f00a 100644 --- a/src/device.c +++ b/src/device.c @@ -1236,19 +1236,6 @@ int __connman_device_disable_persistent(struct connman_device *device) return __connman_device_disable(device); } -int __connman_device_connect(struct connman_device *device) -{ - DBG("device %p", device); - - if (device->disconnected == FALSE) - return -EINVAL; - - if (device->driver && device->driver->connect) - device->driver->connect(device); - - return 0; -} - int __connman_device_disconnect(struct connman_device *device) { GHashTableIter iter; @@ -1282,9 +1269,6 @@ int __connman_device_disconnect(struct connman_device *device) __connman_network_disconnect(network); } - if (device->driver && device->driver->disconnect) - device->driver->disconnect(device); - return 0; } -- 2.7.4