mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-06 10:30:39 +01:00
device: remove unneeded implementations of realize()
The virtual function NMDevice:realize() is only called by nm_device_realize() and immediately followed by nm_device_setup_start(). Devices already overwrite setup_start_notify() to update their properties. No need to duplicate that in realize().
This commit is contained in:
parent
4c6b991bb0
commit
492691dfb2
4 changed files with 0 additions and 35 deletions
|
|
@ -448,13 +448,6 @@ update_connection (NMDevice *device, NMConnection *connection)
|
|||
}
|
||||
}
|
||||
|
||||
static gboolean
|
||||
realize (NMDevice *self, NMPlatformLink *plink, GError **error)
|
||||
{
|
||||
update_properties (self);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
match_parent (NMDevice *dev_parent, const char *setting_parent)
|
||||
{
|
||||
|
|
@ -885,7 +878,6 @@ nm_device_ip_tunnel_class_init (NMDeviceIPTunnelClass *klass)
|
|||
device_class->check_connection_compatible = check_connection_compatible;
|
||||
device_class->create_and_realize = create_and_realize;
|
||||
device_class->ip4_config_pre_commit = ip4_config_pre_commit;
|
||||
device_class->realize = realize;
|
||||
device_class->realize_start_notify = realize_start_notify;
|
||||
device_class->unrealize = unrealize;
|
||||
|
||||
|
|
|
|||
|
|
@ -209,13 +209,6 @@ link_changed (NMDevice *device, NMPlatformLink *info)
|
|||
update_properties (device);
|
||||
}
|
||||
|
||||
static gboolean
|
||||
realize (NMDevice *device, NMPlatformLink *plink, GError **error)
|
||||
{
|
||||
update_properties (device);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
create_and_realize (NMDevice *device,
|
||||
NMConnection *connection,
|
||||
|
|
@ -652,7 +645,6 @@ nm_device_macvlan_class_init (NMDeviceMacvlanClass *klass)
|
|||
device_class->is_available = is_available;
|
||||
device_class->link_changed = link_changed;
|
||||
device_class->notify_new_device_added = notify_new_device_added;
|
||||
device_class->realize = realize;
|
||||
device_class->realize_start_notify = realize_start_notify;
|
||||
device_class->update_connection = update_connection;
|
||||
|
||||
|
|
|
|||
|
|
@ -234,13 +234,6 @@ create_and_realize (NMDevice *device,
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
realize (NMDevice *device, NMPlatformLink *plink, GError **error)
|
||||
{
|
||||
reload_tun_properties (NM_DEVICE_TUN (device));
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static void
|
||||
realize_start_notify (NMDevice *device, const NMPlatformLink *plink)
|
||||
{
|
||||
|
|
@ -446,7 +439,6 @@ nm_device_tun_class_init (NMDeviceTunClass *klass)
|
|||
device_class->complete_connection = complete_connection;
|
||||
device_class->check_connection_compatible = check_connection_compatible;
|
||||
device_class->create_and_realize = create_and_realize;
|
||||
device_class->realize = realize;
|
||||
device_class->realize_start_notify = realize_start_notify;
|
||||
device_class->unrealize = unrealize;
|
||||
device_class->update_connection = update_connection;
|
||||
|
|
|
|||
|
|
@ -236,16 +236,6 @@ create_and_realize (NMDevice *device,
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
realize (NMDevice *device, NMPlatformLink *plink, GError **error)
|
||||
{
|
||||
g_assert (plink->type == NM_LINK_TYPE_VXLAN);
|
||||
|
||||
update_properties (device);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
match_parent (NMDeviceVxlan *self, const char *parent)
|
||||
{
|
||||
|
|
@ -670,7 +660,6 @@ nm_device_vxlan_class_init (NMDeviceVxlanClass *klass)
|
|||
device_class->unrealize = unrealize;
|
||||
device_class->connection_type = NM_SETTING_VXLAN_SETTING_NAME;
|
||||
device_class->create_and_realize = create_and_realize;
|
||||
device_class->realize = realize;
|
||||
device_class->check_connection_compatible = check_connection_compatible;
|
||||
device_class->complete_connection = complete_connection;
|
||||
device_class->update_connection = update_connection;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue