diff options
Diffstat (limited to 'src/devices/wimax')
| -rw-r--r-- | src/devices/wimax/Makefile.am | 12 | ||||
| -rw-r--r-- | src/devices/wimax/Makefile.in | 18 | ||||
| -rw-r--r-- | src/devices/wimax/exports.ver | 1 | ||||
| -rw-r--r-- | src/devices/wimax/iwmxsdk.c | 10 | ||||
| -rw-r--r-- | src/devices/wimax/iwmxsdk.h | 9 | ||||
| -rw-r--r-- | src/devices/wimax/nm-device-wimax.c | 132 | ||||
| -rw-r--r-- | src/devices/wimax/nm-device-wimax.h | 13 | ||||
| -rw-r--r-- | src/devices/wimax/nm-wimax-factory.c | 18 | ||||
| -rw-r--r-- | src/devices/wimax/nm-wimax-nsp.c | 33 | ||||
| -rw-r--r-- | src/devices/wimax/nm-wimax-nsp.h | 4 | ||||
| -rw-r--r-- | src/devices/wimax/nm-wimax-types.h | 4 | ||||
| -rw-r--r-- | src/devices/wimax/nm-wimax-util.c | 3 | ||||
| -rw-r--r-- | src/devices/wimax/nm-wimax-util.h | 9 |
13 files changed, 117 insertions, 149 deletions
diff --git a/src/devices/wimax/Makefile.am b/src/devices/wimax/Makefile.am index def8bf62..555b5ff2 100644 --- a/src/devices/wimax/Makefile.am +++ b/src/devices/wimax/Makefile.am @@ -1,20 +1,16 @@ AM_CPPFLAGS = \ -I${top_srcdir}/src \ -I${top_builddir}/src \ - -I${top_srcdir}/src/logging \ -I${top_srcdir}/src/devices \ -I${top_srcdir}/src/platform \ - -I${top_builddir}/include \ -I${top_srcdir}/include \ - -I${top_builddir}/libnm-util \ - -I${top_srcdir}/libnm-util \ + -I${top_builddir}/libnm-core \ + -I${top_srcdir}/libnm-core \ -DG_LOG_DOMAIN=\""NetworkManager-wimax"\" \ + -DNETWORKMANAGER_COMPILATION \ -DNM_VERSION_MAX_ALLOWED=NM_VERSION_NEXT_STABLE \ $(DBUS_CFLAGS) \ - $(POLKIT_CFLAGS) \ - $(IWMX_SDK_CFLAGS) \ - $(LIBNL_CFLAGS) \ - $(GUDEV_CFLAGS) + $(IWMX_SDK_CFLAGS) pkglib_LTLIBRARIES = libnm-device-plugin-wimax.la diff --git a/src/devices/wimax/Makefile.in b/src/devices/wimax/Makefile.in index ba16d277..f1ffb09c 100644 --- a/src/devices/wimax/Makefile.in +++ b/src/devices/wimax/Makefile.in @@ -215,6 +215,8 @@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ +BLUEZ5_CFLAGS = @BLUEZ5_CFLAGS@ +BLUEZ5_LIBS = @BLUEZ5_LIBS@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ @@ -338,6 +340,7 @@ NEWT_CFLAGS = @NEWT_CFLAGS@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ +NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ NM_MICRO_VERSION = @NM_MICRO_VERSION@ NM_MINOR_VERSION = @NM_MINOR_VERSION@ @@ -357,6 +360,7 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ +PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ @@ -383,7 +387,7 @@ SYSTEMD_INHIBIT_LIBS = @SYSTEMD_INHIBIT_LIBS@ SYSTEMD_LOGIN_CFLAGS = @SYSTEMD_LOGIN_CFLAGS@ SYSTEMD_LOGIN_LIBS = @SYSTEMD_LOGIN_LIBS@ SYSTEM_CA_PATH = @SYSTEM_CA_PATH@ -UDEV_BASE_DIR = @UDEV_BASE_DIR@ +UDEV_DIR = @UDEV_DIR@ USE_NLS = @USE_NLS@ UUID_CFLAGS = @UUID_CFLAGS@ UUID_LIBS = @UUID_LIBS@ @@ -465,20 +469,16 @@ with_valgrind = @with_valgrind@ AM_CPPFLAGS = \ -I${top_srcdir}/src \ -I${top_builddir}/src \ - -I${top_srcdir}/src/logging \ -I${top_srcdir}/src/devices \ -I${top_srcdir}/src/platform \ - -I${top_builddir}/include \ -I${top_srcdir}/include \ - -I${top_builddir}/libnm-util \ - -I${top_srcdir}/libnm-util \ + -I${top_builddir}/libnm-core \ + -I${top_srcdir}/libnm-core \ -DG_LOG_DOMAIN=\""NetworkManager-wimax"\" \ + -DNETWORKMANAGER_COMPILATION \ -DNM_VERSION_MAX_ALLOWED=NM_VERSION_NEXT_STABLE \ $(DBUS_CFLAGS) \ - $(POLKIT_CFLAGS) \ - $(IWMX_SDK_CFLAGS) \ - $(LIBNL_CFLAGS) \ - $(GUDEV_CFLAGS) + $(IWMX_SDK_CFLAGS) pkglib_LTLIBRARIES = libnm-device-plugin-wimax.la SYMBOL_VIS_FILE = $(srcdir)/exports.ver diff --git a/src/devices/wimax/exports.ver b/src/devices/wimax/exports.ver index d2c45124..24cd848c 100644 --- a/src/devices/wimax/exports.ver +++ b/src/devices/wimax/exports.ver @@ -1,7 +1,6 @@ { global: nm_device_factory_create; - nm_device_factory_get_device_type; local: *; }; diff --git a/src/devices/wimax/iwmxsdk.c b/src/devices/wimax/iwmxsdk.c index d1ef7b68..1c2c6821 100644 --- a/src/devices/wimax/iwmxsdk.c +++ b/src/devices/wimax/iwmxsdk.c @@ -19,24 +19,22 @@ * */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif +#include "config.h" #include <stdio.h> #include <stdlib.h> #include <errno.h> #include <string.h> #include <sys/socket.h> -#include <linux/if.h> #include <glib.h> -#include <WiMaxType.h> +#include "nm-wimax-util.h" + #include <WiMaxAPI.h> #include <WiMaxAPIEx.h> -#include "logging/nm-logging.h" +#include "nm-logging.h" #include "iwmxsdk.h" static WIMAX_API_DEVICE_ID g_api; diff --git a/src/devices/wimax/iwmxsdk.h b/src/devices/wimax/iwmxsdk.h index 785ca8c2..c8e76696 100644 --- a/src/devices/wimax/iwmxsdk.h +++ b/src/devices/wimax/iwmxsdk.h @@ -19,10 +19,11 @@ * */ -#ifndef IWMXSDK_H -#define IWMXSDK_H +#ifndef __IWMXSDK_H__ +#define __IWMXSDK_H__ + +#include "nm-wimax-util.h" -#include <wimax/WiMaxType.h> #include <wimax/WiMaxTypesEx.h> #include <wimax/WiMaxAPIEx.h> @@ -108,4 +109,4 @@ int iwmx_sdk_get_networks(struct wmxsdk *wmxsdk); int iwmx_sdk_api_init(void); void iwmx_sdk_api_exit(void); -#endif /* IWMXSDK_H */ +#endif /* __IWMXSDK_H__ */ diff --git a/src/devices/wimax/nm-device-wimax.c b/src/devices/wimax/nm-device-wimax.c index 1bdda489..466cd979 100644 --- a/src/devices/wimax/nm-device-wimax.c +++ b/src/devices/wimax/nm-device-wimax.c @@ -19,14 +19,17 @@ * Copyright (C) 2009 Novell, Inc. */ +#include "config.h" + #include <stdlib.h> #include <string.h> #include <unistd.h> #include <sys/ioctl.h> -#include <net/ethernet.h> #include <sys/socket.h> -#include <linux/if.h> -#include <netinet/ether.h> + +#include <glib/gi18n.h> + +#include "nm-wimax-util.h" #include <WiMaxAPI.h> #include <WiMaxAPIEx.h> @@ -36,8 +39,10 @@ #include "nm-logging.h" #include "nm-device-private.h" #include "NetworkManagerUtils.h" +#include "nm-active-connection.h" #include "nm-dbus-manager.h" #include "nm-connection.h" +#include "nm-platform.h" #include "nm-setting-connection.h" #include "nm-setting-wimax.h" #include "nm-utils.h" @@ -110,19 +115,6 @@ typedef struct { /***********************************************************/ -#define NM_WIMAX_ERROR (nm_wimax_error_quark ()) - -static GQuark -nm_wimax_error_quark (void) -{ - static GQuark quark = 0; - if (!quark) - quark = g_quark_from_static_string ("nm-wimax-error"); - return quark; -} - -/***********************************************************/ - static gboolean impl_device_get_nsp_list (NMDeviceWimax *self, GPtrArray **nsps, GError **error) { @@ -316,7 +308,7 @@ check_connection_compatible (NMDevice *device, NMConnection *connection) NMSettingConnection *s_con; NMSettingWimax *s_wimax; const char *connection_type; - const GByteArray *mac; + const char *mac; if (!NM_DEVICE_CLASS (nm_device_wimax_parent_class)->check_connection_compatible (device, connection)) return FALSE; @@ -333,7 +325,7 @@ check_connection_compatible (NMDevice *device, NMConnection *connection) return FALSE; mac = nm_setting_wimax_get_mac_address (s_wimax); - if (mac && memcmp (mac->data, nm_device_get_hw_address (device, NULL), ETH_ALEN)) + if (mac && !nm_utils_hwaddr_matches (mac, -1, nm_device_get_hw_address (device), -1)) return FALSE; return TRUE; @@ -372,9 +364,8 @@ complete_connection (NMDevice *device, NMDeviceWimax *self = NM_DEVICE_WIMAX (device); NMDeviceWimaxPrivate *priv = NM_DEVICE_WIMAX_GET_PRIVATE (self); NMSettingWimax *s_wimax; - const GByteArray *setting_mac; - const guint8 *hw_address; - char *format; + const char *setting_mac; + const char *hw_address; const char *nsp_name = NULL; NMWimaxNsp *nsp = NULL; GSList *iter; @@ -385,8 +376,8 @@ complete_connection (NMDevice *device, /* If not given a specific object, we need at minimum an NSP name */ if (!s_wimax) { g_set_error_literal (error, - NM_WIMAX_ERROR, - NM_WIMAX_ERROR_CONNECTION_INVALID, + NM_DEVICE_ERROR, + NM_DEVICE_ERROR_INVALID_CONNECTION, "A 'wimax' setting is required if no NSP path was given."); return FALSE; } @@ -394,8 +385,8 @@ complete_connection (NMDevice *device, nsp_name = nm_setting_wimax_get_network_name (s_wimax); if (!nsp_name || !strlen (nsp_name)) { g_set_error_literal (error, - NM_WIMAX_ERROR, - NM_WIMAX_ERROR_CONNECTION_INVALID, + NM_DEVICE_ERROR, + NM_DEVICE_ERROR_INVALID_CONNECTION, "A 'wimax' setting with a valid network name is required if no NSP path was given."); return FALSE; } @@ -422,8 +413,8 @@ complete_connection (NMDevice *device, if (!nsp) { g_set_error (error, - NM_WIMAX_ERROR, - NM_WIMAX_ERROR_NSP_NOT_FOUND, + NM_DEVICE_ERROR, + NM_DEVICE_ERROR_SPECIFIC_OBJECT_NOT_FOUND, "The NSP %s was not in the scan list.", specific_object); return FALSE; @@ -439,38 +430,31 @@ complete_connection (NMDevice *device, } g_assert (nsp_name); - format = g_strdup_printf ("%s %%d", nsp_name); nm_utils_complete_generic (connection, NM_SETTING_WIMAX_SETTING_NAME, existing_connections, - format, nsp_name, + nsp_name, + NULL, TRUE); - g_free (format); g_object_set (G_OBJECT (s_wimax), NM_SETTING_WIMAX_NETWORK_NAME, nsp_name, NULL); setting_mac = nm_setting_wimax_get_mac_address (s_wimax); - hw_address = nm_device_get_hw_address (device, NULL); + hw_address = nm_device_get_hw_address (device); if (setting_mac) { /* Make sure the setting MAC (if any) matches the device's permanent MAC */ - if (memcmp (setting_mac->data, hw_address, ETH_ALEN)) { - g_set_error (error, - NM_SETTING_WIMAX_ERROR, - NM_SETTING_WIMAX_ERROR_INVALID_PROPERTY, - NM_SETTING_WIMAX_MAC_ADDRESS); + if (!nm_utils_hwaddr_matches (setting_mac, -1, hw_address, -1)) { + g_set_error_literal (error, + NM_CONNECTION_ERROR, + NM_CONNECTION_ERROR_INVALID_PROPERTY, + _("connection does not match device")); + g_prefix_error (error, "%s.%s: ", NM_SETTING_WIMAX_SETTING_NAME, NM_SETTING_WIMAX_MAC_ADDRESS); return FALSE; } } else { - GByteArray *mac; - const guint8 null_mac[ETH_ALEN] = { 0, 0, 0, 0, 0, 0 }; - /* Lock the connection to this device by default */ - if (memcmp (hw_address, null_mac, ETH_ALEN)) { - mac = g_byte_array_sized_new (ETH_ALEN); - g_byte_array_append (mac, hw_address, ETH_ALEN); - g_object_set (G_OBJECT (s_wimax), NM_SETTING_WIMAX_MAC_ADDRESS, mac, NULL); - g_byte_array_free (mac, TRUE); - } + if (!nm_utils_hwaddr_matches (hw_address, -1, NULL, ETH_ALEN)) + g_object_set (G_OBJECT (s_wimax), NM_SETTING_WIMAX_MAC_ADDRESS, hw_address, NULL); } return TRUE; @@ -1047,7 +1031,7 @@ set_link_status (NMDeviceWimax *self, WIMAX_API_LINK_STATUS_INFO_EX *link_status conv_rssi = sdk_rssi_to_dbm (link_status->RSSI); conv_cinr = sdk_cinr_to_db (link_status->CINR); conv_tx_pow = sdk_tx_pow_to_dbm (link_status->txPWR); - new_bsid = nm_utils_hwaddr_ntoa_len (link_status->bsId, 6); + new_bsid = nm_utils_hwaddr_ntoa (link_status->bsId, 6); } if (priv->center_freq != center_freq) { @@ -1363,58 +1347,52 @@ nm_device_wimax_class_init (NMDeviceWimaxClass *klass) /* Properties */ g_object_class_install_property (object_class, PROP_NSPS, - g_param_spec_boxed (NM_DEVICE_WIMAX_NSPS, - "Network access points", - "Network access points", + g_param_spec_boxed (NM_DEVICE_WIMAX_NSPS, "", "", DBUS_TYPE_G_ARRAY_OF_OBJECT_PATH, - G_PARAM_READABLE)); + G_PARAM_READABLE | + G_PARAM_STATIC_STRINGS)); - g_object_class_install_property (object_class, PROP_ACTIVE_NSP, - g_param_spec_boxed (NM_DEVICE_WIMAX_ACTIVE_NSP, - "Active NSP", - "Currently active NSP", - DBUS_TYPE_G_OBJECT_PATH, - G_PARAM_READABLE)); + g_object_class_install_property + (object_class, PROP_ACTIVE_NSP, + g_param_spec_boxed (NM_DEVICE_WIMAX_ACTIVE_NSP, "", "", + DBUS_TYPE_G_OBJECT_PATH, + G_PARAM_READABLE | + G_PARAM_STATIC_STRINGS)); g_object_class_install_property (object_class, PROP_CENTER_FREQ, - g_param_spec_uint (NM_DEVICE_WIMAX_CENTER_FREQUENCY, - "Center frequency", - "Center frequency", + g_param_spec_uint (NM_DEVICE_WIMAX_CENTER_FREQUENCY, "", "", 0, G_MAXUINT, 0, - G_PARAM_READABLE)); + G_PARAM_READABLE | + G_PARAM_STATIC_STRINGS)); g_object_class_install_property (object_class, PROP_RSSI, - g_param_spec_int (NM_DEVICE_WIMAX_RSSI, - "RSSI", - "RSSI", + g_param_spec_int (NM_DEVICE_WIMAX_RSSI, "", "", G_MININT, G_MAXINT, 0, - G_PARAM_READABLE)); + G_PARAM_READABLE | + G_PARAM_STATIC_STRINGS)); g_object_class_install_property (object_class, PROP_CINR, - g_param_spec_int (NM_DEVICE_WIMAX_CINR, - "CINR", - "CINR", + g_param_spec_int (NM_DEVICE_WIMAX_CINR, "", "", G_MININT, G_MAXINT, 0, - G_PARAM_READABLE)); + G_PARAM_READABLE | + G_PARAM_STATIC_STRINGS)); g_object_class_install_property (object_class, PROP_TX_POWER, - g_param_spec_int (NM_DEVICE_WIMAX_TX_POWER, - "TX Power", - "TX Power", + g_param_spec_int (NM_DEVICE_WIMAX_TX_POWER, "", "", G_MININT, G_MAXINT, 0, - G_PARAM_READABLE)); + G_PARAM_READABLE | + G_PARAM_STATIC_STRINGS)); g_object_class_install_property (object_class, PROP_BSID, - g_param_spec_string (NM_DEVICE_WIMAX_BSID, - "BSID", - "BSID", + g_param_spec_string (NM_DEVICE_WIMAX_BSID, "", "", NULL, - G_PARAM_READABLE)); + G_PARAM_READABLE | + G_PARAM_STATIC_STRINGS)); /* Signals */ signals[NSP_ADDED] = @@ -1440,6 +1418,4 @@ nm_device_wimax_class_init (NMDeviceWimaxClass *klass) nm_dbus_manager_register_exported_type (nm_dbus_manager_get (), G_TYPE_FROM_CLASS (klass), &dbus_glib_nm_device_wimax_object_info); - - dbus_g_error_domain_register (NM_WIMAX_ERROR, NULL, NM_TYPE_WIMAX_ERROR); } diff --git a/src/devices/wimax/nm-device-wimax.h b/src/devices/wimax/nm-device-wimax.h index 8b252ee1..30b2481f 100644 --- a/src/devices/wimax/nm-device-wimax.h +++ b/src/devices/wimax/nm-device-wimax.h @@ -19,10 +19,9 @@ * Copyright (C) 2009 Novell, Inc. */ -#ifndef NM_DEVICE_WIMAX_H -#define NM_DEVICE_WIMAX_H +#ifndef __NETWORKMANAGER_DEVICE_WIMAX_H__ +#define __NETWORKMANAGER_DEVICE_WIMAX_H__ -#include <net/ethernet.h> #include "nm-device.h" #include "nm-wimax-nsp.h" @@ -35,14 +34,6 @@ G_BEGIN_DECLS #define NM_IS_DEVICE_WIMAX_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), NM_TYPE_DEVICE_WIMAX)) #define NM_DEVICE_WIMAX_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), NM_TYPE_DEVICE_WIMAX, NMDeviceWimaxClass)) -typedef enum -{ - NM_WIMAX_ERROR_CONNECTION_NOT_WIMAX = 0, /*< nick=ConnectionNotWimax >*/ - NM_WIMAX_ERROR_CONNECTION_INVALID, /*< nick=ConnectionInvalid >*/ - NM_WIMAX_ERROR_CONNECTION_INCOMPATIBLE, /*< nick=ConnectionIncompatible >*/ - NM_WIMAX_ERROR_NSP_NOT_FOUND, /*< nick=NspNotFound >*/ -} NMWimaxError; - #define NM_DEVICE_WIMAX_NSPS "nsps" #define NM_DEVICE_WIMAX_ACTIVE_NSP "active-nsp" #define NM_DEVICE_WIMAX_CENTER_FREQUENCY "center-frequency" diff --git a/src/devices/wimax/nm-wimax-factory.c b/src/devices/wimax/nm-wimax-factory.c index ca962e68..39e9a287 100644 --- a/src/devices/wimax/nm-wimax-factory.c +++ b/src/devices/wimax/nm-wimax-factory.c @@ -18,10 +18,13 @@ * Copyright (C) 2011 - 2014 Red Hat, Inc. */ +#include "config.h" + #include <gmodule.h> #include "nm-device-factory.h" #include "nm-device-wimax.h" +#include "nm-platform.h" #define NM_TYPE_WIMAX_FACTORY (nm_wimax_factory_get_type ()) #define NM_WIMAX_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), NM_WIMAX_FACTORY, NMWimaxFactory)) @@ -43,20 +46,12 @@ G_DEFINE_TYPE_EXTENDED (NMWimaxFactory, nm_wimax_factory, G_TYPE_OBJECT, 0, /**************************************************************************/ -#define PLUGIN_TYPE NM_DEVICE_TYPE_WIMAX - G_MODULE_EXPORT NMDeviceFactory * nm_device_factory_create (GError **error) { return (NMDeviceFactory *) g_object_new (NM_TYPE_WIMAX_FACTORY, NULL); } -G_MODULE_EXPORT NMDeviceType -nm_device_factory_get_device_type (void) -{ - return PLUGIN_TYPE; -} - /**************************************************************************/ static NMDevice * @@ -71,10 +66,17 @@ new_link (NMDeviceFactory *factory, NMPlatformLink *plink, GError **error) return (NMDevice *) nm_device_wimax_new (plink); } +static NMDeviceType +get_device_type (NMDeviceFactory *factory) +{ + return NM_DEVICE_TYPE_WIMAX; +} + static void device_factory_interface_init (NMDeviceFactory *factory_iface) { factory_iface->new_link = new_link; + factory_iface->get_device_type = get_device_type; } static void diff --git a/src/devices/wimax/nm-wimax-nsp.c b/src/devices/wimax/nm-wimax-nsp.c index efe3b058..f4db63f0 100644 --- a/src/devices/wimax/nm-wimax-nsp.c +++ b/src/devices/wimax/nm-wimax-nsp.c @@ -19,8 +19,10 @@ * Copyright (C) 2009 Novell, Inc. */ +#include "config.h" + #include "nm-wimax-nsp.h" -#include "NetworkManager.h" +#include "nm-dbus-interface.h" #include "nm-dbus-manager.h" #include "nm-setting-wimax.h" #include "nm-wimax-nsp-glue.h" @@ -210,31 +212,28 @@ nm_wimax_nsp_class_init (NMWimaxNspClass *klass) g_object_class_install_property (object_class, PROP_NAME, - g_param_spec_string (NM_WIMAX_NSP_NAME, - "Name", - "Name", - NULL, - G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY)); + g_param_spec_string (NM_WIMAX_NSP_NAME, "", "", + NULL, + G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY | + G_PARAM_STATIC_STRINGS)); g_object_class_install_property (object_class, PROP_SIGNAL_QUALITY, - g_param_spec_uint (NM_WIMAX_NSP_SIGNAL_QUALITY, - "SignalQuality", - "SignalQuality", - 0, - 100, - 0, - G_PARAM_READWRITE)); + g_param_spec_uint (NM_WIMAX_NSP_SIGNAL_QUALITY, "", "", + 0, + 100, + 0, + G_PARAM_READWRITE | + G_PARAM_STATIC_STRINGS)); g_object_class_install_property (object_class, PROP_NETWORK_TYPE, - g_param_spec_uint (NM_WIMAX_NSP_NETWORK_TYPE, - "NetworkType", - "NetworkType", + g_param_spec_uint (NM_WIMAX_NSP_NETWORK_TYPE, "", "", NM_WIMAX_NSP_NETWORK_TYPE_UNKNOWN, NM_WIMAX_NSP_NETWORK_TYPE_ROAMING_PARTNER, NM_WIMAX_NSP_NETWORK_TYPE_UNKNOWN, - G_PARAM_READWRITE)); + G_PARAM_READWRITE | + G_PARAM_STATIC_STRINGS)); nm_dbus_manager_register_exported_type (nm_dbus_manager_get (), G_TYPE_FROM_CLASS (klass), diff --git a/src/devices/wimax/nm-wimax-nsp.h b/src/devices/wimax/nm-wimax-nsp.h index a74b68a7..8d0a6a14 100644 --- a/src/devices/wimax/nm-wimax-nsp.h +++ b/src/devices/wimax/nm-wimax-nsp.h @@ -18,8 +18,8 @@ * Copyright (C) 2009 Novell, Inc. */ -#ifndef NM_WIMAX_NSP_H -#define NM_WIMAX_NSP_H +#ifndef __NETWORKMANAGER_WIMAX_NSP_H__ +#define __NETWORKMANAGER_WIMAX_NSP_H__ #include <glib-object.h> #include "nm-wimax-types.h" diff --git a/src/devices/wimax/nm-wimax-types.h b/src/devices/wimax/nm-wimax-types.h index 8c807fd8..207d2477 100644 --- a/src/devices/wimax/nm-wimax-types.h +++ b/src/devices/wimax/nm-wimax-types.h @@ -18,8 +18,8 @@ * Copyright (C) 2009 Novell, Inc. */ -#ifndef NM_WIMAX_TYPES_H -#define NM_WIMAX_TYPES_H +#ifndef __NETWORKMANAGER_WIMAX_TYPES_H__ +#define __NETWORKMANAGER_WIMAX_TYPES_H__ typedef enum { NM_WIMAX_NSP_NETWORK_TYPE_UNKNOWN, diff --git a/src/devices/wimax/nm-wimax-util.c b/src/devices/wimax/nm-wimax-util.c index bca25a1d..0ae285ae 100644 --- a/src/devices/wimax/nm-wimax-util.c +++ b/src/devices/wimax/nm-wimax-util.c @@ -18,7 +18,8 @@ * Copyright (C) 2009 Novell, Inc. */ -#include <WiMaxAPI.h> +#include "config.h" + #include "nm-wimax-util.h" #include "nm-utils.h" #include "iwmxsdk.h" diff --git a/src/devices/wimax/nm-wimax-util.h b/src/devices/wimax/nm-wimax-util.h index 71f5aa29..a1852d55 100644 --- a/src/devices/wimax/nm-wimax-util.h +++ b/src/devices/wimax/nm-wimax-util.h @@ -18,12 +18,17 @@ * Copyright (C) 2009 Novell, Inc. */ -#ifndef NM_WIMAX_UTIL_H -#define NM_WIMAX_UTIL_H +#ifndef __NETWORKMANAGER_WIMAX_UTIL_H__ +#define __NETWORKMANAGER_WIMAX_UTIL_H__ #include <glib.h> +#include "nm-utils-internal.h" + +NM_PRAGMA_WARNING_DISABLE("-Wstrict-prototypes") #include <WiMaxType.h> +NM_PRAGMA_WARNING_REENABLE + #include <WiMaxError.h> #include "nm-wimax-types.h" |