Commit Graph

168 Commits

Author SHA1 Message Date
Andrzej Zaborowski 1d38e7e075 network: Watch for changes to relevant SIM files 2011-02-17 15:09:16 -06:00
Denis Kenzior 3f798c4741 core: Minor style tweaks 2011-02-03 13:15:29 -06:00
Andrzej Zaborowski a7a0cb1ed0 simfs: implement ofono_sim_context api 2011-02-03 13:13:37 -06:00
Aki Niemi ac6656b004 netreg: Fix coding style, M12 2011-02-02 11:03:21 +02:00
Aki Niemi 8c15a690df netreg: Deprecate the deregister method 2011-01-20 09:54:55 -06:00
Aki Niemi de3a9c7e7c netreg: Remove default statement 2011-01-18 14:02:59 +02:00
Aki Niemi e25d40f194 netreg: Fix userdata -> user_data
This convention has been advertized on the mailing list.
2011-01-18 14:02:54 +02:00
Aki Niemi cd46b6bcf3 netreg: Style fixes, M12 2011-01-18 14:02:41 +02:00
Marcel Holtmann 8772946cfe network: Ignore signal strength notifications if not registered
With the fix to query the signal strength when the registration status
changes it should be now fine again to just ignore notifications about
signal strength changes when not registered.  So put this extra check
and comment back into signal strenth notification function.
2011-01-05 21:03:52 -08:00
Marit Henriksen b7713da077 network: query signal strength
Signal strength is set to -1 whenever registration status changes
and differs from registered or roaming. When registration status
changes again to registered or roaming, the signal strength needs to
be updated, added query towards driver to get it.
2011-01-05 16:20:31 -08:00
Denis Kenzior 7c3a800267 network: Send strength as a byte, not uint16
To be consistent with the documentation
2010-12-03 12:14:06 -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
Yang Gu c11d3e95cb network: Use bit as size instead of byte 2010-11-26 14:02:02 -06:00
Jeevaka Badrappan 2d0cb92155 src: coding style fixes - rule M6 2010-11-22 05:07:52 -06:00
Aki Niemi 56d46ae16b netreg: Allow strength notifys at all times 2010-10-21 21:39:41 +03:00
Jeevaka Badrappan 4196182770 Fix multi-line comment style issues 2010-09-21 21:16:01 -05:00
Marcel Holtmann 89e5a75fc1 netreg: Make reset_available returning void 2010-08-19 10:06:17 +02:00
Denis Kenzior 60e091f16f netreg: Minor style issues 2010-08-18 21:13:14 -05:00
Denis Kenzior 999a754ef7 netreg: Move more stuff around 2010-08-18 21:09:03 -05:00
Denis Kenzior 89f37c9010 netreg: Move stuff around to avoid forward decl 2010-08-18 21:07:50 -05:00
Denis Kenzior 53c5c9b0e2 netreg: Make logic more readable 2010-08-18 21:03:04 -05:00
Denis Kenzior 84bdd03683 netreg: Move code around to avoid forward decl 2010-08-18 17:53:04 -05:00
Denis Kenzior b67a324ff4 netreg: Update to the new Scan/GetOperators API 2010-08-18 17:46:51 -05:00
Denis Kenzior cf86deeb82 netreg: Add MCC/MNC to NetworkRegistration
These are the same values as on the NetworkOperator interface for the
current operator.  Just added for convenience.
2010-07-27 16:52:16 -05:00
Denis Kenzior c8f15602cf network: Some style issues 2010-06-07 12:57:50 -05:00
Denis Kenzior 3d96880f41 netreg: Ignore operator info when not registered
Sometimes when we roam off the cell or are simply not registered, the
modem still reports a bogus operator.  We explicitly ignore this
condition in the core.
2010-06-07 12:57:46 -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
Denis Kenzior e05318aa5a Refactor: Rename netreg Operator property to Name 2010-03-25 10:57:52 -05:00
Denis Kenzior 77693b697d Rename AvailableOperators to Operators 2010-03-25 10:37:46 -05:00
Denis Kenzior d3ac9188f0 Fix: Handle broken modems that returns empty COPS 2010-03-23 21:16:50 -05:00
Denis Kenzior 01a4a93bee Move netreg interface definitions to dbus.h 2010-03-23 13:35:58 -05:00
Denis Kenzior 87ca1b0c8f Fix: Don't use ofono_debug directly in the core
Use DBG macro which is integrated with the new debug framework.
2010-02-08 11:54:03 -06:00
Denis Kenzior e5bcf50a0c Fix: Wrong variables use
Copy/paste error from above resulted in incorrect variables being used
for comparison.
2010-02-03 23:58:27 -06:00
Denis Kenzior d9bb71e521 Fix: Don't try to unregister a null mcc/mnc
Network operators with null MCC & MNC are not registered, but we try to
unregister them.  Don't do this as it causes a crash.
2010-01-13 11:40:15 -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
Zhenhua Zhang c77f1d0cc9 Fix: Add check for register_auto method
Add check for register_auto method to avoid crash. HFP backend
does not provide implementation for register_auto.
2009-11-24 20:36:56 -06:00
Denis Kenzior 06632f8192 Add ProposeScan method
This is the replacement for automatic operator scanning
2009-11-18 12:49:26 -06:00
Denis Kenzior ac144e40a2 Fix: Use a different function for initial register
Just in case pending variable gets set to something
2009-11-18 12:28:45 -06:00
Denis Kenzior d87e0e86f7 Refactor: Reshuffle bit flags 2009-11-18 12:21:45 -06:00
Denis Kenzior bbfb17366c Refactor: Remove period operator scan 2009-11-18 12:21:30 -06:00
Denis Kenzior cd9b7c07b6 Refactor: Get rid of PENDING flag in netreg 2009-11-18 12:20:39 -06:00
Denis Kenzior 24a7d9a673 Fix: Handle the case where only PLMN name is given
HFP does not allow the use of register / unregister or scan for operator
functionality.  It only allows the name of the operator to be given, not
even an MCC/MNC.  Handle this situation inside netreg atom.
2009-11-04 11:43:57 -06:00
Denis Kenzior cbe52b9a44 Fix: Quiet compiler warnings 2009-10-30 16:09:59 -05:00
Denis Kenzior cc5701c76f Add saving / restoring of netreg settings 2009-10-30 15:23:27 -05:00
Denis Kenzior 66653ecfb7 Add Mode property to NetworkRegistration 2009-10-30 12:38:12 -05:00
Denis Kenzior 252fd9eb52 Fix: Properly update technologies
When current operator is reported, update the technology list if the
tech information is available
2009-10-29 16:38:25 -05:00
Denis Kenzior a53440d648 Compress the operator list before processing 2009-10-29 16:33:29 -05:00
Denis Kenzior 22dc4e229f Add utility to compress plmns that vary by tech 2009-10-29 15:58:32 -05:00
Denis Kenzior 40adc85174 Refactor: Get rid of useless netreg parameter 2009-10-29 15:58:09 -05:00
Denis Kenzior 4e69a94a86 Refactor: Use Technologies instead of Technology 2009-10-29 15:57:02 -05:00
Denis Kenzior 47fa0fb883 Add utility to create a list of supported techs 2009-10-29 15:54:23 -05:00
Denis Kenzior 694cacf4f8 Refactor: Operator registration to DBUS 2009-10-29 15:48:37 -05:00
Denis Kenzior 9f8bc8e6cd Refactor: Internal data structures
This is in preparation to coalescing multiple operators reported by the
driver that vary only by technology into a single operator with multiple
technologies
2009-10-29 15:33:57 -05:00
Denis Kenzior 177c9672d1 Fix: Also auto register when status is unknown 2009-10-29 14:21:04 -05:00
Denis Kenzior 24d8a5722b Refactor: replace netreg get_operator with mcc/mnc
The full operator information is useless as only mcc/mnc are really
required.  The internal structures will be changing soon
2009-10-27 19:47:52 -05:00
Denis Kenzior ed813455c2 Fix: Don't emit spurious Base Station Name signal 2009-10-27 14:41:43 -05:00
Andrzej Zaborowski 5773e30373 Refactor: Move network registration status utils
Move the status to string functions to common.c so that they can be
reused in data connection related network registration code.
2009-10-16 11:12:43 -05:00
Denis Kenzior be55ba4ab3 Refactor: Move elementary file type checking
Every single EF read callback checks the file type reported out of the
SIM is what it expects.  Instead this should be done in one place and
the errors reported accordingly
2009-10-02 18:25:56 -05:00
Denis Kenzior 84515b9d39 Assume netreg is registered when sim ready 2009-09-22 00:07:06 -05:00
Marcel Holtmann 75719f0c01 Fix compilation error with missing return value 2009-09-12 09:01:05 +02:00
Denis Kenzior 6f86a8d0a6 Add utility for setting the netreg base station 2009-09-11 21:35:31 -05:00
Denis Kenzior f03b97c635 Add network registration status watch capability 2009-09-11 16:25:15 -05:00
Denis Kenzior 27cfc00eba Add netreg getter functions
- Get Location, CellID
- Current Operator
- Registration Status
- Technology
2009-09-10 18:19:48 -05:00
Denis Kenzior 422df0edfb change int vendor to unsigned int vendor 2009-09-01 21:39:02 -05:00
Denis Kenzior 271b042488 Add vendor flag capability to netreg 2009-09-01 18:14:58 -05:00
Aki Niemi 4148f82e4e Fix typo in technology name 2009-08-25 10:47:19 +03:00
Denis Kenzior 5b1f5ba084 Evolve the netreg driver 2009-08-19 18:35:07 -05:00
Denis Kenzior 3f17e3eb79 Update network registration to the new SIM API 2009-08-19 18:35:07 -05:00
Denis Kenzior f59aab7f15 Fix whitespace and style issues 2009-08-19 18:35:06 -05:00
Denis Kenzior 95573a4d8d Move network-operator status enum out of common.h 2009-08-17 15:32:34 -05:00
Denis Kenzior 07cca7ab13 Quiet an error if a modem is removed quickly 2009-08-07 20:11:34 -05:00
Denis Kenzior 6db2762d75 Fix segfault upon modem removal due to g_source
Network registration was not removing operator list scan g_source,
which was causing a crash in one of two potential places.
2009-08-07 20:06:05 -05:00
Denis Kenzior f12af3728c Re-enable reading of SPN & PNN on phonesim 2009-08-07 19:51:29 -05:00
Denis Kenzior a7cfcae752 Fix trailing whitespace 2009-08-06 17:24:46 -05:00
Denis Kenzior ba8ef5c3e4 Fix segfault when pnn record doesn't exist 2009-08-04 15:08:08 -05:00
Marcel Holtmann bbc2a56986 Fix over-complicated code flow that results in uninitialized variables 2009-08-03 11:20:46 -07:00
Andrzej Zaborowski fbec2de660 Make sure SIM read callbacks die cleanly. 2009-08-03 12:43:32 -05:00
Denis Kenzior 3e6d4237cb Remove all uses of modem.h 2009-07-29 16:53:19 -05:00
Denis Kenzior 19eeb7f1ba Rename modem_add_interface / modem_remove_interface
Move to ofono_modem_add_interface, ofono_modem_remove_interface
and put in ofono/modem.h
2009-07-29 16:44:16 -05:00
Denis Kenzior 54816de04d Get rid of dbus-gsm.h 2009-07-29 12:26:06 -05:00
Denis Kenzior 9cd9338ba1 Rename dbus_gsm_dict_append_array 2009-07-29 12:26:05 -05:00
Denis Kenzior 6728542a01 Rename dbus_gsm_dict_append 2009-07-29 12:26:05 -05:00
Denis Kenzior d9025e13e1 Move & Rename PROPERTIES_ARRAY_SIGNATURE 2009-07-29 12:26:05 -05:00
Denis Kenzior 55787fe876 Rename dbus_gsm_signal_array_property_changed 2009-07-29 12:26:05 -05:00
Denis Kenzior 684b5be1fc Rename dbus_gsm_signal_property_changed 2009-07-29 12:26:05 -05:00
Denis Kenzior 00fb6cce62 Rename dbus_gsm error functions to __ofono_error 2009-07-29 12:26:05 -05:00
Denis Kenzior 1426d84ad7 Get rid of dbus_gsm_free_string_array
Use g_strfreev instead.
2009-07-29 12:26:04 -05:00
Denis Kenzior 99c1c92708 Move & Rename dbus_gsm_connection
Move to ofono/dbus.h ofono_dbus_get_connection
2009-07-29 12:26:04 -05:00
Andrzej Zaborowski 35c48071f8 Use registration status constants consistently. 2009-07-17 23:48:29 -05:00
Andrzej Zaborowski a5bcab7564 Don't dereference before the null check. 2009-07-17 23:48:29 -05:00
Andrzej Zaborowski da0bdb1cbf Clean-up in sim.c. 2009-07-17 23:48:29 -05:00
Andrzej Zaborowski 983d16ca37 Make PNN / OPL work. 2009-07-17 23:48:28 -05:00
Denis Kenzior f574b5a075 Fix uninitialized warning 2009-07-15 12:10:02 -05:00
Denis Kenzior c0862b7553 Refactor how EONS is used 2009-07-14 15:45:06 -05:00
Denis Kenzior d938e7f300 This function now uses on network_operator_data 2009-07-14 15:45:06 -05:00
Denis Kenzior 8129119d61 Refactor Network Registration for EONS capability 2009-07-14 15:45:06 -05:00
Denis Kenzior 864e09481c Get rid of some div by zero errors 2009-07-14 15:45:06 -05:00
Denis Kenzior 0fa6897213 Refactor OPL code 2009-07-14 15:45:05 -05:00
Denis Kenzior f5e9b2147a Fix CellId data type to be uint32 as intended 2009-07-14 15:45:05 -05:00