453 Commits

Author SHA1 Message Date
Irfan Sheriff
b0c1b80f47 Fix multicast API
Fix multicast API and disable mutlicast V6 packets at driver start

Bug: 5016558
Change-Id: I1e04a905a36045e52c785c1dc702cc246a381a57
2011-07-21 13:37:57 -07:00
Isaac Levy
d7b3e6a39b WifiWatchdogSM notification for first wifi disable
Also moved customizable settings into Settings.Secure and
added listeners for setting changes into the state machine.

Change-Id: Ia6859c71f7edae13062685867959adc423af4643
2011-07-21 10:34:56 -07:00
Isaac Levy
3550ac919c Adding WifiInfo object in CONNECTED broadcast
Adding a parsable wifiinfo object in Connected broadcast, public api.
The connected broadcast only occurs on successful setup on the wifi
interface, so in normal use is very infrequent (once if the wifi
sleeps, or once at new hotspots, etc...)

WifiInfo objects are small, <10 ints, <5 short strings, and contain info
that could be useful to listeners, such as SSID.

The alternative is to the poll the Wifi Manager, using getConnectionInfo.
Because the Wifi Manager can update state in its own thread, polling the
Wifi Manager might result in an info object that's out of sync from the
received broadcast.

Change-Id: Iafcec77f45dd094ea84e6022b7a40e8952ae8137
2011-07-19 16:39:34 -07:00
Isaac Levy
654f509075 WifiWatchdog rewrite to formal statemachine
Rewrote wifiwatchdog service to use net.statemachine

Change-Id: Id6fd42b13192ac2e99f842ff50e9edff1696675d
2011-07-15 12:31:58 -07:00
Wink Saville
8171e6f690 Use resetConnections with resetMask.
Bug: 4981919
Change-Id: I5dec2da0756d5083bc81494fd583672704537694
2011-07-07 16:17:06 -07:00
Irfan Sheriff
6d815e9dd0 Merge "Moved WifiWatchdogService and DnsPinger" 2011-07-06 22:08:38 -07:00
Isaac Levy
a7bc1135c2 Moved WifiWatchdogService and DnsPinger
- Moved WWS and DnsPinger in prep for StateMachine rewrite
 intent.

Change-Id: I912ca80d31ee2ded99eb345a2e5a55d01bd9910c
2011-07-06 13:54:48 -07:00
Ji-Hwan Lee
c4501f7710 Log supplicant restart count correctly
Currently, it's always 0.

Change-Id: I99b2d31e61e1ec7dfffc7a77e04f4059fd6869ef
2011-07-04 14:27:26 +09:00
Irfan Sheriff
cf99765b62 resolved conflicts for merge of 914ed90f to honeycomb-LTE
Change-Id: I616b7ba5c27d0cc4247f5cce4303effe14658e1e
2011-06-22 11:01:16 -07:00
Irfan Sheriff
c74eacde30 resolved conflicts for merge of 267a6181 to honeycomb-LTE
Change-Id: I95d459c937f788ed15f178e85692e1c393bdaa04
2011-06-22 07:11:42 -07:00
Irfan Sheriff
914ed90f2c Revert "DO NOT MERGE Revert "DO NOT MERGE Add DhcpStateMachine""
This reverts commit 58d1bb497e0d83e28a02fbcdc1f33f29a992db7e.
2011-06-21 14:26:37 -07:00
Irfan Sheriff
58d1bb497e DO NOT MERGE Revert "DO NOT MERGE Add DhcpStateMachine"
This reverts commit fe3b33d4ead06c546202753e38188db5e2eaa7fa.

Change-Id: I3a9ae1f0d17e7a154d27d4f3f3eb1efa21a34f64
2011-06-21 11:38:23 -07:00
Irfan Sheriff
f2288c960c Merge "Fix IP address cleanup on network disconnect" 2011-06-17 10:09:36 -07:00
Irfan Sheriff
f5600618df Fix IP address cleanup on network disconnect
We used to bring down the interface on network disconnect
which would in turn clean up all the IP addresses.

The interface bringup/shutdown is now handled by wpa_supplicant.
Add netd interface for clearing all IP addresses

Bug: 4676254
Change-Id: I7e24c0ab2e4a412b8d61e9c33ce028966913aaf6
2011-06-17 10:03:13 -07:00
Irfan Sheriff
e1f9064e35 Fix network state handling
Change I242cda97 introduced a regression where network state
was being modified on any supplicant state change.

Revert the old behavior of only changeing network detailed state
based on supplicant state change in a disconnected state

Bug: 4690073
Change-Id: I927cc5fa36b862cc54661b033939f543cd15d31f
2011-06-16 15:02:17 -07:00
Robert Greenwalt
4f1f7d3158 am 241b65ac: am 5f350512: Merge "Reset connections AFTER we take down the network." into honeycomb-LTE
* commit '241b65aca93e263f0869c5bec4ad1dbda0dec6db':
  Reset connections AFTER we take down the network.
2011-06-16 12:50:46 -07:00
Robert Greenwalt
ec896c6a86 Reset connections AFTER we take down the network.
If you do it before you have a race condition and some apps will
manage to reconnect on the dieing network before it goes and then
get no notification when it goes.

