Frédéric Danis
afe16ba22a
emulator: always create emulators in offline state
...
this allows to fix problem when atom created in online state
are destroyed when modem goes to offline state
2011-02-17 11:25:27 -06:00
Denis Kenzior
4406da382c
devinfo: Handle BT DUN +GMI/+GMM/+GMR commands
2011-02-16 00:23:44 -06:00
Denis Kenzior
3e69defe86
modem: Tweak online & powered watch APIs
2011-02-10 00:34:47 -06:00
Denis Kenzior
458fe585a0
modem: Fix up previous commit
2011-02-10 00:27:01 -06:00
Guillaume Zajac
2b50146a21
modem Add powered watch API
2011-02-10 00:27:01 -06:00
Jeevaka Badrappan
4d6eaf121c
modem: M16 coding style fix
2011-02-05 07:05:32 -08:00
Marcel Holtmann
ed99980cd3
modem: Simplify the modem lockdown modification
2011-01-26 09:51:41 +01:00
Marcel Holtmann
8637e31d1d
modem: Be a bit more paranoid with lock_owner reset
2011-01-26 09:48:48 +01:00
Rémi Denis-Courmont
8c88ccaad9
modem: do not allow more than one client to lock down
2011-01-26 09:46:42 +01:00
Marcel Holtmann
2999252d15
modem: Add feature entry for supplementary services
2011-01-23 10:17:31 +01:00
Aki Niemi
9adc84ea88
core: Always return success to a no-op
...
A SetProperty that doesn't actually change the Online property's state
when no change to that state is pending, should not fail. It should
always succeed regardless of the current modem state.
2011-01-20 12:23:25 +01:00
Rafael Ignacio Zurita
f92f0b5d47
gps: add new interface to feature map
2011-01-13 11:08:07 -06:00
Jeevaka Badrappan
480f7dffd9
core: M15 coding style fix
2011-01-12 08:06:58 -08:00
Denis Kenzior
adda129e7c
modem: Fix a typo
...
The modem should be offline not online
2010-12-22 19:28:37 -06:00
Denis Kenzior
3daf20216f
modem: Implement some race-condition avoidance
2010-12-22 14:02:59 -06:00
Gustavo F. Padovan
655da893cb
modem: add Lockdown property to Modem interface
...
Setting Lockdown to TRUE means power down the modem and hold a lock that
only permits the lock's owner power up the modem back. When released
it restores the last state of the modem before holding the lock.
2010-12-22 13:36:18 -06:00
Gustavo F. Padovan
8bdbdc2c7d
modem: restore state when resetting the modem
2010-12-17 19:12:32 -06:00
Gustavo F. Padovan
5862e614fd
Add ofono_modem_reset()
...
Some modems can screw up everything and then we will need to do a silent
reset of the modem. This patch take the modem back to the OFFLINE state.
2010-12-07 12:16:20 -06:00
Gustavo F. Padovan
42a90432e7
modem: only unref pending if it is a powered pending
2010-12-07 12:16:20 -06:00
Lucas De Marchi
b210838e87
core: explicitly compare pointers to NULL
...
This patch was generated by the following semantic patch
(http://coccinelle.lip6.fr/ )
// <smpl>
@fix disable is_null,isnt_null1@
expression *E;
@@
- !E
+ E == NULL
// </smpl>
2010-11-29 13:27:15 -06:00
Lucas De Marchi
b1c159e6f6
text-telephony: add new interface to feature map
2010-11-24 09:00:40 -06:00
Denis Kenzior
80a8fd1a64
modem: Don't notify online watches the first time
...
We should not notify the online watches when we enter the OFFLINE state
for the first time. We should only do so when we go from ONLINE state
into the OFFLINE state.
2010-11-22 09:56:22 -06:00
Denis Kenzior
60aceb3e71
modem: Miscellaneous style fixes
2010-11-22 09:54:25 -06:00
Andras Domokos
d7fb7da021
modem: add modem online-offline watch
2010-11-22 09:53:41 -06:00
Jeevaka Badrappan
2d0cb92155
src: coding style fixes - rule M6
2010-11-22 05:07:52 -06:00
Marcel Holtmann
d74471e4d9
modem: Fix small coding style issue
2010-11-19 11:40:31 +01:00
Denis Kenzior
5625c9728f
modem: Fix up doc typo
2010-11-17 08:26:26 -06:00
Gustavo F. Padovan
8ae8deb44f
Simplify ofono_modem_set_powered() logic
2010-11-15 07:39:16 -06:00
Denis Kenzior
cfa956596c
modem: Add ofono_modem_is_registered
2010-10-25 16:32:49 -05:00
Petteri Tikander
6d07c1cffe
modem: add debugs to monitor modem state changes
2010-10-21 23:13:23 -05:00
Denis Kenzior
f4a0b9fa20
modem: Add modemwatch watchlist functions
...
Used for registering to modem added & removed notifications
2010-09-28 22:49:22 -05:00
Denis Kenzior
be56f200d8
modem: Minor style fix
2010-09-28 22:13:02 -05:00
Denis Kenzior
0d2b9cb5f4
modem: Add __ofono_modem_foreach
2010-09-09 14:00:09 -05:00
Denis Kenzior
0f994b7ea3
manager: Add ModemRemoved signal
2010-09-09 13:49:21 -05:00
Denis Kenzior
ffcb821ccf
manager: Add ModemAdded signal
2010-09-09 13:44:59 -05:00
Denis Kenzior
4a60d69e98
modem: Remove unneeded functions
2010-09-09 13:38:20 -05:00
Denis Kenzior
7461abbe23
modem: Break out append_modem_properties
2010-09-09 13:34:36 -05:00
Denis Kenzior
88024972df
modem: Skip waiting for sim_ready if no sim atom
...
For modems that do not have a SIM atom (e.g. HFP, DUN) we should skip
waiting for the sim_ready notification that will never arrive.
2010-08-30 14:32:08 -05:00
Denis Kenzior
4292b2dbed
sim: Turn around the order of arguments
...
The void *user argument was first. It should be last instead to be
consistent with the other watch functions.
2010-08-30 14:29:34 -05:00
Denis Kenzior
b74c9fb0c6
modem: Reset unregister when atom is unregistered
2010-08-30 13:04:15 -05:00
Denis Kenzior
31b52123db
modem: Fix turning off modem in immediate case
...
If the driver does not return EINPROGRESS we don't set the modem to the
off state properly
2010-08-30 12:12:13 -05:00
Denis Kenzior
745477f0d4
modem: minor style fix
2010-08-30 12:09:38 -05:00
Denis Kenzior
b73ebe3c83
gprs: Update GPRS related DBus interface names
2010-08-19 14:20:05 -05:00
Denis Kenzior
7e0f28c7b1
sms: Update SmsManager to MessageManager
2010-08-19 14:20:05 -05:00
Zhenhua Zhang
bdef5046d0
Fix: Free modem name in ofono_modem_remove
...
Avoid the memory leak of modem name.
2010-07-21 11:58:35 -05:00
Marcel Holtmann
7f9793d70b
Add feature identifier for SIM Toolkit
2010-07-17 14:53:07 -07:00
Marcel Holtmann
24124d193a
Just call the feature "net" instead of "netreg"
2010-06-12 21:41:48 +02:00
Marcel Holtmann
236f3acc0f
Add support for Features property on modem interface
2010-06-09 20:46:10 -07:00
Pekka Pessi
8001338da7
Use ofono_bool_t instead of bool in modem API.
2010-05-27 13:01:06 -05:00
Pekka Pessi
7d1c404a6a
modem: Fix inconsistent state
...
Keep modem state consistent if sim is removed while set_online
driver call is pending. This results in set_online callback being
called and modem entering an invalid state.
2010-05-27 12:44:40 -05:00
Denis Kenzior
5a24916aae
Fix: Go to online state if set_online is NULL
2010-05-26 21:03:15 -05:00
Denis Kenzior
7705cebd3f
Refactor: no need for dummy_online_callback
2010-05-26 21:03:15 -05:00
Denis Kenzior
f2a2573cd0
Fix: Don't allow setting online before sim ready
2010-05-26 21:03:15 -05:00
Denis Kenzior
adefe451a2
Refactor: Break up set_online_callback
...
- Break up into two functions, one for online and one for offline
- No longer the need for online_pending variable
2010-05-26 21:03:15 -05:00
Denis Kenzior
5da54eea44
Refactor: flush_atoms
...
The current implementation did not take care of the case where the head
of the list was removed
2010-05-26 21:03:14 -05:00
Denis Kenzior
5890c38a37
Refactor: Don't use ofono_ prefix
...
Only meant for oFono public API
2010-05-26 21:03:14 -05:00
Denis Kenzior
53dc160362
Refactor: The macros are no longer needed
2010-05-26 21:03:14 -05:00
Denis Kenzior
d3b9f42ed4
Refactor: Don't use ofono_ prefix
...
Only to be used for ofono public API
2010-05-26 21:03:14 -05:00
Denis Kenzior
1b34af054d
Refactor: Don't use ofono_ prefix
...
only meant for public API
2010-05-26 21:03:14 -05:00
Denis Kenzior
c53d084234
Refactor: Don't use ofono_ prefix
...
ofono_ prefix is meant for public API
2010-05-26 21:03:14 -05:00
Denis Kenzior
e7529bfa70
Fix: minor style issues
2010-05-26 21:03:12 -05:00
Pekka Pessi
4f1506ba25
Add: Online property to modem
...
The online/offline state is changed with the new set_online() modem driver
method.
In order to track atoms, there are modem states as follows:
- OFONO_MODEM_STATE_POWER_OFF
- OFONO_MODEM_STATE_PRE_SIM
- OFONO_MODEM_STATE_OFFLINE
- OFONO_MODEM_STATE_ONLINE
Atoms are added with driver methods pre_sim(), post_sim() and post_online().
Atoms are removed by modem core when the state changes.
2010-05-26 14:24:11 -05:00
Denis Kenzior
83fc72c95a
core: Trivial whitespace error
2010-05-19 05:26:35 -05:00
Aki Niemi
b8ec7553ef
Add network time support
...
Adding a new notify function in the netreg atom for notifying a
received Network Identification and Timezone (NITZ) indication. This
data is consumed via a nettime plugin, of which there is also an
example.
2010-05-19 10:46:18 +03:00
Andrzej Zaborowski
018ee10f92
Fix: Don't remove wrong atoms
...
When the state goes from INSERTED to NOT PRESENT and we have not
advanced past the SIM PIN entry, we remove the pre_sim atoms.
Similarly, if we advanced past the SIM PIN stage and subsequently
removed the SIM, the pre_sim atom list should not be tampered with.
2010-05-10 15:26:09 -05:00
Denis Kenzior
88be6109a2
Fix: Don't crash by calling sim watch too early
...
The modem sim watch is only watching for removed and ready conditions,
so no need to call it prematurely
2010-04-15 16:49:43 -05:00
Denis Kenzior
214c7dd776
Fix: Make distcheck happy
2010-04-15 16:49:43 -05:00
Denis Kenzior
9a9a05095d
Refactor: Keep separate lists for pre/post atoms
2010-04-15 16:49:42 -05:00
Denis Kenzior
0ac64d66e8
Refactor: use a switch/case to make more readable
2010-04-15 16:49:42 -05:00
Andrzej Zaborowski
f27946b4b0
Remove post-sim atoms after SIM is extracted.
2010-04-15 16:49:42 -05:00
Andrzej Zaborowski
aad4d0de78
Add Sim Toolkit atom
...
- Add ofono_stk atom in stk.c
- Move envelope command from sim driver to stk driver
2010-04-15 16:49:40 -05:00
Andrzej Zaborowski
22cbe98146
Extend sim-ready watch with card insert/eject
2010-04-15 16:49:40 -05:00
Denis Kenzior
af4d4aeaeb
Fix: Trivial mistake
2010-02-12 18:48:32 -06:00
Denis Kenzior
d87f285fdf
Add support for modem names
2010-02-12 18:29:41 -06:00
Inaky Perez-Gonzalez
8b54792cdd
Clean: no error path needed
...
Remove unneeded error path and document the rationale behind it in
__ofono_modem_get_list() and manager_get_properties().
2010-02-10 18:06:46 -06:00
Denis Kenzior
1b5c314f9a
Refactor: Allow persisent modem names
2010-01-06 15:50:25 -06:00
Marcel Holtmann
144080e749
Update copyright information
2010-01-01 17:00:10 -08:00
Denis Kenzior
955e6a61ee
Style: Fix a few more occurences of if/else
...
See Linux coding style document for details
2009-12-17 21:45:39 -06:00
Denis Kenzior
bea0fd608e
Fix: Be more paranoid even during shutdown
2009-12-08 04:25:43 -06:00
Denis Kenzior
430e8755dc
Fix: Print a warning in set_powered
...
If ofono_modem_set_powered is used with no driver set, print a warning
2009-12-08 04:24:38 -06:00
Zhenhua Zhang
06d17397c5
Fix remove all atoms in ofono_modem_set_powered
...
We should remove all atoms when we disable the modem. In function
set_powered, we remove all atoms if modem is powered down by dbus
call.
2009-12-08 04:05:10 -06:00
Denis Kenzior
070ea1d339
Remove: Unused code related to modem powered prefs
2009-12-08 04:03:30 -06:00
Denis Kenzior
b15eccf0f4
Revert: Previous powered patch
2009-12-08 03:44:55 -06:00
Alexander Kanavin
81d7cd4e12
Fix a crash during isimodem initialization
2009-12-08 17:09:15 +02:00
Denis Kenzior
c7ac706de1
Refactor: call id allocation / release
2009-12-04 16:52:30 -06:00
Denis Kenzior
bcef5a1dd6
Fix: Exit right away
...
If no plugin needs to run the eventloop to shutdown cleanly, exit right
away.
2009-12-03 00:42:59 -06:00
Denis Kenzior
39568bbef7
Fix: Paste error
2009-12-02 19:24:37 -06:00
Denis Kenzior
b0f0e248e9
When SIGTERM is received, run the event loop
...
This feature will continue running the event loop for another 10 seconds
or so or until all the modems have been shut down. This will allow the
modem drivers to properly shutdown their respective devices.
2009-12-02 19:11:36 -06:00
Denis Kenzior
9c63c7dc20
Refactor: Set powered to false if disable timedout
2009-12-02 19:11:32 -06:00
Denis Kenzior
b787745b00
Fix: unregister modem when unregistering driver
2009-12-02 19:10:07 -06:00
Denis Kenzior
6266e3f679
Refactor: modem de-registration
2009-12-02 19:10:07 -06:00
Denis Kenzior
dac0ccc8a8
Fix: Remove all atoms when attempting to power off
...
The current behavior is to remove atoms when the modem has powered off
successfully. The modem driver must now take special precautions to
cancel all pending actions of the atom drivers, since they would have
been destroyed.
2009-12-02 19:10:07 -06:00
Zhenhua Zhang
7254f8ac86
Fix: Reset call_ids when modem is powered off
2009-11-26 08:08:17 -06:00
Denis Kenzior
7600c4b3ac
Fix: Emit Manufacturer, not Serial
2009-11-11 22:09:36 -06:00
Denis Kenzior
274cd012c4
Fix: Report registered modems properly
2009-09-28 11:18:50 -05:00
Denis Kenzior
863210f7c0
Fix: Comparison should be against negative errno
2009-09-22 09:36:55 -05:00
Denis Kenzior
0698fc2788
Split populate modem driver method
...
Introduce two new methods
- pre_sim - SIM is not inserted or locked. This should populate
the modem with atoms that can be used without the SIM.
Generally this is the devinfo atom, the sim atom and the voice
call atom (emergency calls only)
- post_sim - SIM is ready. This method should populate the
modem with the remaining atoms
2009-09-17 10:14:02 -05:00
Denis Kenzior
5e754c6518
Create watchlists during register
2009-09-11 14:06:18 -05:00
Denis Kenzior
32fc30fa02
Refactor various watch functions
...
Use a common core kernel for all the watcher registrations /
notifications. This is now done in watch.c
2009-09-11 12:39:53 -05:00
Andrzej Zaborowski
6f675b3148
Keep modem->powered_pending up to date after set_powered.
...
Without this once a request to power up the modem fails, modem.c won't
retry even when asked.
2009-09-10 16:29:56 -05:00