device: make @pllink argument in link_changed() function const
This commit is contained in:
@@ -1679,10 +1679,10 @@ carrier_changed (NMDevice *device, gboolean carrier)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
link_changed (NMDevice *device, NMPlatformLink *info)
|
link_changed (NMDevice *device, const NMPlatformLink *pllink)
|
||||||
{
|
{
|
||||||
NM_DEVICE_CLASS (nm_device_ethernet_parent_class)->link_changed (device, info);
|
NM_DEVICE_CLASS (nm_device_ethernet_parent_class)->link_changed (device, pllink);
|
||||||
if (info->initialized)
|
if (pllink->initialized)
|
||||||
_update_s390_subchannels ((NMDeviceEthernet *) device);
|
_update_s390_subchannels ((NMDeviceEthernet *) device);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -331,9 +331,10 @@ update_properties (NMDevice *device)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
link_changed (NMDevice *device, NMPlatformLink *info)
|
link_changed (NMDevice *device,
|
||||||
|
const NMPlatformLink *pllink)
|
||||||
{
|
{
|
||||||
NM_DEVICE_CLASS (nm_device_ip_tunnel_parent_class)->link_changed (device, info);
|
NM_DEVICE_CLASS (nm_device_ip_tunnel_parent_class)->link_changed (device, pllink);
|
||||||
update_properties (device);
|
update_properties (device);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -212,9 +212,10 @@ update_properties (NMDevice *device)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
link_changed (NMDevice *device, NMPlatformLink *info)
|
link_changed (NMDevice *device,
|
||||||
|
const NMPlatformLink *pllink)
|
||||||
{
|
{
|
||||||
NM_DEVICE_CLASS (nm_device_macvlan_parent_class)->link_changed (device, info);
|
NM_DEVICE_CLASS (nm_device_macvlan_parent_class)->link_changed (device, pllink);
|
||||||
update_properties (device);
|
update_properties (device);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -122,10 +122,10 @@ get_generic_capabilities (NMDevice *dev)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
link_changed (NMDevice *device, NMPlatformLink *info)
|
link_changed (NMDevice *device,
|
||||||
|
const NMPlatformLink *pllink)
|
||||||
{
|
{
|
||||||
NM_DEVICE_CLASS (nm_device_tun_parent_class)->link_changed (device, info);
|
NM_DEVICE_CLASS (nm_device_tun_parent_class)->link_changed (device, pllink);
|
||||||
|
|
||||||
reload_tun_properties (NM_DEVICE_TUN (device));
|
reload_tun_properties (NM_DEVICE_TUN (device));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -152,19 +152,18 @@ get_generic_capabilities (NMDevice *dev)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
link_changed (NMDevice *device, NMPlatformLink *info)
|
link_changed (NMDevice *device,
|
||||||
|
const NMPlatformLink *pllink)
|
||||||
{
|
{
|
||||||
NM_DEVICE_CLASS (nm_device_vxlan_parent_class)->link_changed (device, info);
|
NM_DEVICE_CLASS (nm_device_vxlan_parent_class)->link_changed (device, pllink);
|
||||||
update_properties (device);
|
update_properties (device);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
realize_start_notify (NMDevice *device, const NMPlatformLink *plink)
|
realize_start_notify (NMDevice *device, const NMPlatformLink *plink)
|
||||||
{
|
{
|
||||||
g_assert (plink->type == NM_LINK_TYPE_VXLAN);
|
g_return_if_fail (plink->type == NM_LINK_TYPE_VXLAN);
|
||||||
|
|
||||||
NM_DEVICE_CLASS (nm_device_vxlan_parent_class)->realize_start_notify (device, plink);
|
NM_DEVICE_CLASS (nm_device_vxlan_parent_class)->realize_start_notify (device, plink);
|
||||||
|
|
||||||
update_properties (device);
|
update_properties (device);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -2119,12 +2119,12 @@ link_changed_cb (NMPlatform *platform,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
link_changed (NMDevice *self, NMPlatformLink *info)
|
link_changed (NMDevice *self, const NMPlatformLink *pllink)
|
||||||
{
|
{
|
||||||
/* Update carrier from link event if applicable. */
|
/* Update carrier from link event if applicable. */
|
||||||
if ( nm_device_has_capability (self, NM_DEVICE_CAP_CARRIER_DETECT)
|
if ( nm_device_has_capability (self, NM_DEVICE_CAP_CARRIER_DETECT)
|
||||||
&& !nm_device_has_capability (self, NM_DEVICE_CAP_NONSTANDARD_CARRIER))
|
&& !nm_device_has_capability (self, NM_DEVICE_CAP_NONSTANDARD_CARRIER))
|
||||||
nm_device_set_carrier (self, info->connected);
|
nm_device_set_carrier (self, pllink->connected);
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
|
@@ -153,7 +153,8 @@ typedef struct {
|
|||||||
NMDeviceState old_state,
|
NMDeviceState old_state,
|
||||||
NMDeviceStateReason reason);
|
NMDeviceStateReason reason);
|
||||||
|
|
||||||
void (* link_changed) (NMDevice *self, NMPlatformLink *info);
|
void (* link_changed) (NMDevice *self,
|
||||||
|
const NMPlatformLink *pllink);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* create_and_realize():
|
* create_and_realize():
|
||||||
|
Reference in New Issue
Block a user