mirror of
https://gitlab.freedesktop.org/upower/upower.git
synced 2026-05-05 09:58:06 +02:00
linux: Lower initial power usage when iDevice isn't accessible
When starting up, we would try to connect to the iDevice repeatedly, once a second. But the process takes between a quarter and half a second, and is CPU heavy. Lower this timeout to once every 5 seconds to reduce the initial CPU consumption.
This commit is contained in:
parent
54dd83501a
commit
402640bee0
1 changed files with 1 additions and 1 deletions
|
|
@ -247,7 +247,7 @@ up_device_idevice_coldplug (UpDevice *device)
|
|||
"has-history", TRUE,
|
||||
NULL);
|
||||
|
||||
idevice->priv->start_id = g_timeout_add_seconds (1, (GSourceFunc) up_device_idevice_start_poll_cb,
|
||||
idevice->priv->start_id = g_timeout_add_seconds (5, (GSourceFunc) up_device_idevice_start_poll_cb,
|
||||
idevice);
|
||||
g_source_set_name_by_id (idevice->priv->start_id,
|
||||
"[upower] up_device_idevice_start_poll_cb (linux)");
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue