diff options
author | Seonah Moon <seonah1.moon@samsung.com> | 2018-01-08 13:42:54 +0900 |
---|---|---|
committer | Seonah Moon <seonah1.moon@samsung.com> | 2018-01-08 13:43:31 +0900 |
commit | 9362752a471a5c892d679548fbf2828d5fc5684b (patch) | |
tree | 83c7d29a28556906938f5c2198d81e2d35f86f92 /include | |
parent | 22633ced6225d294ce8483efbf2b39ea0c0c1b65 (diff) | |
download | connman-9362752a471a5c892d679548fbf2828d5fc5684b.tar.gz connman-9362752a471a5c892d679548fbf2828d5fc5684b.tar.bz2 connman-9362752a471a5c892d679548fbf2828d5fc5684b.zip |
Imported Upstream version 1.35upstream/1.35
Change-Id: I174854914d9fd06a813270b57d1f7bc2bac63c6a
Signed-off-by: Seonah Moon <seonah1.moon@samsung.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/backtrace.h | 32 | ||||
-rw-r--r-- | include/device.h | 4 | ||||
-rw-r--r-- | include/network.h | 1 | ||||
-rw-r--r-- | include/provider.h | 3 | ||||
-rw-r--r-- | include/resolver.h | 2 | ||||
-rw-r--r-- | include/service.h | 2 | ||||
-rw-r--r-- | include/session.h | 14 | ||||
-rw-r--r-- | include/technology.h | 2 |
8 files changed, 52 insertions, 8 deletions
diff --git a/include/backtrace.h b/include/backtrace.h new file mode 100644 index 00000000..12a202d7 --- /dev/null +++ b/include/backtrace.h @@ -0,0 +1,32 @@ +/* + * + * Connection Manager + * + * Copyright (C) 2016 Yann E. MORIN <yann.morin.1998@free.fr>. 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 + * + */ + +#ifndef __CONNMAN_BACKTRACE_H +#define __CONNMAN_BACKTRACE_H + +#ifdef HAVE_EXECINFO_H +void print_backtrace(const char* program_path, const char* program_exec, + unsigned int offset); +#else +#define print_backtrace(P,E,O) +#endif + +#endif /* __CONNMAN_BACKTRACE_H */ diff --git a/include/device.h b/include/device.h index 57b925c4..9ac800a2 100644 --- a/include/device.h +++ b/include/device.h @@ -85,10 +85,6 @@ int connman_device_set_scanning(struct connman_device *device, bool connman_device_get_scanning(struct connman_device *device); void connman_device_reset_scanning(struct connman_device *device); -int connman_device_set_disconnected(struct connman_device *device, - bool disconnected); -bool connman_device_get_disconnected(struct connman_device *device); - int connman_device_set_string(struct connman_device *device, const char *key, const char *value); const char *connman_device_get_string(struct connman_device *device, diff --git a/include/network.h b/include/network.h index d772699b..4fc20c1c 100644 --- a/include/network.h +++ b/include/network.h @@ -55,6 +55,7 @@ enum connman_network_error { CONNMAN_NETWORK_ERROR_CONFIGURE_FAIL = 2, CONNMAN_NETWORK_ERROR_INVALID_KEY = 3, CONNMAN_NETWORK_ERROR_CONNECT_FAIL = 4, + CONNMAN_NETWORK_ERROR_BLOCKED = 5, }; #define CONNMAN_NETWORK_PRIORITY_LOW -100 diff --git a/include/provider.h b/include/provider.h index d1a8983b..d28651ad 100644 --- a/include/provider.h +++ b/include/provider.h @@ -124,7 +124,8 @@ struct connman_provider_driver { enum connman_provider_type type; int (*probe) (struct connman_provider *provider); int (*remove) (struct connman_provider *provider); - int (*connect) (struct connman_provider *provider); + int (*connect) (struct connman_provider *provider, + const char *dbus_sender); int (*disconnect) (struct connman_provider *provider); int (*save) (struct connman_provider *provider, GKeyFile *keyfile); int (*set_property) (struct connman_provider *provider, diff --git a/include/resolver.h b/include/resolver.h index 57cb2870..70a02ade 100644 --- a/include/resolver.h +++ b/include/resolver.h @@ -40,8 +40,6 @@ int connman_resolver_remove(int index, const char *domain, const char *server); int connman_resolver_remove_all(int index); -void connman_resolver_flush(void); - #ifdef __cplusplus } #endif diff --git a/include/service.h b/include/service.h index 31dfce7e..958e7fd1 100644 --- a/include/service.h +++ b/include/service.h @@ -79,6 +79,7 @@ enum connman_service_error { CONNMAN_SERVICE_ERROR_LOGIN_FAILED = 5, CONNMAN_SERVICE_ERROR_AUTH_FAILED = 6, CONNMAN_SERVICE_ERROR_INVALID_KEY = 7, + CONNMAN_SERVICE_ERROR_BLOCKED = 8, }; enum connman_service_proxy_method { @@ -129,6 +130,7 @@ bool connman_service_get_favorite(struct connman_service *service); bool connman_service_get_autoconnect(struct connman_service *service); struct connman_service *connman_service_lookup_from_network(struct connman_network *network); +struct connman_service *connman_service_lookup_from_identifier(const char* identifier); void connman_service_create_ip4config(struct connman_service *service, int index); diff --git a/include/session.h b/include/session.h index 37dfc4e4..5106e886 100644 --- a/include/session.h +++ b/include/session.h @@ -22,6 +22,7 @@ #ifndef __CONNMAN_SESSION_H #define __CONNMAN_SESSION_H +#include <stdint.h> #include <connman/service.h> #ifdef __cplusplus @@ -55,6 +56,12 @@ enum connman_session_id_type { CONNMAN_SESSION_ID_TYPE_LSM = 3, }; +enum connman_session_state { + CONNMAN_SESSION_STATE_DISCONNECTED = 0, + CONNMAN_SESSION_STATE_CONNECTED = 1, + CONNMAN_SESSION_STATE_ONLINE = 2, +}; + struct connman_session; struct connman_session_config { @@ -65,6 +72,8 @@ struct connman_session_config { enum connman_session_type type; bool ecall; GSList *allowed_bearers; + char *allowed_interface; + bool source_ip_rule; }; typedef int (* connman_session_config_func_t) (struct connman_session *session, @@ -83,8 +92,13 @@ struct connman_session_policy { GSList *bearers); bool (*allowed)(struct connman_session *session, struct connman_service *service); + void (*update_session_state)(struct connman_session* session, + enum connman_session_state state); + struct connman_service* (*get_service_for_session)(struct connman_session* session, + GSList* services); }; +uint32_t connman_session_firewall_get_fwmark(struct connman_session *session); int connman_session_policy_register(struct connman_session_policy *config); void connman_session_policy_unregister(struct connman_session_policy *config); diff --git a/include/technology.h b/include/technology.h index d7fcdde2..97db6607 100644 --- a/include/technology.h +++ b/include/technology.h @@ -36,7 +36,7 @@ extern "C" { struct connman_technology; -void connman_technology_tethering_notify(struct connman_technology *technology, +int connman_technology_tethering_notify(struct connman_technology *technology, bool enabled); int connman_technology_set_regdom(const char *alpha2); void connman_technology_regdom_notify(struct connman_technology *technology, |