port-probe: rename _get_port() to _peek_port() as there is no ownership transfer
This commit is contained in:
@@ -63,7 +63,7 @@ grab_port (MMPlugin *self,
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
port = mm_port_probe_get_port (probe); /* transfer none */
|
port = mm_port_probe_peek_port (probe);
|
||||||
|
|
||||||
/* TODO: Why do we check for device file? */
|
/* TODO: Why do we check for device file? */
|
||||||
devfile = g_udev_device_get_device_file (port);
|
devfile = g_udev_device_get_device_file (port);
|
||||||
|
@@ -75,7 +75,7 @@ grab_port (MMPlugin *self,
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
port = mm_port_probe_get_port (probe); /* transfer none */
|
port = mm_port_probe_peek_port (probe);
|
||||||
|
|
||||||
/* Look for port type hints */
|
/* Look for port type hints */
|
||||||
if (g_udev_device_get_property_as_boolean (port, "ID_MM_NOKIA_PORT_TYPE_MODEM"))
|
if (g_udev_device_get_property_as_boolean (port, "ID_MM_NOKIA_PORT_TYPE_MODEM"))
|
||||||
|
@@ -60,7 +60,7 @@ grab_port (MMPlugin *self,
|
|||||||
gchar *devfile;
|
gchar *devfile;
|
||||||
MMPortType port_type;
|
MMPortType port_type;
|
||||||
|
|
||||||
port = mm_port_probe_get_port (probe); /* transfer none */
|
port = mm_port_probe_peek_port (probe);
|
||||||
subsys = mm_port_probe_get_port_subsys (probe);
|
subsys = mm_port_probe_get_port_subsys (probe);
|
||||||
name = mm_port_probe_get_port_name (probe);
|
name = mm_port_probe_get_port_name (probe);
|
||||||
|
|
||||||
|
@@ -66,7 +66,7 @@ grab_port (MMPlugin *self,
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
port = mm_port_probe_get_port (probe); /* transfer none */
|
port = mm_port_probe_peek_port (probe);
|
||||||
|
|
||||||
/* Genuine Option NV devices are always supposed to use USB interface 0 as
|
/* Genuine Option NV devices are always supposed to use USB interface 0 as
|
||||||
* the modem/data port, per mail with Option engineers. Only this port
|
* the modem/data port, per mail with Option engineers. Only this port
|
||||||
|
@@ -65,7 +65,7 @@ grab_port (MMPlugin *self,
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
port = mm_port_probe_get_port (probe); /* transfer none */
|
port = mm_port_probe_peek_port (probe);
|
||||||
|
|
||||||
/* Look for port type hints; just probing can't distinguish which port should
|
/* Look for port type hints; just probing can't distinguish which port should
|
||||||
* be the data/primary port on these devices. We have to tag them based on
|
* be the data/primary port on these devices. We have to tag them based on
|
||||||
|
@@ -933,7 +933,7 @@ mm_port_probe_get_port_type (MMPortProbe *self)
|
|||||||
}
|
}
|
||||||
|
|
||||||
GUdevDevice *
|
GUdevDevice *
|
||||||
mm_port_probe_get_port (MMPortProbe *self)
|
mm_port_probe_peek_port (MMPortProbe *self)
|
||||||
{
|
{
|
||||||
g_return_val_if_fail (MM_IS_PORT_PROBE (self), NULL);
|
g_return_val_if_fail (MM_IS_PORT_PROBE (self), NULL);
|
||||||
|
|
||||||
|
@@ -59,7 +59,7 @@ MMPortProbe *mm_port_probe_new (GUdevDevice *port,
|
|||||||
const gchar *physdev_path,
|
const gchar *physdev_path,
|
||||||
const gchar *driver);
|
const gchar *driver);
|
||||||
|
|
||||||
GUdevDevice *mm_port_probe_get_port (MMPortProbe *self);
|
GUdevDevice *mm_port_probe_peek_port (MMPortProbe *self);
|
||||||
const gchar *mm_port_probe_get_port_name (MMPortProbe *self);
|
const gchar *mm_port_probe_get_port_name (MMPortProbe *self);
|
||||||
const gchar *mm_port_probe_get_port_subsys (MMPortProbe *self);
|
const gchar *mm_port_probe_get_port_subsys (MMPortProbe *self);
|
||||||
const gchar *mm_port_probe_get_port_physdev (MMPortProbe *self);
|
const gchar *mm_port_probe_get_port_physdev (MMPortProbe *self);
|
||||||
|
Reference in New Issue
Block a user