diff options
Diffstat (limited to 'src/nm-config.h')
| -rw-r--r-- | src/nm-config.h | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/src/nm-config.h b/src/nm-config.h index 8bdd5002..42ab4682 100644 --- a/src/nm-config.h +++ b/src/nm-config.h @@ -165,6 +165,13 @@ gint nm_config_keyfile_get_boolean (const GKeyFile *keyfile, const char *section, const char *key, gint default_value); +gint64 nm_config_keyfile_get_int64 (const GKeyFile *keyfile, + const char *section, + const char *key, + guint base, + gint64 min, + gint64 max, + gint64 fallback); char *nm_config_keyfile_get_value (const GKeyFile *keyfile, const char *section, const char *key, @@ -205,6 +212,10 @@ struct _NMConfigDeviceStateData { int ifindex; NMConfigDeviceStateManagedType managed; + /* a value of zero means that no metric is set. */ + guint32 route_metric_default_aspired; + guint32 route_metric_default_effective; + /* the UUID of the last settings-connection active * on the device. */ const char *connection_uuid; @@ -213,17 +224,25 @@ struct _NMConfigDeviceStateData { /* whether the device was nm-owned (0/1) or -1 for * non-software devices. */ - gint nm_owned; + int nm_owned:3; }; NMConfigDeviceStateData *nm_config_device_state_load (int ifindex); +GHashTable *nm_config_device_state_load_all (void); gboolean nm_config_device_state_write (int ifindex, NMConfigDeviceStateManagedType managed, const char *perm_hw_addr_fake, const char *connection_uuid, - gint nm_owned); + gint nm_owned, + guint32 route_metric_default_aspired, + guint32 route_metric_default_effective); + void nm_config_device_state_prune_unseen (GHashTable *seen_ifindexes); +const GHashTable *nm_config_device_state_get_all (NMConfig *self); +const NMConfigDeviceStateData *nm_config_device_state_get (NMConfig *self, + int ifindex); + /*****************************************************************************/ #endif /* __NETWORKMANAGER_CONFIG_H__ */ |