summaryrefslogtreecommitdiff
path: root/src/technology.c
AgeCommit message (Collapse)AuthorFilesLines
2012-04-27technology: Create the settings file in initJukka Rissanen1-0/+3
We save offline mode status in init so that settings file gets created if it was missing.
2012-04-27technology: Save technology state if entry is missing from fileJukka Rissanen1-28/+30
So we save the technology status if the settings file does not contain it.
2012-04-27technology: Offline mode is OFF by defaultJukka Rissanen1-2/+2
By defalt offline mode is OFF if settings file is not found or OfflineMode entry is not found in settings file.
2012-04-27technology: Enable ethernet by defaultJukka Rissanen1-2/+9
Ethernet is enabled by default if settings file is not found or the Wired entry is not found in the file.
2012-04-20technology: Fix indentionDaniel Wagner1-1/+1
2012-03-04core: Add extra checks for set property methodsMarcel Holtmann1-0/+7
2012-03-01technology: Enable tech if device is already poweredAlok Barsode1-2/+11
connman_technology_add_device() calls __connman_device_enable() but since the device is already enabled, the calls does not propagate through to __connman_technology_enabled via connman_device_set_powered.
2012-02-24technology: Fix technology refcountingAlok Barsode1-2/+2
__sync_fetch_and_sub() gives the value that had previously been in memory which gives the older refount. technology_find() does not refcount the technology. __connman_technology_update_rfkill() was using technology_get() which was refcounting the technology. Every technology_get() must be matched with a corresponding technology_put() for accurate refcounting.
2012-02-04technology: Implement Technology Scan and scan start/stop functionalityPatrik Flykt1-11/+100
When Technology Scan D-Bus method call is called, add caller to a scan list and start a scan for the service type. When a device reports scan completed, check whether it was the last device scanning and reply to the callers accordingly. Also check for scanning status when removing devices and technology objects.
2012-02-01technology: Fix technology refcountingAlok Barsode1-2/+6
technology_add_device and technology_add_rfkill should increment technology refcount. The refcount denotes the total number of devices and rfkill switches in the technology. Similarly technology_remove_device and technology_remove_rfkill should decrement technology refcount. Once the refcount is 0, which means that there are no devices and rfkill switches in this technology, technology should be freed.
2012-02-01technology: Create a list for technology orphaned rfkill switchesAlok Barsode1-20/+45
If we get a rfkill switch before the technology driver was registered we would lose track of it as we currently ignoed it. Adding a global rfkill hash table which can keep a track of technologyless switches untill the driver for them is loaded. If the driver is not compiled in the switches will remain in the hash but will not be handled by connman.
2012-02-01technology: Create a list for technology orphaned devicesAlok Barsode1-2/+43
If we get a device before the technology driver was registered we would lose track of it as we ignoed it. Adding a device list which can keep a track of technologyless devices untill the driver for them is loaded. If the driver is not compiled in the devices will remain in the list.
2012-01-24technology: Remove 'State' property from TechnologyPatrik Flykt1-58/+3
2012-01-24technology: Add 'Connected' Technology propertyPatrik Flykt1-0/+23
Set Technology property 'Connected' to true if at least one service for the Technology is connected; false otherwise.
2012-01-24technology: Add object path to TechnologyAdded signalDaniel Wagner1-0/+2
As it is described in the manager-api.txt document.
2012-01-20technology: Fix g_dbus_emit_signal argumentAlok Barsode1-1/+1
Fixes BMC#24636
2012-01-20technology: Remove unused notifier functionsPatrik Flykt1-6/+0
2012-01-20technology: Add 'Powered' Technology propertyPatrik Flykt1-154/+192
Remove __connman_technology_enable/disable functions but reuse their contents for 'Powered' property implementation. As a result move code around as the new functions are now static.
2012-01-16technology: Register a technology is there's a driver for itAlok Barsode1-22/+25
Connman should not handle technologies whose drivers are not compiled in. This patch also avoids connman controlling the rfkill switches for technologies not compiled in. Fixes BMC#24549.
2012-01-16technology: Assign driver to technology at creation timeAlok Barsode1-15/+2
No need to assign driver to technolog during driver registration.
2012-01-13technology: Add missing args terminationDaniel Wagner1-1/+2
Open argument list has to be terminated.
2012-01-09technology: There is no need for add_interface to refcount technology.Alok Barsode1-4/+2
2012-01-09technology: return a reply even if there are no devices in the technology list.Alok Barsode1-2/+4
2012-01-05manager: Remove manager 'Technologies' propertyPatrik Flykt1-24/+0
Remove 'Technologies' property from Manager API and the code updating the property.
2012-01-05technology: Implement Manager API GetTechnologies method callPatrik Flykt1-0/+20
2012-01-05technology: Add 'TechnologyAdded' and 'TechnologyRemoved' signalsPatrik Flykt1-13/+46
2011-12-22technology: Return technology name Cellular instead 3GDaniel Wagner1-1/+1
2011-12-01technology: Check if pending message is NULL before sending it backSamuel Ortiz1-2/+4
The message would be NULL when setting offline mode on and off. Fixes BMC#24314
2011-11-28technology: Save the pending reply only when the status is inprogressYu A Wang1-8/+12
For ethernet device, there is no need to save a pending reply as the technology enablement is synchronous. Fixes BMC#24249
2011-11-10core: Use gcc atomics instead glib's onesDaniel Wagner1-10/+11
g_atomic_int_exchange_and_add() has been removed from glib 2.30 and g_atomic_int_add() should be used. Though there are still quite a few distros out which do not ship a glib version with g_atomic_int_add(). Instead of maintaing a compatiblilty glib layer we just use the built-in functions for atomic memory access.
2011-10-06technology: remove the pending_timeout source with g_source_removeAlok Barsode1-0/+3
2011-09-29technology: Register a rfkilled technology in technology_add_rfkillAlok Barsode1-0/+9
If a technology was rfkilled before connman ran, we need to register it. If such tech was enabled, technology->device_list will be empty. We save the state, rfkill unblock the type and exit. When the devices get unblocked, they are automatically enabled since we saved the enable state.
2011-09-12technology: Disable tethering only when no technology is tetheringPatrik Flykt1-2/+11
When notifying that a technology is not tethering anymore, go through the list of technologies and disable tethering only if no other technology is tethering.
2011-09-12technology: When disabling technology, disble tethering tooPatrik Flykt1-0/+3
2011-09-12technology: Move bridege checking to set_tethering()Patrik Flykt1-8/+7
Move bridge checking into set_tethering(), as the bridge information is not used elsewhere.
2011-09-12storage: Switch to settings fileAlok Barsode1-21/+29
All the global settings would reside in /var/lib/connman/settings. We also migrate global keys from /var/lib/connman/default.profile to /var/lib/connman/settings for a smooth transition.
2011-08-25storage: Remove technology state load/save methods from storage moduleAlok Barsode1-71/+62
2011-08-25technology: Save/Load offlinemodeAlok Barsode1-15/+63
Load/Save offlinemode in technology.c instead of profile.c.
2011-08-25device: Remove device persistent codeAlok Barsode1-2/+2
Connman now stores technology states persistently. Hence there is no reason to store device states persistently.
2011-08-25technology: Remove blocked variables and associated functionsAlok Barsode1-84/+51
2011-08-25technology: Fix enable notifier to be invoked just onceAlok Barsode1-2/+1
When there are multiple devices, the technology enable notifier was invoked multiple times. But when disabling the technology, the disable notifier was invoked just once, hence there was a mismatch in the technology states.
2011-08-25technology: Remove 'available' stateAlok Barsode1-16/+5
The connman technology state machine is simplified. It now has 3 states: Offline: Technology is disabled. Enabled: Technology is enabled. Connected: Technology is connected.
2011-08-25technology: Redo offlinemode logicAlok Barsode1-5/+27
Traverse the list of technologies and enable/disable each instead of traversing the device list.
2011-08-25technology: Save state persistentlyAlok Barsode1-3/+87
Save the technology state persistently. This will help in resuming the technology state after offlinemode or during startup. This patch just saves the states.
2011-08-25technology: Remove the global device hashAlok Barsode1-18/+1
There is a device list per technology. Hence removing the global device hash.
2011-08-25technology: Remove global rfkill tableAlok Barsode1-11/+5
Remove the global rfkill_table and maintain a per technology rfkill table.
2011-08-25technology: Modify technology enable/disable APIsAlok Barsode1-13/+100
Add the pending dbus message per technology. Also move the pending timeout from manager to technology.
2011-08-25device: Update profile in enable_persistent callbackAlok Barsode1-0/+5
2011-08-25technology: Refactor enable/disable APIsAlok Barsode1-2/+56
connman_technology_enable: Enable a technology. Enables all the devices in the device_list of the technology. connman_technology_enabled: Callback for connman_technology_enable. Changes the state of the technology to ENABLED. Ditto for connman_technology_disable/connman_technology_disabled.
2011-06-16element: Remove element.cDaniel Wagner1-0/+1