bug: 3408025
Change-Id: I5386ff313c759b3f687bc38731454ab43dbe76b8
2011-06-16 11:26:54 -07:00
Irfan Sheriff
1523da22e9 Fix driver start/stop handling
The driver start and stop events will be removed as they are now
redundant (and incorrect)

Move to using supplicant INTERFACE_DISABLED indication for deciding
if driver has started or stopped

When driver start is given, the supplicant will first switch to
INTERFACE_DISABLED state and then out of it to start connecting.
We should use this indication to find out driver has started

When driver stop is given, the supplicant will just switch to
INTERFACE_DISABLED state and this indicates driver has stopped

Bug: 4550125
Change-Id: I242cda97951a733c8707c8d99cdfcc9a33b75c2d
2011-06-10 17:02:48 -07:00
Irfan Sheriff
680e0a4782 Merge "Remove interface disable in wifistatemachine" 2011-06-09 16:53:27 -07:00
Irfan Sheriff
89f2ea6fc2 Remove interface disable in wifistatemachine
Supplicant now handles interface disable/enable on its own

Change-Id: Ib104989dd49654befff82261cc531b0646c7b15d
2011-06-09 16:42:36 -07:00
Irfan Sheriff
dd65ed25c4 am 92593dc4: am 84db79bb: Merge "Clear IP configuration on lost network" into honeycomb-LTE
* commit '92593dc49b348c4951037a1ae2fa17bb6644ffb9':
  Clear IP configuration on lost network
2011-06-08 17:31:58 -07:00
Irfan Sheriff
0c13d47939 Clear IP configuration on lost network
Bug: 4391449
Change-Id: I574128083a5612f13fcccaf5ed091eae114b7943
2011-06-07 12:29:59 -07:00
Irfan Sheriff
319da8c4c5 Add new states to support wpa_supplicant 0.8
Latest supplicant introduces the INTERFACE_DISABLED state. This
is entered when the interface is brought down (which is effectively
done by us and tracked already through the driver stop operation)

Also, added is a state for tracking authentication when supplicant acts as
the SME

Change-Id: I76090068d0ebba6df76f16707da559fcbd7512c5
2011-06-02 11:18:00 -07:00
Irfan Sheriff
d57f5067e6 am c2ff0e70: am 9a737639: Merge "Clear network id when invalid" into honeycomb-LTE
* commit 'c2ff0e7031b54810d26e1d2a1ba9cdb529f25306':
  Clear network id when invalid
2011-05-24 19:53:04 -07:00
Irfan Sheriff
0a8bd60a8e Clear network id when invalid
Bug: 4391449
Change-Id: If0902a3fe4ad65d34dfc3d60f0e630d5e868d6a9
2011-05-23 17:02:11 -07:00
Irfan Sheriff
e526cfb490 am 5b9ceeba: am a4815c0e: am 9c9088a5: Merge "Move softap config handling to WifiConfigStore" into honeycomb-mr2
* commit '5b9ceebafd36db4491a49c1f00750ce50c4d4433':
  Move softap config handling to WifiConfigStore
2011-05-19 15:17:33 -07:00
Irfan Sheriff
a4815c0ec0 am 9c9088a5: Merge "Move softap config handling to WifiConfigStore" into honeycomb-mr2
* commit '9c9088a54f6dee7a13dcc7a12297137147b01baa':
  Move softap config handling to WifiConfigStore
2011-05-19 14:57:54 -07:00
Irfan Sheriff
ffcea7ae73 Move softap config handling to WifiConfigStore
Move softap config to flat file and read/write on a seperate handler thread

Bug: 4391796

Change-Id: Iafe43200d7f829df7ced20a4e7b0ed451ad22a05
2011-05-18 15:29:31 -07:00
Irfan Sheriff
fe3b33d4ea DO NOT MERGE Add DhcpStateMachine
Add DhcpStateMachine for interation with dhcpcd

- Supports wakeup and renewal on dhcp
- Supports multiple controllers to use the state machine
  simultaneously
- Optionally, a controller can request a notification prior
    to DHCP request/renewal being sent

Change-Id: I5324814b19ff19863aa6fa89f1e3f0a202930c98
2011-05-12 14:10:11 -07:00
Irfan Sheriff
fba19ff5e8 DO NOT MERGE Define Protocol class
Adds a common namespace for communication across
different state machines

Change-Id: Ib6a29715c651371f91a950348a8525275b6026a0
2011-05-06 16:05:53 -07:00
Robert Greenwalt
a8e0dfae06 resolved conflicts for merge of db46fa25 to master
Change-Id: I8df9d5d07588fbd70e417dae567be26f645b74b6
2011-05-02 14:41:57 -07:00
Irfan Sheriff
d713683f9f am d369d64e: am 8ab6a6d4: Merge "Add DhcpStateMachine for interation with dhcpcd" into honeycomb-LTE
* commit 'd369d64ee7931726d479e60e64d76a31fdba4a8f':
  Add DhcpStateMachine for interation with dhcpcd
2011-05-02 13:29:36 -07:00
Robert Greenwalt
a47c40193f Merge "Add RouteInfo objects for tracking routes." into honeycomb-LTE 2011-05-02 13:26:52 -07:00
Robert Greenwalt
aa70f101e0 Add RouteInfo objects for tracking routes.
Used to have list of gateways for default routes, but general static routes
should be supported.

Change-Id: I01730142c6139f2b833b9d48f5381d2d320b69f6
2011-05-02 11:17:30 -07:00
Irfan Sheriff
31be7cf4c7 Add DhcpStateMachine for interation with dhcpcd
- Supports wakeup and renewal on dhcp
- Supports multiple controllers to use the state machine
  simultaneously
- Optionally, a controller can request a notification prior
  to DHCP request/renewal being sent

Change-Id: I3a9d7e6a02ff26be3a86ddca6964683ad3c28f93
2011-04-30 12:58:51 -07:00
Irfan Sheriff
2dbf683b61 am c1f39396: am 8f87f838: Merge "Define Protocol class for use with StateMachine" into honeycomb-LTE
* commit 'c1f39396b94837f728c56b4c3e2f5c37e1d0eef7':
  Define Protocol class for use with StateMachine
2011-04-28 11:52:56 -07:00
Irfan Sheriff
3fc75e9267 Define Protocol class for use with StateMachine
Adds a common namespace for communication across
different state machines

Change-Id: I0a9ae872112567afd35a1dc95ac9283170f3f459
2011-04-28 11:10:03 -07:00
Irfan Sheriff
5cd8d4dece handle supplicant stop after child states exit
When a user explicitly disables wifi, wait on the supplicant shut down until after
all child states have handled exit - this avoids time outs due to communicating with
supplicant after breaking the socket connection

Bug: 4052161

Change-Id: Iec5bb3e14a2df4a8a12de8bb81d9c10aeb992ad4
2011-04-19 07:33:07 -07:00
Wink Saville
343c1ad720 am 37677849: am 64c42cae: Rename HierarchicalStateMachine and HierarchicalState to StateMachine and State.
* commit '37677849998e6c9a39afe0a730b2f0131a371f3b':
  Rename HierarchicalStateMachine and HierarchicalState to StateMachine and State.
2011-04-18 15:28:47 -07:00
Wink Saville
64c42cae44 Rename HierarchicalStateMachine and HierarchicalState to StateMachine and State.
Change-Id: Ib4b33894da75f5f156066092fb145b478e52f7d7
2011-04-18 14:55:10 -07:00
Joe Onorato
43a17654cf Remove the deprecated things from Config.java. These haven't been working since before 1.0.
Change-Id: Ic2e8fa68797ea9d486f4117f3d82c98233cdab1e
2011-04-07 19:23:05 -07:00
Robert Greenwalt
80f7c594fa am f4a29403: resolved conflicts for merge of 70c3d1c2 to honeycomb-plus-aosp
* commit 'f4a29403ae5b6d3e8e754a025d33f0c33adecb21':
  Add external dependency API.
2011-04-07 14:22:03 -07:00
Robert Greenwalt
d55a6b498d Add external dependency API.
An APN will not be connected to if some external dependency is not met.

bug:3486704
Change-Id: I7d94df343b260013efd11faa978deb13f07f1389
2011-04-07 12:28:37 -07:00
Irfan Sheriff
2b7f63887e Add support for supplicant SCAN_INTERVAL
Also, allow scan interval for framework and supplicant
to be configured at build time or run time

Bug: 4144882
Change-Id: I877f4bcc872597b44d3f4da85cf2bc0f16e09444
2011-04-06 09:11:15 -07:00
Kenny Root
d710fb500c Update WakeLock-related docs to mention permissions
android.permission.WAKE_LOCK permission is required to use WakeLock or
WifiLock, but nowhere is it mentioned that you must declare that
permission to use it.

Change-Id: Ib5f5294d37e39169fe5678743f380d95c4e5a842
2011-03-16 09:38:11 -07:00
Irfan Sheriff
4aeca7c590 Backup and restore IP and proxy settings
Bug: 4081954
Change-Id: I27266637c6ade0c5c8242792176d1edae0983446
2011-03-10 16:57:10 -08:00
Irfan Sheriff
84cffa4526 DO NOT MERGE update current config with dhcp settings
After DHCP completes, update the current configured
networks list with the IP setting details

Change-Id: I1ece1eda20224c69a4635bd38fdc5bef15818bb2
2011-03-03 15:00:51 -08:00
Irfan Sheriff
04e04fe333 Merge "fix network disconnection handling" 2011-03-02 15:36:10 -08:00
Irfan Sheriff
9b3710b253 fix network disconnection handling
We should avoid network id set unless the access point is associating.
Also, we should reset network connection state before sending
out network change broadcast.

Finally, we should reset connect mode settings when we disconnect from
an access point

Bug: 3424635
Change-Id: I41db5399810218abd6a77155166db5a9b1dbd22c
2011-03-02 14:45:42 -08:00
Robert Greenwalt
7e48e76cab Merge "Start using NetworkUtils.numericToInetAddress." 2011-03-02 12:10:51 -08:00