Merge b2ginbound to central, a=merge
authorWes Kocher <wkocher@mozilla.com>
Wed, 29 Jul 2015 20:19:12 -0700
changeset 255314 62469b20ec842c2399c409bdc2af0f5e5d3facd2
parent 255289 d3e4f0062531e73b7f2a257ed1913569e70e629c (current diff)
parent 255313 9c3436a4f28bf48f9436f0774e393621815c3898 (diff)
child 255319 785f60f45b98bfef0b2565cfdeced581617c53eb
child 255321 edf65201bdaf6625554d18154206a88334a76b98
child 255366 69b3b57895914bb082331c9567581c1c399cc390
push id29135
push userkwierso@gmail.com
push dateThu, 30 Jul 2015 03:19:18 +0000
treeherdermozilla-central@62469b20ec84 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmerge
milestone42.0a1
first release with
nightly linux32
62469b20ec84 / 42.0a1 / 20150730030208 / files
nightly linux64
62469b20ec84 / 42.0a1 / 20150730030208 / files
nightly mac
62469b20ec84 / 42.0a1 / 20150730030208 / files
nightly win32
62469b20ec84 / 42.0a1 / 20150730030208 / files
nightly win64
62469b20ec84 / 42.0a1 / 20150730030208 / files
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
releases
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Merge b2ginbound to central, a=merge
--- a/b2g/chrome/content/shell.js
+++ b/b2g/chrome/content/shell.js
@@ -196,19 +196,19 @@ var shell = {
     if (this.onlineForCrashReport()) {
       this.submitQueuedCrashes();
       return;
     }
 
     debugCrashReport('Not online, postponing.');
 
     Services.obs.addObserver(function observer(subject, topic, state) {
-      let network = subject.QueryInterface(Ci.nsINetworkInterface);
-      if (network.state == Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED
-          && network.type == Ci.nsINetworkInterface.NETWORK_TYPE_WIFI) {
+      let network = subject.QueryInterface(Ci.nsINetworkInfo);
+      if (network.state == Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED
+          && network.type == Ci.nsINetworkInfo.NETWORK_TYPE_WIFI) {
         shell.submitQueuedCrashes();
 
         Services.obs.removeObserver(observer, topic);
       }
     }, "network-connection-state-changed", false);
   },
 
   get homeURL() {
--- a/b2g/config/aries/sources.xml
+++ b/b2g/config/aries/sources.xml
@@ -10,17 +10,17 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="e862ab9177af664f00b4522e2350f4cb13866d73">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="1b3591a50ed352fc6ddb77462b7b35d0bfa555a3"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="5bb657ada461be666c35f419dbe072ed2ce632fc"/>
--- a/b2g/config/dolphin/sources.xml
+++ b/b2g/config/dolphin/sources.xml
@@ -10,17 +10,17 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="e862ab9177af664f00b4522e2350f4cb13866d73">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="1b3591a50ed352fc6ddb77462b7b35d0bfa555a3"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="5bb657ada461be666c35f419dbe072ed2ce632fc"/>
--- a/b2g/config/emulator-ics/sources.xml
+++ b/b2g/config/emulator-ics/sources.xml
@@ -14,17 +14,17 @@
   <!--original fetch url was git://github.com/apitrace/-->
   <remote fetch="https://git.mozilla.org/external/apitrace" name="apitrace"/>
   <default remote="caf" revision="refs/tags/android-4.0.4_r2.1" sync-j="4"/>
   <!-- Gonk specific things and forks -->
   <project name="platform_build" path="build" remote="b2g" revision="1b0db93fb6b870b03467aff50d6419771ba0d88c">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
   <project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
-  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="platform_hardware_ril" path="hardware/ril" remote="b2g" revision="8bc59310552179f9a8bc6cdd0188e2475df52fb7"/>
   <project name="platform_external_qemu" path="external/qemu" remote="b2g" revision="9d0e5057ee5404a31ec1bf76131cb11336a7c3b6"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="34ea6163f9f0e0122fb0bb03607eccdca31ced7a"/>
   <!-- Stock Android things -->
   <project name="platform/abi/cpp" path="abi/cpp" revision="dd924f92906085b831bf1cbbc7484d3c043d613c"/>
--- a/b2g/config/emulator-jb/sources.xml
+++ b/b2g/config/emulator-jb/sources.xml
@@ -12,17 +12,17 @@
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="660169a3d7e034a892359e39135e8c2785a6ad6f">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="5bb657ada461be666c35f419dbe072ed2ce632fc"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <!-- Stock Android things -->
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.1" path="prebuilts/clang/linux-x86/3.1" revision="5c45f43419d5582949284eee9cef0c43d866e03b"/>
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.2" path="prebuilts/clang/linux-x86/3.2" revision="3748b4168e7bd8d46457d4b6786003bc6a5223ce"/>
--- a/b2g/config/emulator-kk/sources.xml
+++ b/b2g/config/emulator-kk/sources.xml
@@ -10,17 +10,17 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="e862ab9177af664f00b4522e2350f4cb13866d73">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="1b3591a50ed352fc6ddb77462b7b35d0bfa555a3"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="5bb657ada461be666c35f419dbe072ed2ce632fc"/>
--- a/b2g/config/emulator-l/sources.xml
+++ b/b2g/config/emulator-l/sources.xml
@@ -10,17 +10,17 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="07c383a786f188904311a37f6062c2cb84c9b61d">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="1b3591a50ed352fc6ddb77462b7b35d0bfa555a3"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="5bb657ada461be666c35f419dbe072ed2ce632fc"/>
--- a/b2g/config/emulator/sources.xml
+++ b/b2g/config/emulator/sources.xml
@@ -14,17 +14,17 @@
   <!--original fetch url was git://github.com/apitrace/-->
   <remote fetch="https://git.mozilla.org/external/apitrace" name="apitrace"/>
   <default remote="caf" revision="refs/tags/android-4.0.4_r2.1" sync-j="4"/>
   <!-- Gonk specific things and forks -->
   <project name="platform_build" path="build" remote="b2g" revision="1b0db93fb6b870b03467aff50d6419771ba0d88c">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
   <project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
-  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="platform_hardware_ril" path="hardware/ril" remote="b2g" revision="8bc59310552179f9a8bc6cdd0188e2475df52fb7"/>
   <project name="platform_external_qemu" path="external/qemu" remote="b2g" revision="9d0e5057ee5404a31ec1bf76131cb11336a7c3b6"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="34ea6163f9f0e0122fb0bb03607eccdca31ced7a"/>
   <!-- Stock Android things -->
   <project name="platform/abi/cpp" path="abi/cpp" revision="dd924f92906085b831bf1cbbc7484d3c043d613c"/>
--- a/b2g/config/flame-kk/sources.xml
+++ b/b2g/config/flame-kk/sources.xml
@@ -10,17 +10,17 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="e862ab9177af664f00b4522e2350f4cb13866d73">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="1b3591a50ed352fc6ddb77462b7b35d0bfa555a3"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="5bb657ada461be666c35f419dbe072ed2ce632fc"/>
--- a/b2g/config/gaia.json
+++ b/b2g/config/gaia.json
@@ -1,9 +1,9 @@
 {
     "git": {
-        "git_revision": "088f350b39baf8f86c7c1161fd4be178ce822b7b", 
+        "git_revision": "bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8", 
         "remote": "https://git.mozilla.org/releases/gaia.git", 
         "branch": ""
     }, 
-    "revision": "97666dae0fe5da2a0da4f57f41fcb12e9c2fe709", 
+    "revision": "3b5be8b229de20ea6cdcd3089558bf631c184c58", 
     "repo_path": "integration/gaia-central"
 }
--- a/b2g/config/nexus-4/sources.xml
+++ b/b2g/config/nexus-4/sources.xml
@@ -12,17 +12,17 @@
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="660169a3d7e034a892359e39135e8c2785a6ad6f">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="5bb657ada461be666c35f419dbe072ed2ce632fc"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <!-- Stock Android things -->
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.1" path="prebuilts/clang/linux-x86/3.1" revision="5c45f43419d5582949284eee9cef0c43d866e03b"/>
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.2" path="prebuilts/clang/linux-x86/3.2" revision="3748b4168e7bd8d46457d4b6786003bc6a5223ce"/>
--- a/b2g/config/nexus-5-l/sources.xml
+++ b/b2g/config/nexus-5-l/sources.xml
@@ -10,17 +10,17 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="07c383a786f188904311a37f6062c2cb84c9b61d">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="088f350b39baf8f86c7c1161fd4be178ce822b7b"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="bf8565e0c3ad216ccb3f109c17f8a2eb2c42f6b8"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="9f45c1988fe72749f0659409e6e3320fabf7b79a"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="1b3591a50ed352fc6ddb77462b7b35d0bfa555a3"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="657894b4a1dc0a926117f4812e0940229f9f676f"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="5ef30994f4778b4052e58a4383dbe7890048c87e"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <project name="apitrace" path="external/apitrace" remote="apitrace" revision="5bb657ada461be666c35f419dbe072ed2ce632fc"/>
--- a/dom/media/tests/mochitest/network.js
+++ b/dom/media/tests/mochitest/network.js
@@ -20,17 +20,17 @@ function isNetworkReady() {
           SpecialPowers.Ci.nsINetworkInterfaceListService.LIST_NOT_INCLUDE_SUPL_INTERFACES |
           SpecialPowers.Ci.nsINetworkInterfaceListService.LIST_NOT_INCLUDE_IMS_INTERFACES |
           SpecialPowers.Ci.nsINetworkInterfaceListService.LIST_NOT_INCLUDE_DUN_INTERFACES |
           SpecialPowers.Ci.nsINetworkInterfaceListService.LIST_NOT_INCLUDE_FOTA_INTERFACES);
     var num = itfList.getNumberOfInterface();
     for (var i = 0; i < num; i++) {
       var ips = {};
       var prefixLengths = {};
-      var length = itfList.getInterface(i).getAddresses(ips, prefixLengths);
+      var length = itfList.getInterfaceInfo(i).getAddresses(ips, prefixLengths);
 
       for (var j = 0; j < length; j++) {
         var ip = ips.value[j];
         // skip IPv6 address until bug 797262 is implemented
         if (ip.indexOf(":") < 0) {
           info("Network interface is ready with address: " + ip);
           return true;
         }
--- a/dom/mobileconnection/gonk/MobileConnectionService.js
+++ b/dom/mobileconnection/gonk/MobileConnectionService.js
@@ -703,20 +703,20 @@ MobileConnectionProvider.prototype = {
     if (isUpdated && !aBatch) {
       this.deliverListenerEvent("notifyVoiceChanged");
     }
   },
 
   updateDataInfo: function(aNewInfo, aBatch = false) {
     // For the data connection, the `connected` flag indicates whether
     // there's an active data call. We get correct `connected` state here.
-    let active = gNetworkManager.active;
+    let active = gNetworkManager.activeNetworkInfo;
     aNewInfo.connected = false;
     if (active &&
-        active.type === Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE &&
+        active.type === Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE &&
         active.serviceId === this._clientId) {
       aNewInfo.connected = true;
     }
 
     let isUpdated = this._updateConnectionInfo(this.data, aNewInfo);
     if (isUpdated && !aBatch) {
       this.deliverListenerEvent("notifyDataChanged");
     }
@@ -1594,21 +1594,20 @@ MobileConnectionService.prototype = {
       case NS_NETWORK_ACTIVE_CHANGED_TOPIC_ID:
         for (let i = 0; i < this.numItems; i++) {
           let provider = this._providers[i];
           // Update connected flag only.
           provider.updateDataInfo({});
         }
         break;
       case NS_DATA_CALL_ERROR_TOPIC_ID:
-        let network = aSubject;
         try {
-          if (network instanceof Ci.nsIRilNetworkInterface) {
-            let rilNetwork = network.QueryInterface(Ci.nsIRilNetworkInterface);
-            this.notifyDataError(rilNetwork.serviceId, rilNetwork);
+          if (aSubject instanceof Ci.nsIRilNetworkInfo) {
+            let rilInfo = aSubject.QueryInterface(Ci.nsIRilNetworkInfo);
+            this.notifyDataError(rilInfo.serviceId, aData);
           }
         } catch (e) {}
         break;
       case NS_PREFBRANCH_PREFCHANGE_TOPIC_ID:
         if (aData === kPrefRilDebuggingEnabled) {
           this._updateDebugFlag();
         }
         break;
--- a/dom/mobilemessage/gonk/MmsService.js
+++ b/dom/mobilemessage/gonk/MmsService.js
@@ -222,20 +222,20 @@ function MmsConnection(aServiceId) {
 MmsConnection.prototype = {
   QueryInterface: XPCOMUtils.generateQI([Ci.nsIObserver]),
 
   /** MMS proxy settings. */
   mmsc:     "",
   mmsProxy: "",
   mmsPort:  -1,
 
-  setApnSetting: function(network) {
-    this.mmsc = network.mmsc;
-    this.mmsProxy = network.mmsProxy;
-    this.mmsPort = network.mmsPort;
+  setApnSetting: function(networkInfo) {
+    this.mmsc = networkInfo.mmsc;
+    this.mmsProxy = networkInfo.mmsProxy;
+    this.mmsPort = networkInfo.mmsPort;
   },
 
   get proxyInfo() {
     if (!this.mmsProxy) {
       if (DEBUG) debug("getProxyInfo: MMS proxy is not available.");
       return null;
     }
 
@@ -263,18 +263,18 @@ MmsConnection.prototype = {
   pendingCallbacks: null,
 
   /** MMS network connection reference count. */
   refCount: 0,
 
   // cache of hosts to be accessed when this connection is alive.
   hostsToRoute: null,
 
-  // cache of the networkInterface acquired during this connection.
-  networkInterface: null,
+  // cache of the networkInfo acquired during this connection.
+  networkInfo: null,
 
   connectTimer: null,
 
   disconnectTimer: null,
 
   /**
    * Callback when |connectTimer| is timeout or cancelled by shutdown.
    */
@@ -298,24 +298,24 @@ MmsConnection.prototype = {
       return;
     }
 
     let deactivateMmsDataCall = (aError) => {
       if (aError) debug("Failed to removeHostRoute: " + aError);
 
       // Clear cache.
       this.hostsToRoute = [];
-      this.networkInterface = null;
+      this.networkInfo = null;
 
-      this.radioInterface.deactivateDataCallByType(Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_MMS);
+      this.radioInterface.deactivateDataCallByType(Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_MMS);
     };
 
     let promises =
       this.hostsToRoute.map((aHost) => {
-        return gNetworkManager.removeHostRoute(this.networkInterface, aHost);
+        return gNetworkManager.removeHostRoute(this.networkInfo, aHost);
       });
 
     return Promise.all(promises)
       .then(() => deactivateMmsDataCall(),
             (aError) => deactivateMmsDataCall(aError));
   },
 
   init: function() {
@@ -437,17 +437,17 @@ MmsConnection.prototype = {
       // MMS network fails to be connected within a time period.
       this.connectTimer.
         initWithCallback(() => this.flushPendingCallbacks(_HTTP_STATUS_ACQUIRE_TIMEOUT),
                          TIME_TO_BUFFER_MMS_REQUESTS,
                          Ci.nsITimer.TYPE_ONE_SHOT);
 
       // Bug 1059110: Ensure all the initialization are done before setup data call.
       if (DEBUG) debug("acquire: buffer the MMS request and setup the MMS data call.");
-      this.radioInterface.setupDataCallByType(Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_MMS);
+      this.radioInterface.setupDataCallByType(Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_MMS);
 
       return false;
     }
 
     callback(true, _HTTP_STATUS_ACQUIRE_CONNECTION_SUCCESS);
     return true;
   },
 
@@ -489,17 +489,17 @@ MmsConnection.prototype = {
       host = url;
     }
 
     try {
       let uri = Services.io.newURI(host, null, null);
       host = uri.host;
     } catch (e) {}
 
-    return gNetworkManager.addHostRoute(this.networkInterface, host)
+    return gNetworkManager.addHostRoute(this.networkInfo, host)
       .then(() => {
         if (this.hostsToRoute.indexOf(host) < 0) {
           this.hostsToRoute.push(host);
         }
       });
   },
 
   shutdown: function() {
@@ -512,50 +512,50 @@ MmsConnection.prototype = {
     this.onDisconnectTimerTimeout();
   },
 
   // nsIObserver
 
   observe: function(subject, topic, data) {
     switch (topic) {
       case kNetworkConnStateChangedTopic: {
-        // The network for MMS connection must be nsIRilNetworkInterface.
-        if (!(subject instanceof Ci.nsIRilNetworkInterface)) {
+        // The network info for MMS connection must be nsIRilNetworkInfo.
+        if (!(subject instanceof Ci.nsIRilNetworkInfo)) {
           return;
         }
 
         // Check if the network state change belongs to this service.
-        let network = subject.QueryInterface(Ci.nsIRilNetworkInterface);
-        if (network.serviceId != this.serviceId ||
-            network.type != Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_MMS) {
+        let networkInfo = subject.QueryInterface(Ci.nsIRilNetworkInfo);
+        if (networkInfo.serviceId != this.serviceId ||
+            networkInfo.type != Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_MMS) {
           return;
         }
 
         let connected =
-          network.state == Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED;
+          networkInfo.state == Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED;
 
         // Return if the MMS network state doesn't change, where the network
         // state change can come from other non-MMS networks.
         if (connected == this.connected) {
           return;
         }
 
         this.connected = connected;
         if (!this.connected) {
           this.hostsToRoute = [];
-          this.networkInterface = null;
+          this.networkInfo = null;
           return;
         }
 
         // Set up the MMS APN setting based on the connected MMS network,
         // which is going to be used for the HTTP requests later.
-        this.setApnSetting(network);
+        this.setApnSetting(networkInfo);
 
-        // Cache connected network.
-        this.networkInterface = network;
+        // Cache connected network info.
+        this.networkInfo = networkInfo;
 
         if (DEBUG) debug("Got the MMS network connected! Resend the buffered " +
                          "MMS requests: number: " + this.pendingCallbacks.length);
         this.connectTimer.cancel();
         this.flushPendingCallbacks(_HTTP_STATUS_ACQUIRE_CONNECTION_SUCCESS);
         break;
       }
       case NS_XPCOM_SHUTDOWN_OBSERVER_ID: {
@@ -740,17 +740,17 @@ XPCOMUtils.defineLazyGetter(this, "gMmsT
           debug('Failed to start a transaction: ' + aReason);
           mmsConnection.release();
           cancellable.done(_HTTP_STATUS_FAILED_TO_ROUTE, null);
         };
 
         // TODO: |getNetId| will be implemented as a sync call in nsINetworkManager
         //       once Bug 1141903 is landed.
         mmsConnection.ensureRouting(url)
-          .then(() => gNetworkService.getNetId(mmsConnection.networkInterface.name))
+          .then(() => gNetworkService.getNetId(mmsConnection.networkInfo.name))
           .then((netId) => startTransaction(netId))
           .catch((aReason) => onRejected(aReason));
       });
 
       return cancellable;
     },
 
     sendHttpRequest: function(mmsConnection, method, url, istream, proxyFilter,
--- a/dom/network/NetworkStatsService.jsm
+++ b/dom/network/NetworkStatsService.jsm
@@ -21,18 +21,18 @@ Cu.import("resource://gre/modules/Networ
 Cu.import("resource://gre/modules/Timer.jsm");
 
 const NET_NETWORKSTATSSERVICE_CONTRACTID = "@mozilla.org/network/netstatsservice;1";
 const NET_NETWORKSTATSSERVICE_CID = Components.ID("{18725604-e9ac-488a-8aa0-2471e7f6c0a4}");
 
 const TOPIC_BANDWIDTH_CONTROL = "netd-bandwidth-control"
 
 const TOPIC_CONNECTION_STATE_CHANGED = "network-connection-state-changed";
-const NET_TYPE_WIFI = Ci.nsINetworkInterface.NETWORK_TYPE_WIFI;
-const NET_TYPE_MOBILE = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE;
+const NET_TYPE_WIFI = Ci.nsINetworkInfo.NETWORK_TYPE_WIFI;
+const NET_TYPE_MOBILE = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE;
 
 // Networks have different status that NetworkStats API needs to be aware of.
 // Network is present and ready, so NetworkManager provides the whole info.
 const NETWORK_STATUS_READY   = 0;
 // Network is present but hasn't established a connection yet (e.g. SIM that has not
 // enabled 3G since boot).
 const NETWORK_STATUS_STANDBY = 1;
 // Network is not present, but stored in database by the previous connections.
@@ -187,20 +187,20 @@ this.NetworkStatsService = {
   observe: function observe(aSubject, aTopic, aData) {
     switch (aTopic) {
       case TOPIC_CONNECTION_STATE_CHANGED:
 
         // If new interface is registered (notified from NetworkService),
         // the stats are updated for the new interface without waiting to
         // complete the updating period.
 
-        let network = aSubject.QueryInterface(Ci.nsINetworkInterface);
-        debug("Network " + network.name + " of type " + network.type + " status change");
+        let networkInfo = aSubject.QueryInterface(Ci.nsINetworkInfo);
+        debug("Network " + networkInfo.name + " of type " + networkInfo.type + " status change");
 
-        let netId = this.convertNetworkInterface(network);
+        let netId = this.convertNetworkInfo(networkInfo);
         if (!netId) {
           break;
         }
 
         this._updateCurrentAlarm(netId);
 
         debug("NetId: " + netId);
         this.updateStats(netId);
@@ -264,43 +264,43 @@ this.NetworkStatsService = {
                                       NET_TYPE_MOBILE);
         networks[netId] = { id : icc.iccInfo.iccid,
                             type: NET_TYPE_MOBILE };
       }
     }
     return networks;
   },
 
-  convertNetworkInterface: function(aNetwork) {
-    if (aNetwork.type != NET_TYPE_MOBILE &&
-        aNetwork.type != NET_TYPE_WIFI) {
+  convertNetworkInfo: function(aNetworkInfo) {
+    if (aNetworkInfo.type != NET_TYPE_MOBILE &&
+        aNetworkInfo.type != NET_TYPE_WIFI) {
       return null;
     }
 
     let id = '0';
-    if (aNetwork.type == NET_TYPE_MOBILE) {
-      if (!(aNetwork instanceof Ci.nsIRilNetworkInterface)) {
-        debug("Error! Mobile network should be an nsIRilNetworkInterface!");
+    if (aNetworkInfo.type == NET_TYPE_MOBILE) {
+      if (!(aNetworkInfo instanceof Ci.nsIRilNetworkInfo)) {
+        debug("Error! Mobile network should be an nsIRilNetworkInfo!");
         return null;
       }
 
-      let rilNetwork = aNetwork.QueryInterface(Ci.nsIRilNetworkInterface);
+      let rilNetwork = aNetworkInfo.QueryInterface(Ci.nsIRilNetworkInfo);
       id = rilNetwork.iccId;
     }
 
-    let netId = this.getNetworkId(id, aNetwork.type);
+    let netId = this.getNetworkId(id, aNetworkInfo.type);
 
     if (!this._networks[netId]) {
       this._networks[netId] = Object.create(null);
       this._networks[netId].network = { id: id,
-                                        type: aNetwork.type };
+                                        type: aNetworkInfo.type };
     }
 
     this._networks[netId].status = NETWORK_STATUS_READY;
-    this._networks[netId].interfaceName = aNetwork.name;
+    this._networks[netId].interfaceName = aNetworkInfo.name;
     return netId;
   },
 
   getNetworkId: function getNetworkId(aIccId, aNetworkType) {
     return aIccId + '' + aNetworkType;
   },
 
   /* Function to ensure that one network is valid. The network is valid if its status is
@@ -733,20 +733,20 @@ this.NetworkStatsService = {
         aCallback(true, "OK");
       }
     });
   },
 
   /*
    * Function responsible for receiving stats which are not from netd.
    */
-  saveStats: function saveStats(aAppId, aIsInBrowser, aServiceType, aNetwork,
+  saveStats: function saveStats(aAppId, aIsInBrowser, aServiceType, aNetworkInfo,
                                 aTimeStamp, aRxBytes, aTxBytes, aIsAccumulative,
                                 aCallback) {
-    let netId = this.convertNetworkInterface(aNetwork);
+    let netId = this.convertNetworkInfo(aNetworkInfo);
     if (!netId) {
       if (aCallback) {
         aCallback(false, "Invalid network type");
       }
       return;
     }
 
     // Check if |aConnectionType|, |aAppId| and |aServiceType| are valid.
--- a/dom/network/NetworkStatsServiceProxy.js
+++ b/dom/network/NetworkStatsServiceProxy.js
@@ -24,66 +24,66 @@ function NetworkStatsServiceProxy() {
   }
 }
 
 NetworkStatsServiceProxy.prototype = {
   /*
    * Function called in the protocol layer (HTTP, FTP, WebSocket ...etc)
    * to pass the per-app stats to NetworkStatsService.
    */
-  saveAppStats: function saveAppStats(aAppId, aIsInBrowser, aNetwork, aTimeStamp,
+  saveAppStats: function saveAppStats(aAppId, aIsInBrowser, aNetworkInfo, aTimeStamp,
                                       aRxBytes, aTxBytes, aIsAccumulative,
                                       aCallback) {
-    if (!aNetwork) {
+    if (!aNetworkInfo) {
       if (DEBUG) {
-        debug("|aNetwork| is not specified. Failed to save stats. Returning.");
+        debug("|aNetworkInfo| is not specified. Failed to save stats. Returning.");
       }
       return;
     }
 
     if (DEBUG) {
       debug("saveAppStats: " + aAppId + " " + aIsInBrowser + " " +
-            aNetwork.type + " " + aTimeStamp + " " +
+            aNetworkInfo.type + " " + aTimeStamp + " " +
             aRxBytes + " " + aTxBytes + " " + aIsAccumulative);
     }
 
     if (aCallback) {
       aCallback = aCallback.notify;
     }
 
-    NetworkStatsService.saveStats(aAppId, aIsInBrowser, "", aNetwork,
+    NetworkStatsService.saveStats(aAppId, aIsInBrowser, "", aNetworkInfo,
                                   aTimeStamp, aRxBytes, aTxBytes,
                                   aIsAccumulative, aCallback);
   },
 
   /*
    * Function called in the points of different system services
    * to pass the per-service stats to NetworkStatsService.
    */
-  saveServiceStats: function saveServiceStats(aServiceType, aNetwork,
+  saveServiceStats: function saveServiceStats(aServiceType, aNetworkInfo,
                                               aTimeStamp, aRxBytes, aTxBytes,
                                               aIsAccumulative, aCallback) {
-    if (!aNetwork) {
+    if (!aNetworkInfo) {
       if (DEBUG) {
-        debug("|aNetwork| is not specified. Failed to save stats. Returning.");
+        debug("|aNetworkInfo| is not specified. Failed to save stats. Returning.");
       }
       return;
     }
 
     if (DEBUG) {
-      debug("saveServiceStats: " + aServiceType + " " + aNetwork.type + " " +
+      debug("saveServiceStats: " + aServiceType + " " + aNetworkInfo.type + " " +
             aTimeStamp + " " + aRxBytes + " " + aTxBytes + " " +
             aIsAccumulative);
     }
 
     if (aCallback) {
       aCallback = aCallback.notify;
     }
 
-    NetworkStatsService.saveStats(0, false, aServiceType ,aNetwork, aTimeStamp,
+    NetworkStatsService.saveStats(0, false, aServiceType , aNetworkInfo, aTimeStamp,
                                   aRxBytes, aTxBytes, aIsAccumulative,
                                   aCallback);
   },
 
   classID : NETWORKSTATSSERVICEPROXY_CID,
   QueryInterface : XPCOMUtils.generateQI([nsINetworkStatsServiceProxy]),
 }
 
--- a/dom/network/TCPSocket.js
+++ b/dom/network/TCPSocket.js
@@ -180,17 +180,17 @@ TCPSocket.prototype = {
   _trackingNumber: 0,
 
 #ifdef MOZ_WIDGET_GONK
   // Network statistics (Gonk-specific feature)
   _txBytes: 0,
   _rxBytes: 0,
   _appId: Ci.nsIScriptSecurityManager.NO_APP_ID,
   _inBrowser: false,
-  _activeNetwork: null,
+  _activeNetworkInfo: null,
 #endif
 
   // Public accessors.
   get readyState() {
     return this._readyState;
   },
   get binaryType() {
     return this._binaryType;
@@ -369,17 +369,17 @@ TCPSocket.prototype = {
     }
 
     let nssProxy = Cc["@mozilla.org/networkstatsServiceProxy;1"]
                      .getService(Ci.nsINetworkStatsServiceProxy);
     if (!nssProxy) {
       LOG("Error: Ci.nsINetworkStatsServiceProxy service is not available.");
       return;
     }
-    nssProxy.saveAppStats(this._appId, this._inBrowser, this._activeNetwork,
+    nssProxy.saveAppStats(this._appId, this._inBrowser, this._activeNetworkInfo,
                           Date.now(), this._rxBytes, this._txBytes, false);
 
     // Reset the counters once the statistics is saved to NetworkStatsServiceProxy.
     this._txBytes = this._rxBytes = 0;
   },
   // End of helper method for network statistics.
 #endif
 
@@ -611,22 +611,22 @@ TCPSocket.prototype = {
       return that;
     }
 
     let transport = that._transport = this._createTransport(host, port, that._ssl);
     transport.setEventSink(that, Services.tm.currentThread);
     that._initStream(that._binaryType);
 
 #ifdef MOZ_WIDGET_GONK
-    // Set _activeNetwork, which is only required for network statistics.
+    // Set _activeNetworkInfo, which is only required for network statistics.
     // Note that nsINetworkManager, as well as nsINetworkStatsServiceProxy, is
     // Gonk-specific.
     let networkManager = Cc["@mozilla.org/network/manager;1"].getService(Ci.nsINetworkManager);
     if (networkManager) {
-      that._activeNetwork = networkManager.active;
+      that._activeNetworkInfo = networkManager.activeNetworkInfo;
     }
 #endif
 
     return that;
   },
 
   upgradeToSecure: function ts_upgradeToSecure() {
     if (this._readyState !== kOPEN) {
--- a/dom/network/interfaces/nsINetworkStatsServiceProxy.idl
+++ b/dom/network/interfaces/nsINetworkStatsServiceProxy.idl
@@ -1,43 +1,43 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
 * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "nsISupports.idl"
 
-interface nsINetworkInterface;
+interface nsINetworkInfo;
 
 [scriptable, function, uuid(5f821529-1d80-4ab5-a933-4e1b3585b6bc)]
 interface nsINetworkStatsServiceProxyCallback : nsISupports
 {
   /*
    * @param aResult callback result with boolean value
    * @param aMessage message
    */
   void notify(in boolean aResult, in jsval aMessage);
 };
 
-[scriptable, uuid(98fd8f69-784e-4626-aa59-56d6436a3c24)]
+[scriptable, uuid(f4f3e901-e102-499d-9d37-dc9951f52df7)]
 interface nsINetworkStatsServiceProxy : nsISupports
 {
   /*
    * An interface used to record per-app traffic data.
    * @param aAppId app id
    * @param aIsInBrowser true if the iframe element is mozbrowser
    * @param aNetworkInterface network
    * @param aTimeStamp time stamp
    * @param aRxBytes received data amount
    * @param aTxBytes transmitted data amount
    * @param aIsAccumulative is stats accumulative
    * @param aCallback an optional callback
    */
   void saveAppStats(in unsigned long aAppId,
                     in boolean aIsInBrowser,
-                    in nsINetworkInterface aNetwork,
+                    in nsINetworkInfo aNetworkInfo,
                     in unsigned long long aTimeStamp,
                     in unsigned long long aRxBytes,
                     in unsigned long long aTxBytes,
                     in boolean aIsAccumulative,
          [optional] in nsINetworkStatsServiceProxyCallback aCallback);
 
   /*
    * An interface used to record per-system service traffic data.
@@ -45,15 +45,15 @@ interface nsINetworkStatsServiceProxy : 
    * @param aNetworkInterface network
    * @param aTimeStamp time stamp
    * @param aRxBytes received data amount
    * @param aTxBytes transmitted data amount
    * @param aIsAccumulative is stats accumulative
    * @param aCallback an optional callback
    */
   void saveServiceStats(in string aServiceType,
-                        in nsINetworkInterface aNetwork,
+                        in nsINetworkInfo aNetworkInfo,
                         in unsigned long long aTimeStamp,
                         in unsigned long long aRxBytes,
                         in unsigned long long aTxBytes,
                         in boolean aIsAccumulative,
              [optional] in nsINetworkStatsServiceProxyCallback aCallback);
 };
--- a/dom/network/tests/unit_stats/test_networkstats_db.js
+++ b/dom/network/tests/unit_stats/test_networkstats_db.js
@@ -931,17 +931,17 @@ var alarms = [{ id:                null,
 var alarmsDbId = 1;
 
 add_test(function test_addAlarm() {
   // Add alarms[0] -> DB: [ alarms[0] (id: 1) ]
   // Check the insertion is OK.
   netStatsDb.addAlarm(alarms[0], function(error, result) {
     do_check_eq(error, null);
     alarmsDbId = result;
-    netStatsDb.getAlarms(Ci.nsINetworkInterface.NETWORK_TYPE_WIFI, exampleManifestURL, function(error, result) {
+    netStatsDb.getAlarms(Ci.nsINetworkInfo.NETWORK_TYPE_WIFI, exampleManifestURL, function(error, result) {
       do_check_eq(error, null);
       do_check_eq(result.length, 1);
       do_check_eq(result[0].id, alarmsDbId);
       do_check_eq(result[0].networkId, alarms[0].networkId);
       do_check_eq(result[0].absoluteThreshold, alarms[0].absoluteThreshold);
       do_check_eq(result[0].relativeThreshold, alarms[0].relativeThreshold);
       do_check_eq(result[0].data.foo, alarms[0].data.foo);
       run_next_test();
--- a/dom/network/tests/unit_stats/test_networkstats_service.js
+++ b/dom/network/tests/unit_stats/test_networkstats_service.js
@@ -255,29 +255,29 @@ add_test(function test_fireAlarm() {
                 data: null,
                 pageURL: testPageURL,
                 manifestURL: testManifestURL };
 
   // Set wifi status to standby to avoid connecting to netd when adding an alarm.
   NetworkStatsService._networks[wifiId].status = NETWORK_STATUS_STANDBY;
 
   NetworkStatsService._db.addAlarm(alarm, function addSuccessCb(error, newId) {
-    NetworkStatsService._db.getAlarms(Ci.nsINetworkInterface.NETWORK_TYPE_WIFI,
+    NetworkStatsService._db.getAlarms(Ci.nsINetworkInfo.NETWORK_TYPE_WIFI,
                                       testManifestURL, function onGet(error, result) {
       do_check_eq(error, null);
       do_check_eq(result.length, 1);
 
       // Result of getAlarms is based on expected child's data format, so
       // some changes are needed to be able to use it.
       result[0].networkId = wifiId;
       result[0].pageURL = testPageURL;
       result[0].manifestURL = testManifestURL;
 
       NetworkStatsService._fireAlarm(result[0], false);
-      NetworkStatsService._db.getAlarms(Ci.nsINetworkInterface.NETWORK_TYPE_WIFI,
+      NetworkStatsService._db.getAlarms(Ci.nsINetworkInfo.NETWORK_TYPE_WIFI,
                                         testManifestURL, function onGet(error, result) {
         do_check_eq(error, undefined);
         do_check_eq(result.length, 0);
         run_next_test();
       });
     });
   });
 });
--- a/dom/network/tests/unit_stats/test_networkstats_service_proxy.js
+++ b/dom/network/tests/unit_stats/test_networkstats_service_proxy.js
@@ -4,51 +4,50 @@
 const {classes: Cc, interfaces: Ci, utils: Cu, results: Cr} = Components;
 
 Cu.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyServiceGetter(this, "nssProxy",
                                    "@mozilla.org/networkstatsServiceProxy;1",
                                    "nsINetworkStatsServiceProxy");
 
-function mokConvertNetworkInterface() {
-  NetworkStatsService.convertNetworkInterface = function(aNetwork) {
-    if (aNetwork.type != Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE &&
-        aNetwork.type != Ci.nsINetworkInterface.NETWORK_TYPE_WIFI) {
+function mokConvertNetworkInfo() {
+  NetworkStatsService.convertNetworkInfo = function(aNetworkInfo) {
+    if (aNetworkInfo.type != Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE &&
+        aNetworkInfo.type != Ci.nsINetworkInfo.NETWORK_TYPE_WIFI) {
       return null;
     }
 
     let id = '0';
-    if (aNetwork.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE) {
+    if (aNetworkInfo.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE) {
       id = '1234'
     }
 
-    let netId = this.getNetworkId(id, aNetwork.type);
+    let netId = this.getNetworkId(id, aNetworkInfo.type);
 
     if (!this._networks[netId]) {
       this._networks[netId] = Object.create(null);
       this._networks[netId].network = { id: id,
-                                        type: aNetwork.type };
+                                        type: aNetworkInfo.type };
     }
 
     return netId;
   };
 }
 
 add_test(function test_saveAppStats() {
   var cachedStats = NetworkStatsService.cachedStats;
   var timestamp = NetworkStatsService.cachedStatsDate.getTime();
 
-  // Create to fake nsINetworkInterfaces. As nsINetworkInterface can not
-  // be instantiated, these two vars will emulate it by filling the properties
-  // that will be used.
-  var wifi = {type: Ci.nsINetworkInterface.NETWORK_TYPE_WIFI, id: "0"};
-  var mobile = {type: Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE, id: "1234"};
+  // Create to fake nsINetworkInfos. As nsINetworkInfo can not be instantiated,
+  // these two vars will emulate it by filling the properties that will be used.
+  var wifi = {type: Ci.nsINetworkInfo.NETWORK_TYPE_WIFI, id: "0"};
+  var mobile = {type: Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE, id: "1234"};
 
-  // Insert fake mobile network interface in NetworkStatsService
+  // Insert fake mobile network info in NetworkStatsService
   var mobileNetId = NetworkStatsService.getNetworkId(mobile.id, mobile.type);
 
   do_check_eq(Object.keys(cachedStats).length, 0);
 
   nssProxy.saveAppStats(1, false, wifi, timestamp, 10, 20, false,
                         function (success, message) {
     do_check_eq(success, true);
     nssProxy.saveAppStats(1, false, mobile, timestamp, 10, 20, false,
@@ -78,23 +77,22 @@ add_test(function test_saveAppStats() {
       run_next_test();
     });
   });
 });
 
 add_test(function test_saveServiceStats() {
   var timestamp = NetworkStatsService.cachedStatsDate.getTime();
 
-  // Create to fake nsINetworkInterfaces. As nsINetworkInterface can not
-  // be instantiated, these two vars will emulate it by filling the properties
-  // that will be used.
-  var wifi = {type: Ci.nsINetworkInterface.NETWORK_TYPE_WIFI, id: "0"};
-  var mobile = {type: Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE, id: "1234"};
+  // Create to fake nsINetworkInfos. As nsINetworkInfo can not be instantiated,
+  // these two vars will emulate it by filling the properties that will be used.
+  var wifi = {type: Ci.nsINetworkInfo.NETWORK_TYPE_WIFI, id: "0"};
+  var mobile = {type: Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE, id: "1234"};
 
-  // Insert fake mobile network interface in NetworkStatsService
+  // Insert fake mobile network info in NetworkStatsService
   var mobileNetId = NetworkStatsService.getNetworkId(mobile.id, mobile.type);
 
   NetworkStatsService.updateCachedStats(function (success, msg) {
     do_check_eq(success, true);
 
     var cachedStats = NetworkStatsService.cachedStats;
     do_check_eq(Object.keys(cachedStats).length, 0);
 
@@ -133,17 +131,17 @@ add_test(function test_saveServiceStats(
     });
   });
 });
 
 add_test(function test_saveStatsWithDifferentDates() {
   var today = NetworkStatsService.cachedStatsDate;
   var tomorrow = new Date(today.getTime() + (24 * 60 * 60 * 1000));
 
-  var mobile = {type: Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE, id: "1234"};
+  var mobile = {type: Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE, id: "1234"};
 
   NetworkStatsService.updateCachedStats(function (success, message) {
     do_check_eq(success, true);
 
     do_check_eq(Object.keys(NetworkStatsService.cachedStats).length, 0);
     nssProxy.saveAppStats(1, false, mobile, today.getTime(), 10, 20, false,
                           function (success, message) {
       do_check_eq(success, true);
@@ -168,17 +166,17 @@ add_test(function test_saveStatsWithDiff
       });
     });
   });
 });
 
 add_test(function test_saveStatsWithMaxCachedTraffic() {
   var timestamp = NetworkStatsService.cachedStatsDate.getTime();
   var maxtraffic = NetworkStatsService.maxCachedTraffic;
-  var wifi = {type: Ci.nsINetworkInterface.NETWORK_TYPE_WIFI, id: "0"};
+  var wifi = {type: Ci.nsINetworkInfo.NETWORK_TYPE_WIFI, id: "0"};
 
   NetworkStatsService.updateCachedStats(function (success, message) {
     do_check_eq(success, true);
 
     var cachedStats = NetworkStatsService.cachedStats;
     do_check_eq(Object.keys(cachedStats).length, 0);
     nssProxy.saveAppStats(1, false, wifi, timestamp, 10, 20, false,
                           function (success, message) {
@@ -194,21 +192,21 @@ add_test(function test_saveStatsWithMaxC
     });
   });
 });
 
 add_test(function test_saveAppStats() {
   var cachedStats = NetworkStatsService.cachedStats;
   var timestamp = NetworkStatsService.cachedStatsDate.getTime();
 
-  // Create to fake nsINetworkInterfaces. As nsINetworkInterface can not
+  // Create to fake nsINetworkInfo. As nsINetworkInfo can not
   // be instantiated, these two vars will emulate it by filling the properties
   // that will be used.
-  var wifi = {type: Ci.nsINetworkInterface.NETWORK_TYPE_WIFI, id: "0"};
-  var mobile = {type: Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE, id: "1234"};
+  var wifi = {type: Ci.nsINetworkInfo.NETWORK_TYPE_WIFI, id: "0"};
+  var mobile = {type: Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE, id: "1234"};
 
   // Insert fake mobile network interface in NetworkStatsService
   var mobileNetId = NetworkStatsService.getNetworkId(mobile.id, mobile.type);
 
   do_check_eq(Object.keys(cachedStats).length, 0);
 
   nssProxy.saveAppStats(1, false, wifi, timestamp, 10, 20, false, { notify:
                         function (success, message) {
@@ -227,14 +225,14 @@ add_test(function test_saveAppStats() {
   }});
 });
 
 function run_test() {
   do_get_profile();
 
   Cu.import("resource://gre/modules/NetworkStatsService.jsm");
 
-  // Function convertNetworkInterface of NetworkStatsService causes errors when dealing
+  // Function convertNetworkInfo of NetworkStatsService causes errors when dealing
   // with RIL to get the iccid, so overwrite it.
-  mokConvertNetworkInterface();
+  mokConvertNetworkInfo();
 
   run_next_test();
 }
--- a/dom/push/PushServiceWebSocket.jsm
+++ b/dom/push/PushServiceWebSocket.jsm
@@ -1251,34 +1251,34 @@ let PushNetworkInfo = {
     try {
       if (!prefs.get("udp.wakeupEnabled")) {
         debug("UDP support disabled, we do not send any carrier info");
         throw new Error("UDP disabled");
       }
 
       let nm = Cc["@mozilla.org/network/manager;1"]
                  .getService(Ci.nsINetworkManager);
-      if (nm.active &&
-          nm.active.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE) {
+      if (nm.activeNetworkInfo &&
+          nm.activeNetworkInfo.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE) {
         let iccService = Cc["@mozilla.org/icc/iccservice;1"]
                            .getService(Ci.nsIIccService);
         // TODO: Bug 927721 - PushService for multi-sim
         // In Multi-sim, there is more than one client in iccService. Each
         // client represents a icc handle. To maintain backward compatibility
         // with single sim, we always use client 0 for now. Adding support
         // for multiple sim will be addressed in bug 927721, if needed.
         let clientId = 0;
         let icc = iccService.getIccByServiceId(clientId);
         let iccInfo = icc && icc.iccInfo;
         if (iccInfo) {
           debug("Running on mobile data");
 
           let ips = {};
           let prefixLengths = {};
-          nm.active.getAddresses(ips, prefixLengths);
+          nm.activeNetworkInfo.getAddresses(ips, prefixLengths);
 
           return {
             mcc: iccInfo.mcc,
             mnc: iccInfo.mnc,
             ip:  ips.value[0]
           };
         }
       }
--- a/dom/simplepush/PushService.jsm
+++ b/dom/simplepush/PushService.jsm
@@ -1769,32 +1769,33 @@ this.PushService = {
 
     try {
       if (!prefs.get("udp.wakeupEnabled")) {
         debug("UDP support disabled, we do not send any carrier info");
         throw new Error("UDP disabled");
       }
 
       let nm = Cc["@mozilla.org/network/manager;1"].getService(Ci.nsINetworkManager);
-      if (nm.active && nm.active.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE) {
+      if (nm.activeNetworkInfo &&
+          nm.activeNetworkInfo.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE) {
         let iccService = Cc["@mozilla.org/icc/iccservice;1"].getService(Ci.nsIIccService);
         // TODO: Bug 927721 - PushService for multi-sim
         // In Multi-sim, there is more than one client in iccService. Each
         // client represents a icc handle. To maintain backward compatibility
         // with single sim, we always use client 0 for now. Adding support
         // for multiple sim will be addressed in bug 927721, if needed.
         let clientId = 0;
         let icc = iccService.getIccByServiceId(clientId);
         let iccInfo = icc && icc.iccInfo;
         if (iccInfo) {
           debug("Running on mobile data");
 
           let ips = {};
           let prefixLengths = {};
-          nm.active.getAddresses(ips, prefixLengths);
+          nm.activeNetworkInfo.getAddresses(ips, prefixLengths);
 
           return {
             mcc: iccInfo.mcc,
             mnc: iccInfo.mnc,
             ip:  ips.value[0]
           }
         }
       }
--- a/dom/system/gonk/DataCallManager.js
+++ b/dom/system/gonk/DataCallManager.js
@@ -48,38 +48,40 @@ let RILQUIRKS_SUBSCRIPTION_CONTROL =
 let RILQUIRKS_HAVE_IPV6 =
   libcutils.property_get("ro.moz.ril.ipv6", "false") == "true";
 
 const DATACALLMANAGER_CID =
   Components.ID("{35b9efa2-e42c-45ce-8210-0a13e6f4aadc}");
 const DATACALLHANDLER_CID =
   Components.ID("{132b650f-c4d8-4731-96c5-83785cb31dee}");
 const RILNETWORKINTERFACE_CID =
-  Components.ID("{8c11bef9-9b4f-4d96-bed7-f5a1f48eabda}");
+  Components.ID("{9574ee84-5d0d-4814-b9e6-8b279e03dcf4}");
+const RILNETWORKINFO_CID =
+  Components.ID("{dd6cf2f0-f0e3-449f-a69e-7c34fdcb8d4b}");
 
 const TOPIC_XPCOM_SHUTDOWN      = "xpcom-shutdown";
 const TOPIC_MOZSETTINGS_CHANGED = "mozsettings-changed";
 const TOPIC_PREF_CHANGED        = "nsPref:changed";
 const TOPIC_DATA_CALL_ERROR     = "data-call-error";
 const PREF_RIL_DEBUG_ENABLED    = "ril.debugging.enabled";
 
-const NETWORK_TYPE_UNKNOWN     = Ci.nsINetworkInterface.NETWORK_TYPE_UNKNOWN;
-const NETWORK_TYPE_WIFI        = Ci.nsINetworkInterface.NETWORK_TYPE_WIFI;
-const NETWORK_TYPE_MOBILE      = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE;
-const NETWORK_TYPE_MOBILE_MMS  = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_MMS;
-const NETWORK_TYPE_MOBILE_SUPL = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_SUPL;
-const NETWORK_TYPE_MOBILE_IMS  = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_IMS;
-const NETWORK_TYPE_MOBILE_DUN  = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN;
-const NETWORK_TYPE_MOBILE_FOTA = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_FOTA;
+const NETWORK_TYPE_UNKNOWN     = Ci.nsINetworkInfo.NETWORK_TYPE_UNKNOWN;
+const NETWORK_TYPE_WIFI        = Ci.nsINetworkInfo.NETWORK_TYPE_WIFI;
+const NETWORK_TYPE_MOBILE      = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE;
+const NETWORK_TYPE_MOBILE_MMS  = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_MMS;
+const NETWORK_TYPE_MOBILE_SUPL = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_SUPL;
+const NETWORK_TYPE_MOBILE_IMS  = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_IMS;
+const NETWORK_TYPE_MOBILE_DUN  = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN;
+const NETWORK_TYPE_MOBILE_FOTA = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_FOTA;
 
-const NETWORK_STATE_UNKNOWN       = Ci.nsINetworkInterface.NETWORK_STATE_UNKNOWN;
-const NETWORK_STATE_CONNECTING    = Ci.nsINetworkInterface.NETWORK_STATE_CONNECTING;
-const NETWORK_STATE_CONNECTED     = Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED;
-const NETWORK_STATE_DISCONNECTING = Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTING;
-const NETWORK_STATE_DISCONNECTED  = Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED;
+const NETWORK_STATE_UNKNOWN       = Ci.nsINetworkInfo.NETWORK_STATE_UNKNOWN;
+const NETWORK_STATE_CONNECTING    = Ci.nsINetworkInfo.NETWORK_STATE_CONNECTING;
+const NETWORK_STATE_CONNECTED     = Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED;
+const NETWORK_STATE_DISCONNECTING = Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTING;
+const NETWORK_STATE_DISCONNECTED  = Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED;
 
 const INT32_MAX = 2147483647;
 
 // set to true in ril_consts.js to see debug messages
 var DEBUG = RIL.DEBUG_RIL;
 
 function updateDebugFlag() {
   // Read debug setting from pref
@@ -410,17 +412,17 @@ DataCallHandler.prototype = {
       gNetworkManager.unregisterNetworkInterface(networkInterface);
       networkInterface.shutdown();
       networkInterface = null;
     });
     this.dataNetworkInterfaces.clear();
     this._dataCalls = [];
     this.clientId = null;
 
-    this.dataCallinterface.unregisterListener(this);
+    this.dataCallInterface.unregisterListener(this);
     this.dataCallInterface = null;
 
     let mobileConnection =
       gMobileConnectionService.getItemByServiceId(this.clientId);
     mobileConnection.unregisterListener(this);
   },
 
   /**
@@ -620,18 +622,18 @@ DataCallHandler.prototype = {
     if (!isRegistered || !haveDataConnection) {
       if (DEBUG) {
         this.debug("RIL is not ready for data connection: Phone's not " +
                    "registered or doesn't have data connection.");
       }
       return;
     }
     let wifi_active = false;
-    if (gNetworkManager.active &&
-        gNetworkManager.active.type == NETWORK_TYPE_WIFI) {
+    if (gNetworkManager.activeNetworkInfo &&
+        gNetworkManager.activeNetworkInfo.type == NETWORK_TYPE_WIFI) {
       wifi_active = true;
     }
 
     let defaultDataCallConnected = networkInterface.connected;
 
     // We have moved part of the decision making into DataCall, the rest will be
     // moved after Bug 904514 - [meta] NetworkManager enhancement.
     if (networkInterface.enabled &&
@@ -704,17 +706,17 @@ DataCallHandler.prototype = {
       if (DEBUG) this.debug(aNetworkType + " is not a mobile network type!");
       throw Cr.NS_ERROR_INVALID_ARG;
     }
 
     let networkInterface = this.dataNetworkInterfaces.get(aNetworkType);
     if (!networkInterface) {
       return NETWORK_STATE_UNKNOWN;
     }
-    return networkInterface.state;
+    return networkInterface.info.state;
   },
 
   setupDataCallByType: function(aNetworkType) {
     if (DEBUG) {
       this.debug("setupDataCallByType: " + aNetworkType);
     }
 
     if (!this._isMobileNetworkType(aNetworkType)) {
@@ -755,18 +757,18 @@ DataCallHandler.prototype = {
   },
 
   _deactivatingDataCalls: false,
 
   deactivateDataCalls: function(aCallback) {
     let dataDisconnecting = false;
     this.dataNetworkInterfaces.forEach(function(networkInterface) {
       if (networkInterface.enabled) {
-        if (networkInterface.state != NETWORK_STATE_UNKNOWN &&
-            networkInterface.state != NETWORK_STATE_DISCONNECTED) {
+        if (networkInterface.info.state != NETWORK_STATE_UNKNOWN &&
+            networkInterface.info.state != NETWORK_STATE_DISCONNECTED) {
           dataDisconnecting = true;
         }
         networkInterface.disconnect();
       }
     });
 
     this._deactivatingDataCalls = dataDisconnecting;
     if (!dataDisconnecting) {
@@ -831,33 +833,24 @@ DataCallHandler.prototype = {
     }
 
     return -1;
   },
 
   /**
    * Notify about data call setup error, called from DataCall.
    */
-  notifyDataCallError: function(aMessage) {
+  notifyDataCallError: function(aDataCall, aErrorMsg) {
     // Notify data call error only for data APN
     let networkInterface = this.dataNetworkInterfaces.get(NETWORK_TYPE_MOBILE);
     if (networkInterface && networkInterface.enabled) {
       let dataCall = networkInterface.dataCall;
-      // If there is a cid, compare cid; otherwise it is probably an error on
-      // data call setup.
-      if (aMessage.cid !== undefined) {
-        if (aMessage.linkInfo.cid == dataCall.linkInfo.cid) {
-          Services.obs.notifyObservers(networkInterface, TOPIC_DATA_CALL_ERROR,
-                                       null);
-        }
-      } else {
-        if (this._compareDataCallOptions(dataCall, aMessage)) {
-          Services.obs.notifyObservers(networkInterface, TOPIC_DATA_CALL_ERROR,
-                                       null);
-        }
+      if (this._compareDataCallOptions(dataCall, aDataCall)) {
+        Services.obs.notifyObservers(networkInterface.info,
+                                     TOPIC_DATA_CALL_ERROR, aErrorMsg);
       }
     }
   },
 
   /**
    * Notify about data call changed, called from DataCall.
    */
   notifyDataCallChanged: function(aUpdatedDataCall) {
@@ -1060,17 +1053,17 @@ DataCall.prototype = {
       this.state = NETWORK_STATE_DISCONNECTED;
 
       if (this.requestedNetworkIfaces.length === 0) {
         if (DEBUG) this.debug("This DataCall is not requested anymore.");
         return;
       }
 
       // Let DataCallHandler notify MobileConnectionService
-      this.dataCallHandler.notifyDataCallError(this);
+      this.dataCallHandler.notifyDataCallError(this, errorMsg);
 
       // For suggestedRetryTime, the value of INT32_MAX(0x7fffffff) means no retry.
       if (aDataCall.suggestedRetryTime === INT32_MAX ||
           this.isPermanentFail(aDataCall.failCause, errorMsg)) {
         if (DEBUG) this.debug("Data call error: no retry needed.");
         return;
       }
 
@@ -1237,17 +1230,17 @@ DataCall.prototype = {
       return true;
     }
 
     return false;
   },
 
   inRequestedTypes: function(aType) {
     for (let i = 0; i < this.requestedNetworkIfaces.length; i++) {
-      if (this.requestedNetworkIfaces[i].type == aType) {
+      if (this.requestedNetworkIfaces[i].info.type == aType) {
         return true;
       }
     }
     return false;
   },
 
   canHandleApn: function(aApnSetting) {
     let isIdentical = this.apnProfile.apn == aApnSetting.apn &&
@@ -1274,33 +1267,33 @@ DataCall.prototype = {
 
   reset: function() {
     this.resetLinkInfo();
 
     this.state = NETWORK_STATE_UNKNOWN;
   },
 
   connect: function(aNetworkInterface) {
-    if (DEBUG) this.debug("connect: " + aNetworkInterface.type);
+    if (DEBUG) this.debug("connect: " + aNetworkInterface.info.type);
 
     if (this.requestedNetworkIfaces.indexOf(aNetworkInterface) == -1) {
       this.requestedNetworkIfaces.push(aNetworkInterface);
     }
 
     if (this.state == NETWORK_STATE_CONNECTING ||
         this.state == NETWORK_STATE_DISCONNECTING) {
       return;
     }
     if (this.state == NETWORK_STATE_CONNECTED) {
       // This needs to run asynchronously, to behave the same way as the case of
       // non-shared apn, see bug 1059110.
       Services.tm.currentThread.dispatch(() => {
         // Do not notify if state changed while this event was being dispatched,
         // the state probably was notified already or need not to be notified.
-        if (aNetworkInterface.state == RIL.GECKO_NETWORK_STATE_CONNECTED) {
+        if (aNetworkInterface.info.state == RIL.GECKO_NETWORK_STATE_CONNECTED) {
           aNetworkInterface.notifyRILNetworkInterface();
         }
       }, Ci.nsIEventTarget.DISPATCH_NORMAL);
       return;
     }
 
     // If retry mechanism is running on background, stop it since we are going
     // to setup data call now.
@@ -1400,17 +1393,17 @@ DataCall.prototype = {
       // Event timer for connection retries
       this.timer = Cc["@mozilla.org/timer;1"].createInstance(Ci.nsITimer);
     }
     this.timer.initWithCallback(this, apnRetryTimer * 1000,
                                 Ci.nsITimer.TYPE_ONE_SHOT);
   },
 
   disconnect: function(aNetworkInterface) {
-    if (DEBUG) this.debug("disconnect: " + aNetworkInterface.type);
+    if (DEBUG) this.debug("disconnect: " + aNetworkInterface.info.type);
 
     let index = this.requestedNetworkIfaces.indexOf(aNetworkInterface);
     if (index != -1) {
       this.requestedNetworkIfaces.splice(index, 1);
 
       if (this.state == NETWORK_STATE_DISCONNECTED ||
           this.state == NETWORK_STATE_UNKNOWN) {
         if (this.timer) {
@@ -1421,17 +1414,17 @@ DataCall.prototype = {
       }
 
       // Notify the DISCONNECTED event immediately after network interface is
       // removed from requestedNetworkIfaces, to make the DataCall, shared or
       // not, to have the same behavior.
       Services.tm.currentThread.dispatch(() => {
         // Do not notify if state changed while this event was being dispatched,
         // the state probably was notified already or need not to be notified.
-        if (aNetworkInterface.state == RIL.GECKO_NETWORK_STATE_DISCONNECTED) {
+        if (aNetworkInterface.info.state == RIL.GECKO_NETWORK_STATE_DISCONNECTED) {
           aNetworkInterface.notifyRILNetworkInterface();
 
           // Clear link info after notifying NetworkManager.
           if (this.requestedNetworkIfaces.length === 0) {
             this.resetLinkInfo();
           }
         }
       }, Ci.nsIEventTarget.DISPATCH_NORMAL);
@@ -1444,17 +1437,17 @@ DataCall.prototype = {
         this.state != NETWORK_STATE_CONNECTED) {
       return;
     }
 
     this.deactivate();
   },
 
   deactivate: function() {
-    let reason = Ci.nsINetworkInterface.DATACALL_DEACTIVATE_NO_REASON;
+    let reason = Ci.nsIDataCallInterface.DATACALL_DEACTIVATE_NO_REASON;
     if (DEBUG) {
       this.debug("Going to disconnect data connection cid " + this.linkInfo.cid);
     }
 
     let dcInterface = this.dataCallHandler.dataCallInterface;
     dcInterface.deactivateDataCall(this.linkInfo.cid, reason, {
       QueryInterface: XPCOMUtils.generateQI([Ci.nsIDataCallCallback]),
       notifySuccess: () => {
@@ -1476,165 +1469,200 @@ DataCall.prototype = {
   shutdown: function() {
     if (this.timer) {
       this.timer.cancel();
       this.timer = null;
     }
   }
 };
 
-function RILNetworkInterface(aDataCallHandler, aType, aApnSetting, aDataCall) {
-  if (!aDataCall) {
-    throw new Error("No dataCall for RILNetworkInterface: " + type);
-  }
-
-  this.dataCallHandler = aDataCallHandler;
+function RILNetworkInfo(aClientId, aType, aNetworkInterface)
+{
+  this.serviceId = aClientId;
   this.type = aType;
-  this.apnSetting = aApnSetting;
-  this.dataCall = aDataCall;
-
-  this.enabled = false;
-}
 
-RILNetworkInterface.prototype = {
-  classID:   RILNETWORKINTERFACE_CID,
-  classInfo: XPCOMUtils.generateCI({classID: RILNETWORKINTERFACE_CID,
-                                    classDescription: "RILNetworkInterface",
-                                    interfaces: [Ci.nsINetworkInterface,
-                                                 Ci.nsIRilNetworkInterface]}),
-  QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInterface,
-                                         Ci.nsIRilNetworkInterface]),
+  this.networkInterface = aNetworkInterface;
+}
+RILNetworkInfo.prototype = {
+  classID:   RILNETWORKINFO_CID,
+  classInfo: XPCOMUtils.generateCI({classID: RILNETWORKINFO_CID,
+                                    classDescription: "RILNetworkInfo",
+                                    interfaces: [Ci.nsINetworkInfo,
+                                                 Ci.nsIRilNetworkInfo]}),
+  QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInfo,
+                                         Ci.nsIRilNetworkInfo]),
+
+  networkInterface: null,
 
-  // Hold reference to DataCall object which is determined at initilization.
-  dataCall: null,
+  getDataCall: function() {
+    return this.networkInterface.dataCall;
+  },
 
-  // If this RILNetworkInterface type is enabled or not.
-  enabled: null,
+  getApnSetting: function() {
+    return this.networkInterface.apnSetting;
+  },
+
+  debug: function(aMsg) {
+    dump("-*- RILNetworkInfo[" + this.serviceId + ":" + this.type + "]: " +
+         aMsg + "\n");
+  },
 
   /**
-   * nsINetworkInterface Implementation
+   * nsINetworkInfo Implementation
    */
-
   get state() {
-    if (!this.dataCall.inRequestedTypes(this.type)) {
+    let dataCall = this.getDataCall();
+    if (!dataCall.inRequestedTypes(this.type)) {
       return NETWORK_STATE_DISCONNECTED;
     }
-    return this.dataCall.state;
+    return dataCall.state;
   },
 
   type: null,
 
   get name() {
-    return this.dataCall.linkInfo.ifname;
-  },
-
-  get httpProxyHost() {
-    return this.apnSetting.proxy || "";
-  },
-
-  get httpProxyPort() {
-    return this.apnSetting.port || "";
+    return this.getDataCall().linkInfo.ifname;
   },
 
   getAddresses: function(aIps, aPrefixLengths) {
-    let addresses = this.dataCall.linkInfo.addresses;
+    let addresses = this.getDataCall().linkInfo.addresses;
 
     let ips = [];
     let prefixLengths = [];
     for (let i = 0; i < addresses.length; i++) {
       let [ip, prefixLength] = addresses[i].split("/");
       ips.push(ip);
       prefixLengths.push(prefixLength);
     }
 
     aIps.value = ips.slice();
     aPrefixLengths.value = prefixLengths.slice();
 
     return ips.length;
   },
 
   getGateways: function(aCount) {
-    let linkInfo = this.dataCall.linkInfo;
+    let linkInfo = this.getDataCall().linkInfo;
 
     if (aCount) {
       aCount.value = linkInfo.gateways.length;
     }
+
     return linkInfo.gateways.slice();
   },
 
   getDnses: function(aCount) {
-    let linkInfo = this.dataCall.linkInfo;
+    let linkInfo = this.getDataCall().linkInfo;
 
     if (aCount) {
       aCount.value = linkInfo.dnses.length;
     }
+
     return linkInfo.dnses.slice();
   },
 
   /**
-   * nsIRilNetworkInterface Implementation
+   * nsIRilNetworkInfo Implementation
    */
 
-  get serviceId() {
-    return this.dataCallHandler.clientId;
-  },
+  serviceId: 0,
 
   get iccId() {
-    let icc = gIccService.getIccByServiceId(this.dataCallHandler.clientId);
+    let icc = gIccService.getIccByServiceId(this.serviceId);
     let iccInfo = icc && icc.iccInfo;
 
     return iccInfo && iccInfo.iccid;
   },
 
   get mmsc() {
     if (this.type != NETWORK_TYPE_MOBILE_MMS) {
       if (DEBUG) this.debug("Error! Only MMS network can get MMSC.");
       throw Cr.NS_ERROR_UNEXPECTED;
     }
 
-    return this.apnSetting.mmsc || "";
+    return this.getApnSetting().mmsc || "";
   },
 
   get mmsProxy() {
     if (this.type != NETWORK_TYPE_MOBILE_MMS) {
       if (DEBUG) this.debug("Error! Only MMS network can get MMS proxy.");
       throw Cr.NS_ERROR_UNEXPECTED;
     }
 
-    return this.apnSetting.mmsproxy || "";
+    return this.getApnSetting().mmsproxy || "";
   },
 
   get mmsPort() {
     if (this.type != NETWORK_TYPE_MOBILE_MMS) {
       if (DEBUG) this.debug("Error! Only MMS network can get MMS port.");
       throw Cr.NS_ERROR_UNEXPECTED;
     }
 
     // Note: Port 0 is reserved, so we treat it as invalid as well.
     // See http://www.iana.org/assignments/port-numbers
-    return this.apnSetting.mmsport || -1;
+    return this.getApnSetting().mmsport || -1;
+  },
+};
+
+function RILNetworkInterface(aDataCallHandler, aType, aApnSetting, aDataCall) {
+  if (!aDataCall) {
+    throw new Error("No dataCall for RILNetworkInterface: " + type);
+  }
+
+  this.dataCallHandler = aDataCallHandler;
+  this.enabled = false;
+  this.dataCall = aDataCall;
+  this.apnSetting = aApnSetting;
+
+  this.info = new RILNetworkInfo(aDataCallHandler.clientId, aType, this);
+}
+
+RILNetworkInterface.prototype = {
+  classID:   RILNETWORKINTERFACE_CID,
+  classInfo: XPCOMUtils.generateCI({classID: RILNETWORKINTERFACE_CID,
+                                    classDescription: "RILNetworkInterface",
+                                    interfaces: [Ci.nsINetworkInterface]}),
+  QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInterface]),
+
+  // If this RILNetworkInterface type is enabled or not.
+  enabled: null,
+
+  apnSetting: null,
+
+  dataCall: null,
+
+  /**
+   * nsINetworkInterface Implementation
+   */
+
+  info: null,
+
+  get httpProxyHost() {
+    return this.apnSetting.proxy || "";
+  },
+
+  get httpProxyPort() {
+    return this.apnSetting.port || "";
   },
 
   // Helpers
 
   debug: function(aMsg) {
     dump("-*- RILNetworkInterface[" + this.dataCallHandler.clientId + ":" +
-         this.type + "]: " + aMsg + "\n");
+         this.info.type + "]: " + aMsg + "\n");
   },
 
-  apnSetting: null,
-
   get connected() {
-    return this.state == NETWORK_STATE_CONNECTED;
+    return this.info.state == NETWORK_STATE_CONNECTED;
   },
 
   notifyRILNetworkInterface: function() {
     if (DEBUG) {
-      this.debug("notifyRILNetworkInterface type: " + this.type + ", state: " +
-                 this.state);
+      this.debug("notifyRILNetworkInterface type: " + this.info.type +
+                 ", state: " + this.info.state);
     }
 
     gNetworkManager.updateNetworkInterface(this);
   },
 
   connect: function() {
     this.enabled = true;
 
--- a/dom/system/gonk/GonkGPSGeolocationProvider.cpp
+++ b/dom/system/gonk/GonkGPSGeolocationProvider.cpp
@@ -20,17 +20,17 @@
 #include <hardware/gps.h>
 
 #include "mozilla/Constants.h"
 #include "mozilla/Preferences.h"
 #include "mozilla/Services.h"
 #include "nsContentUtils.h"
 #include "nsGeoPosition.h"
 #include "nsIInterfaceRequestorUtils.h"
-#include "nsINetworkManager.h"
+#include "nsINetworkInterface.h"
 #include "nsIObserverService.h"
 #include "nsJSUtils.h"
 #include "nsPrintfCString.h"
 #include "nsServiceManagerUtils.h"
 #include "nsThreadUtils.h"
 #include "prtime.h"
 #include "mozilla/dom/BindingUtils.h"
 #include "mozilla/dom/ScriptSettings.h"
@@ -354,22 +354,22 @@ GonkGPSGeolocationProvider::GetGPSInterf
   return result;
 }
 
 #ifdef MOZ_B2G_RIL
 int32_t
 GonkGPSGeolocationProvider::GetDataConnectionState()
 {
   if (!mRadioInterface) {
-    return nsINetworkInterface::NETWORK_STATE_UNKNOWN;
+    return nsINetworkInfo::NETWORK_STATE_UNKNOWN;
   }
 
   int32_t state;
   mRadioInterface->GetDataCallStateByType(
-    nsINetworkInterface::NETWORK_TYPE_MOBILE_SUPL, &state);
+    nsINetworkInfo::NETWORK_TYPE_MOBILE_SUPL, &state);
   return state;
 }
 
 void
 GonkGPSGeolocationProvider::SetAGpsDataConn(nsAString& aApn)
 {
   MOZ_ASSERT(NS_IsMainThread());
   MOZ_ASSERT(mAGpsInterface);
@@ -378,34 +378,34 @@ GonkGPSGeolocationProvider::SetAGpsDataC
   if (mAGpsRilInterface &&
       mAGpsRilInterface->size >= sizeof(AGpsRilInterface) &&
       mAGpsRilInterface->update_network_availability) {
     hasUpdateNetworkAvailability = true;
   }
 
   int32_t connectionState = GetDataConnectionState();
   NS_ConvertUTF16toUTF8 apn(aApn);
-  if (connectionState == nsINetworkInterface::NETWORK_STATE_CONNECTED) {
+  if (connectionState == nsINetworkInfo::NETWORK_STATE_CONNECTED) {
     // The definition of availability is
     // 1. The device is connected to the home network
     // 2. The device is connected to a foreign network and data
     //    roaming is enabled
     // RIL turns on/off data connection automatically when the data
     // roaming setting changes.
     if (hasUpdateNetworkAvailability) {
       mAGpsRilInterface->update_network_availability(true, apn.get());
     }
 #ifdef AGPS_HAVE_DUAL_APN
     mAGpsInterface->data_conn_open(AGPS_TYPE_SUPL,
                                    apn.get(),
                                    AGPS_APN_BEARER_IPV4);
 #else
     mAGpsInterface->data_conn_open(apn.get());
 #endif
-  } else if (connectionState == nsINetworkInterface::NETWORK_STATE_DISCONNECTED) {
+  } else if (connectionState == nsINetworkInfo::NETWORK_STATE_DISCONNECTED) {
     if (hasUpdateNetworkAvailability) {
       mAGpsRilInterface->update_network_availability(false, apn.get());
     }
 #ifdef AGPS_HAVE_DUAL_APN
     mAGpsInterface->data_conn_closed(AGPS_TYPE_SUPL);
 #else
     mAGpsInterface->data_conn_closed();
 #endif
@@ -445,35 +445,35 @@ void
 GonkGPSGeolocationProvider::RequestDataConnection()
 {
   MOZ_ASSERT(NS_IsMainThread());
 
   if (!mRadioInterface) {
     return;
   }
 
-  if (GetDataConnectionState() == nsINetworkInterface::NETWORK_STATE_CONNECTED) {
+  if (GetDataConnectionState() == nsINetworkInfo::NETWORK_STATE_CONNECTED) {
     // Connection is already established, we don't need to setup again.
     // We just get supl APN and make AGPS data connection state updated.
     RequestSettingValue("ril.supl.apn");
   } else {
-    mRadioInterface->SetupDataCallByType(nsINetworkInterface::NETWORK_TYPE_MOBILE_SUPL);
+    mRadioInterface->SetupDataCallByType(nsINetworkInfo::NETWORK_TYPE_MOBILE_SUPL);
   }
 }
 
 void
 GonkGPSGeolocationProvider::ReleaseDataConnection()
 {
   MOZ_ASSERT(NS_IsMainThread());
 
   if (!mRadioInterface) {
     return;
   }
 
-  mRadioInterface->DeactivateDataCallByType(nsINetworkInterface::NETWORK_TYPE_MOBILE_SUPL);
+  mRadioInterface->DeactivateDataCallByType(nsINetworkInfo::NETWORK_TYPE_MOBILE_SUPL);
 }
 
 void
 GonkGPSGeolocationProvider::RequestSetID(uint32_t flags)
 {
   MOZ_ASSERT(NS_IsMainThread());
 
   if (!mRadioInterface ||
@@ -1005,25 +1005,25 @@ GonkGPSGeolocationProvider::SetHighAccur
   return NS_OK;
 }
 
 namespace {
 int
 ConvertToGpsNetworkType(int aNetworkInterfaceType)
 {
   switch (aNetworkInterfaceType) {
-    case nsINetworkInterface::NETWORK_TYPE_WIFI:
+    case nsINetworkInfo::NETWORK_TYPE_WIFI:
       return AGPS_RIL_NETWORK_TYPE_WIFI;
-    case nsINetworkInterface::NETWORK_TYPE_MOBILE:
+    case nsINetworkInfo::NETWORK_TYPE_MOBILE:
       return AGPS_RIL_NETWORK_TYPE_MOBILE;
-    case nsINetworkInterface::NETWORK_TYPE_MOBILE_MMS:
+    case nsINetworkInfo::NETWORK_TYPE_MOBILE_MMS:
       return AGPS_RIL_NETWORK_TYPE_MOBILE_MMS;
-    case nsINetworkInterface::NETWORK_TYPE_MOBILE_SUPL:
+    case nsINetworkInfo::NETWORK_TYPE_MOBILE_SUPL:
       return AGPS_RIL_NETWORK_TYPE_MOBILE_SUPL;
-    case nsINetworkInterface::NETWORK_TYPE_MOBILE_DUN:
+    case nsINetworkInfo::NETWORK_TYPE_MOBILE_DUN:
       return AGPS_RIL_NETWORK_TTYPE_MOBILE_DUN;
     default:
       NS_WARNING(nsPrintfCString("Unknown network type mapping %d",
                                  aNetworkInterfaceType).get());
       return -1;
   }
 }
 } // namespace
@@ -1032,31 +1032,31 @@ NS_IMETHODIMP
 GonkGPSGeolocationProvider::Observe(nsISupports* aSubject,
                                     const char* aTopic,
                                     const char16_t* aData)
 {
   MOZ_ASSERT(NS_IsMainThread());
 
 #ifdef MOZ_B2G_RIL
   if (!strcmp(aTopic, kNetworkConnStateChangedTopic)) {
-    nsCOMPtr<nsINetworkInterface> iface = do_QueryInterface(aSubject);
-    if (!iface) {
+    nsCOMPtr<nsINetworkInfo> info = do_QueryInterface(aSubject);
+    if (!info) {
       return NS_OK;
     }
-    nsCOMPtr<nsIRilNetworkInterface> rilface = do_QueryInterface(aSubject);
+    nsCOMPtr<nsIRilNetworkInfo> rilInfo = do_QueryInterface(aSubject);
     if (mAGpsRilInterface && mAGpsRilInterface->update_network_state) {
       int32_t state;
       int32_t type;
-      iface->GetState(&state);
-      iface->GetType(&type);
-      bool connected = (state == nsINetworkInterface::NETWORK_STATE_CONNECTED);
+      info->GetState(&state);
+      info->GetType(&type);
+      bool connected = (state == nsINetworkInfo::NETWORK_STATE_CONNECTED);
       bool roaming = false;
       int gpsNetworkType = ConvertToGpsNetworkType(type);
       if (gpsNetworkType >= 0) {
-        if (rilface) {
+        if (rilInfo) {
           do {
             nsCOMPtr<nsIMobileConnectionService> service =
               do_GetService(NS_MOBILE_CONNECTION_SERVICE_CONTRACTID);
             if (!service) {
               break;
             }
 
             nsCOMPtr<nsIMobileConnection> connection;
@@ -1075,17 +1075,17 @@ GonkGPSGeolocationProvider::Observe(nsIS
         mAGpsRilInterface->update_network_state(
           connected,
           gpsNetworkType,
           roaming,
           /* extra_info = */ nullptr);
       }
     }
     // No data connection
-    if (!rilface) {
+    if (!rilInfo) {
       return NS_OK;
     }
 
     RequestSettingValue("ril.supl.apn");
   }
 #endif
 
   if (!strcmp(aTopic, kMozSettingsChangedTopic)) {
--- a/dom/system/gonk/NetworkInterfaceListService.js
+++ b/dom/system/gonk/NetworkInterfaceListService.js
@@ -45,29 +45,27 @@ NetworkInterfaceListService.prototype = 
           excludeFota: (aConditions &
                         Ci.nsINetworkInterfaceListService.
                         LIST_NOT_INCLUDE_FOTA_INTERFACES) != 0
         }
       )[0]);
   }
 };
 
-function FakeNetworkInterface(aAttributes) {
+function FakeNetworkInfo(aAttributes) {
   this.state = aAttributes.state;
   this.type = aAttributes.type;
   this.name = aAttributes.name;
   this.ips = aAttributes.ips;
   this.prefixLengths = aAttributes.prefixLengths;
   this.gateways = aAttributes.gateways;
   this.dnses = aAttributes.dnses;
-  this.httpProxyHost = aAttributes.httpProxyHost;
-  this.httpProxyPort = aAttributes.httpProxyPort;
 }
-FakeNetworkInterface.prototype = {
-  QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInterface]),
+FakeNetworkInfo.prototype = {
+  QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInfo]),
 
   getAddresses: function (ips, prefixLengths) {
     ips.value = this.ips.slice();
     prefixLengths.value = this.prefixLengths.slice();
 
     return this.ips.length;
   },
 
@@ -84,28 +82,28 @@ FakeNetworkInterface.prototype = {
     }
     return this.dnses.slice();
   }
 };
 
 function NetworkInterfaceList (aInterfaceLiterals) {
   this._interfaces = [];
   for (let entry of aInterfaceLiterals) {
-    this._interfaces.push(new FakeNetworkInterface(entry));
+    this._interfaces.push(new FakeNetworkInfo(entry));
   }
 }
 
 NetworkInterfaceList.prototype = {
   QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInterfaceList]),
 
   getNumberOfInterface: function() {
     return this._interfaces.length;
   },
 
-  getInterface: function(index) {
+  getInterfaceInfo: function(index) {
     if (!this._interfaces) {
       return null;
     }
     return this._interfaces[index];
   }
 };
 
 this.NSGetFactory = XPCOMUtils.generateNSGetFactory([NetworkInterfaceListService]);
--- a/dom/system/gonk/NetworkManager.js
+++ b/dom/system/gonk/NetworkManager.js
@@ -11,17 +11,17 @@ Cu.import("resource://gre/modules/Servic
 Cu.import("resource://gre/modules/FileUtils.jsm");
 Cu.import("resource://gre/modules/systemlibs.js");
 Cu.import("resource://gre/modules/Promise.jsm");
 
 const NETWORKMANAGER_CONTRACTID = "@mozilla.org/network/manager;1";
 const NETWORKMANAGER_CID =
   Components.ID("{33901e46-33b8-11e1-9869-f46d04d25bcc}");
 
-const DEFAULT_PREFERRED_NETWORK_TYPE = Ci.nsINetworkInterface.NETWORK_TYPE_WIFI;
+const DEFAULT_PREFERRED_NETWORK_TYPE = Ci.nsINetworkInfo.NETWORK_TYPE_WIFI;
 
 XPCOMUtils.defineLazyGetter(this, "ppmm", function() {
   return Cc["@mozilla.org/parentprocessmessagemanager;1"]
          .getService(Ci.nsIMessageBroadcaster);
 });
 
 XPCOMUtils.defineLazyServiceGetter(this, "gDNSService",
                                    "@mozilla.org/network/dns-service;1",
@@ -80,52 +80,52 @@ updateDebug();
 
 function defineLazyRegExp(obj, name, pattern) {
   obj.__defineGetter__(name, function() {
     delete obj[name];
     return obj[name] = new RegExp(pattern);
   });
 }
 
-function NetworkInterface(aNetwork) {
+function ExtraNetworkInfo(aNetwork) {
   let ips = {};
   let prefixLengths = {};
-  aNetwork.getAddresses(ips, prefixLengths);
+  aNetwork.info.getAddresses(ips, prefixLengths);
 
-  this.state = aNetwork.state;
-  this.type = aNetwork.type;
-  this.name = aNetwork.name;
+  this.state = aNetwork.info.state;
+  this.type = aNetwork.info.type;
+  this.name = aNetwork.info.name;
   this.ips = ips.value;
   this.prefixLengths = prefixLengths.value;
-  this.gateways = aNetwork.getGateways();
-  this.dnses = aNetwork.getDnses();
+  this.gateways = aNetwork.info.getGateways();
+  this.dnses = aNetwork.info.getDnses();
   this.httpProxyHost = aNetwork.httpProxyHost;
   this.httpProxyPort = aNetwork.httpProxyPort;
 }
-NetworkInterface.prototype = {
-  QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInterface]),
-
+ExtraNetworkInfo.prototype = {
   getAddresses: function(aIps, aPrefixLengths) {
     aIps.value = this.ips.slice();
     aPrefixLengths.value = this.prefixLengths.slice();
 
     return this.ips.length;
   },
 
   getGateways: function(aCount) {
     if (aCount) {
       aCount.value = this.gateways.length;
     }
+
     return this.gateways.slice();
   },
 
   getDnses: function(aCount) {
     if (aCount) {
       aCount.value = this.dnses.length;
     }
+
     return this.dnses.slice();
   }
 };
 
 function NetworkInterfaceLinks()
 {
   this.resetLinks();
 }
@@ -226,74 +226,73 @@ NetworkManager.prototype = {
       case "NetworkInterfaceList:ListInterface": {
         let excludeMms = aMsg.json.excludeMms;
         let excludeSupl = aMsg.json.excludeSupl;
         let excludeIms = aMsg.json.excludeIms;
         let excludeDun = aMsg.json.excludeDun;
         let excludeFota = aMsg.json.excludeFota;
         let interfaces = [];
 
-        for each (let i in this.networkInterfaces) {
-          if ((i.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_MMS && excludeMms) ||
-              (i.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_SUPL && excludeSupl) ||
-              (i.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_IMS && excludeIms) ||
-              (i.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN && excludeDun) ||
-              (i.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_FOTA && excludeFota)) {
+        for each (let network in this.networkInterfaces) {
+          let i = network.info;
+          if ((i.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_MMS && excludeMms) ||
+              (i.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_SUPL && excludeSupl) ||
+              (i.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_IMS && excludeIms) ||
+              (i.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN && excludeDun) ||
+              (i.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_FOTA && excludeFota)) {
             continue;
           }
 
           let ips = {};
           let prefixLengths = {};
           i.getAddresses(ips, prefixLengths);
 
           interfaces.push({
             state: i.state,
             type: i.type,
             name: i.name,
             ips: ips.value,
             prefixLengths: prefixLengths.value,
             gateways: i.getGateways(),
-            dnses: i.getDnses(),
-            httpProxyHost: i.httpProxyHost,
-            httpProxyPort: i.httpProxyPort
+            dnses: i.getDnses()
           });
         }
         return interfaces;
       }
     }
   },
 
-  getNetworkId: function(network) {
+  getNetworkId: function(aNetworkInfo) {
     let id = "device";
     try {
-      if (network instanceof Ci.nsIRilNetworkInterface) {
-        let rilNetwork = network.QueryInterface(Ci.nsIRilNetworkInterface);
-        id = "ril" + rilNetwork.serviceId;
+      if (aNetworkInfo instanceof Ci.nsIRilNetworkInfo) {
+        let rilInfo = aNetworkInfo.QueryInterface(Ci.nsIRilNetworkInfo);
+        id = "ril" + rilInfo.serviceId;
       }
     } catch (e) {}
 
-    return id + "-" + network.type;
+    return id + "-" + aNetworkInfo.type;
   },
 
   // nsINetworkManager
 
   registerNetworkInterface: function(network) {
     if (!(network instanceof Ci.nsINetworkInterface)) {
       throw Components.Exception("Argument must be nsINetworkInterface.",
                                  Cr.NS_ERROR_INVALID_ARG);
     }
-    let networkId = this.getNetworkId(network);
+    let networkId = this.getNetworkId(network.info);
     if (networkId in this.networkInterfaces) {
       throw Components.Exception("Network with that type already registered!",
                                  Cr.NS_ERROR_INVALID_ARG);
     }
     this.networkInterfaces[networkId] = network;
     this.networkInterfaceLinks[networkId] = new NetworkInterfaceLinks();
 
-    Services.obs.notifyObservers(network, TOPIC_INTERFACE_REGISTERED, null);
+    Services.obs.notifyObservers(network.info, TOPIC_INTERFACE_REGISTERED, null);
     debug("Network '" + networkId + "' registered.");
   },
 
   _addSubnetRoutes: function(network) {
     let ips = {};
     let prefixLengths = {};
     let length = network.getAddresses(ips, prefixLengths);
     let promises = [];
@@ -311,201 +310,211 @@ NetworkManager.prototype = {
     return Promise.all(promises);
   },
 
   updateNetworkInterface: function(network) {
     if (!(network instanceof Ci.nsINetworkInterface)) {
       throw Components.Exception("Argument must be nsINetworkInterface.",
                                  Cr.NS_ERROR_INVALID_ARG);
     }
-    let networkId = this.getNetworkId(network);
+    let networkId = this.getNetworkId(network.info);
     if (!(networkId in this.networkInterfaces)) {
       throw Components.Exception("No network with that type registered.",
                                  Cr.NS_ERROR_INVALID_ARG);
     }
-    debug("Network " + network.type + "/" + network.name +
-          " changed state to " + network.state);
+    debug("Network " + network.info.type + "/" + network.info.name +
+          " changed state to " + network.info.state);
 
     // Keep a copy of network in case it is modified while we are updating.
-    let networkInterface = new NetworkInterface(network);
+    let extNetworkInfo = new ExtraNetworkInfo(network);
 
     // Note that since Lollipop we need to allocate and initialize
     // something through netd, so we add createNetwork/destroyNetwork
     // to deal with that explicitly.
 
-    switch (networkInterface.state) {
-      case Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED:
+    switch (extNetworkInfo.state) {
+      case Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED:
 
-        this._createNetwork(networkInterface.name)
+        this._createNetwork(extNetworkInfo.name)
           // Remove pre-created default route and let setAndConfigureActive()
           // to set default route only on preferred network
-          .then(() => this._removeDefaultRoute(networkInterface))
+          .then(() => this._removeDefaultRoute(extNetworkInfo))
           // Set DNS server as early as possible to prevent from
           // premature domain name lookup.
-          .then(() => this._setDNS(networkInterface))
+          .then(() => this._setDNS(extNetworkInfo))
           .then(() => {
             // Add host route for data calls
-            if (!this.isNetworkTypeMobile(networkInterface.type)) {
+            if (!this.isNetworkTypeMobile(extNetworkInfo.type)) {
               return;
             }
 
             let currentInterfaceLinks = this.networkInterfaceLinks[networkId];
-            let newLinkRoutes = networkInterface.getDnses().concat(
-              networkInterface.httpProxyHost);
+            let newLinkRoutes = extNetworkInfo.getDnses().concat(
+              extNetworkInfo.httpProxyHost);
             // If gateways have changed, remove all old routes first.
-            return this._handleGateways(networkId, networkInterface.getGateways())
+            return this._handleGateways(networkId, extNetworkInfo.getGateways())
               .then(() => this._updateRoutes(currentInterfaceLinks.linkRoutes,
                                              newLinkRoutes,
-                                             networkInterface.getGateways(),
-                                             networkInterface.name))
+                                             extNetworkInfo.getGateways(),
+                                             extNetworkInfo.name))
               .then(() => currentInterfaceLinks.setLinks(newLinkRoutes,
-                                                         networkInterface.getGateways(),
-                                                         networkInterface.name));
+                                                         extNetworkInfo.getGateways(),
+                                                         extNetworkInfo.name));
           })
           .then(() => {
-            if (networkInterface.type !=
-                Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN) {
+            if (extNetworkInfo.type !=
+                Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN) {
               return;
             }
             // Dun type is a special case where we add the default route to a
             // secondary table.
-            return this.setSecondaryDefaultRoute(networkInterface);
+            return this.setSecondaryDefaultRoute(extNetworkInfo);
           })
-          .then(() => this._addSubnetRoutes(networkInterface))
+          .then(() => this._addSubnetRoutes(extNetworkInfo))
           .then(() => this.setAndConfigureActive())
           .then(() => {
             // Update data connection when Wifi connected/disconnected
-            if (networkInterface.type ==
-                Ci.nsINetworkInterface.NETWORK_TYPE_WIFI && this.mRil) {
+            if (extNetworkInfo.type ==
+                Ci.nsINetworkInfo.NETWORK_TYPE_WIFI && this.mRil) {
               for (let i = 0; i < this.mRil.numRadioInterfaces; i++) {
                 this.mRil.getRadioInterface(i).updateRILNetworkInterface();
               }
             }
 
             // Probing the public network accessibility after routing table is ready
             CaptivePortalDetectionHelper
-              .notify(CaptivePortalDetectionHelper.EVENT_CONNECT, this.active);
+              .notify(CaptivePortalDetectionHelper.EVENT_CONNECT,
+                      this.activeNetworkInfo);
           })
           .then(() => {
             // Notify outer modules like MmsService to start the transaction after
             // the configuration of the network interface is done.
-            Services.obs.notifyObservers(network, TOPIC_CONNECTION_STATE_CHANGED,
-                                         this.convertConnectionType(network));
+            Services.obs.notifyObservers(network.info,
+                                         TOPIC_CONNECTION_STATE_CHANGED,
+                                         this.convertConnectionType(network.info));
           })
           .catch(aError => {
             debug("updateNetworkInterface error: " + aError);
           });
         break;
-      case Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED:
+      case Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED:
         Promise.resolve()
           .then(() => {
-            if (!this.isNetworkTypeMobile(networkInterface.type)) {
+            if (!this.isNetworkTypeMobile(extNetworkInfo.type)) {
               return;
             }
             // Remove host route for data calls
             return this._cleanupAllHostRoutes(networkId);
           })
           .then(() => {
-            if (networkInterface.type !=
-                Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN) {
+            if (extNetworkInfo.type !=
+                Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN) {
               return;
             }
             // Remove secondary default route for dun.
-            return this.removeSecondaryDefaultRoute(networkInterface);
+            return this.removeSecondaryDefaultRoute(extNetworkInfo);
           })
           .then(() => {
-            if (networkInterface.type == Ci.nsINetworkInterface.NETWORK_TYPE_WIFI) {
+            if (extNetworkInfo.type == Ci.nsINetworkInfo.NETWORK_TYPE_WIFI) {
               // Remove routing table in /proc/net/route
-              return this._resetRoutingTable(networkInterface.name);
+              return this._resetRoutingTable(extNetworkInfo.name);
             }
-            if (networkInterface.type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE) {
-              return this._removeDefaultRoute(networkInterface)
+            if (extNetworkInfo.type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE) {
+              return this._removeDefaultRoute(extNetworkInfo)
             }
           })
           .then(() => {
             // Clear http proxy on active network.
-            if (this.active && networkInterface.type == this.active.type) {
+            if (this.activeNetworkInfo &&
+                extNetworkInfo.type == this.activeNetworkInfo.type) {
               this.clearNetworkProxy();
             }
 
             // Abort ongoing captive portal detection on the wifi interface
             CaptivePortalDetectionHelper
-              .notify(CaptivePortalDetectionHelper.EVENT_DISCONNECT, networkInterface);
+              .notify(CaptivePortalDetectionHelper.EVENT_DISCONNECT, extNetworkInfo);
           })
           .then(() => this.setAndConfigureActive())
           .then(() => {
             // Update data connection when Wifi connected/disconnected
-            if (networkInterface.type ==
-                Ci.nsINetworkInterface.NETWORK_TYPE_WIFI && this.mRil) {
+            if (extNetworkInfo.type ==
+                Ci.nsINetworkInfo.NETWORK_TYPE_WIFI && this.mRil) {
               for (let i = 0; i < this.mRil.numRadioInterfaces; i++) {
                 this.mRil.getRadioInterface(i).updateRILNetworkInterface();
               }
             }
           })
-          .then(() => this._destroyNetwork(networkInterface.name))
+          .then(() => this._destroyNetwork(extNetworkInfo.name))
           .then(() => {
             // Notify outer modules like MmsService to start the transaction after
             // the configuration of the network interface is done.
-            Services.obs.notifyObservers(network, TOPIC_CONNECTION_STATE_CHANGED,
-                                         this.convertConnectionType(network));
+            Services.obs.notifyObservers(network.info,
+                                         TOPIC_CONNECTION_STATE_CHANGED,
+                                         this.convertConnectionType(network.info));
           })
           .catch(aError => {
             debug("updateNetworkInterface error: " + aError);
           });
         break;
     }
   },
 
   unregisterNetworkInterface: function(network) {
     if (!(network instanceof Ci.nsINetworkInterface)) {
       throw Components.Exception("Argument must be nsINetworkInterface.",
                                  Cr.NS_ERROR_INVALID_ARG);
     }
-    let networkId = this.getNetworkId(network);
+    let networkId = this.getNetworkId(network.info);
     if (!(networkId in this.networkInterfaces)) {
       throw Components.Exception("No network with that type registered.",
                                  Cr.NS_ERROR_INVALID_ARG);
     }
 
     // This is for in case a network gets unregistered without being
     // DISCONNECTED.
-    if (this.isNetworkTypeMobile(network.type)) {
+    if (this.isNetworkTypeMobile(network.info.type)) {
       this._cleanupAllHostRoutes(networkId);
     }
 
     delete this.networkInterfaces[networkId];
 
-    Services.obs.notifyObservers(network, TOPIC_INTERFACE_UNREGISTERED, null);
+    Services.obs.notifyObservers(network.info, TOPIC_INTERFACE_UNREGISTERED, null);
     debug("Network '" + networkId + "' unregistered.");
   },
 
   _manageOfflineStatus: true,
 
   networkInterfaces: null,
 
   networkInterfaceLinks: null,
 
   _preferredNetworkType: DEFAULT_PREFERRED_NETWORK_TYPE,
   get preferredNetworkType() {
     return this._preferredNetworkType;
   },
   set preferredNetworkType(val) {
-    if ([Ci.nsINetworkInterface.NETWORK_TYPE_WIFI,
-         Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE].indexOf(val) == -1) {
+    if ([Ci.nsINetworkInfo.NETWORK_TYPE_WIFI,
+         Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE].indexOf(val) == -1) {
       throw "Invalid network type";
     }
     this._preferredNetworkType = val;
   },
 
-  active: null,
+  _activeNetwork: null,
+
+  get activeNetworkInfo() {
+    return this._activeNetwork && this._activeNetwork.info;
+  },
+
   _overriddenActive: null,
 
   overrideActive: function(network) {
-    if ([Ci.nsINetworkInterface.NETWORK_TYPE_WIFI,
-         Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE].indexOf(val) == -1) {
+    let type = network.info.type;
+    if ([Ci.nsINetworkInfo.NETWORK_TYPE_WIFI,
+         Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE].indexOf(type) == -1) {
       throw "Invalid network type";
     }
 
     this._overriddenActive = network;
     this.setAndConfigureActive();
   },
 
   _updateRoutes: function(oldLinks, newLinks, gateways, interfaceName) {
@@ -543,90 +552,90 @@ NetworkManager.prototype = {
                                         networkName, aIpAddress,
                                         getMaxPrefixLength(aIpAddress), gateway));
       }
     });
 
     return Promise.all(promises);
   },
 
-  isValidatedNetwork: function(network) {
+  isValidatedNetwork: function(aNetworkInfo) {
     let isValid = false;
     try {
-      isValid = (this.getNetworkId(network) in this.networkInterfaces);
+      isValid = (this.getNetworkId(aNetworkInfo) in this.networkInterfaces);
     } catch (e) {
       debug("Invalid network interface: " + e);
     }
 
     return isValid;
   },
 
-  addHostRoute: function(network, host) {
-    if (!this.isValidatedNetwork(network)) {
-      return Promise.reject("Invalid network interface.");
+  addHostRoute: function(aNetworkInfo, aHost) {
+    if (!this.isValidatedNetwork(aNetworkInfo)) {
+      return Promise.reject("Invalid network info.");
     }
 
-    return this.resolveHostname(network, host)
+    return this.resolveHostname(aNetworkInfo, aHost)
       .then((ipAddresses) => {
         let promises = [];
-        let networkId = this.getNetworkId(network);
+        let networkId = this.getNetworkId(aNetworkInfo);
 
         ipAddresses.forEach((aIpAddress) => {
           let promise =
-            this._setHostRoutes(true, [aIpAddress], network.name, network.getGateways())
+            this._setHostRoutes(true, [aIpAddress], aNetworkInfo.name, aNetworkInfo.getGateways())
               .then(() => this.networkInterfaceLinks[networkId].extraRoutes.push(aIpAddress));
 
           promises.push(promise);
         });
 
         return Promise.all(promises);
       });
   },
 
-  removeHostRoute: function(network, host) {
-    if (!this.isValidatedNetwork(network)) {
-      return Promise.reject("Invalid network interface.");
+  removeHostRoute: function(aNetworkInfo, aHost) {
+    if (!this.isValidatedNetwork(aNetworkInfo)) {
+      return Promise.reject("Invalid network info.");
     }
 
-    return this.resolveHostname(network, host)
+    return this.resolveHostname(aNetworkInfo, aHost)
       .then((ipAddresses) => {
         let promises = [];
-        let networkId = this.getNetworkId(network);
+        let networkId = this.getNetworkId(aNetworkInfo);
 
         ipAddresses.forEach((aIpAddress) => {
           let found = this.networkInterfaceLinks[networkId].extraRoutes.indexOf(aIpAddress);
           if (found < 0) {
             return; // continue
           }
 
           let promise =
-            this._setHostRoutes(false, [aIpAddress], network.name, network.getGateways())
+            this._setHostRoutes(false, [aIpAddress], aNetworkInfo.name, aNetworkInfo.getGateways())
               .then(() => {
                 this.networkInterfaceLinks[networkId].extraRoutes.splice(found, 1);
               }, () => {
                 // We should remove it even if the operation failed.
                 this.networkInterfaceLinks[networkId].extraRoutes.splice(found, 1);
               });
           promises.push(promise);
         });
 
         return Promise.all(promises);
       });
   },
 
   isNetworkTypeSecondaryMobile: function(type) {
-    return (type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_MMS ||
-            type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_SUPL ||
-            type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_IMS ||
-            type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN ||
-            type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_FOTA);
+    return (type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_MMS ||
+            type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_SUPL ||
+            type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_IMS ||
+            type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN ||
+            type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_FOTA);
   },
 
   isNetworkTypeMobile: function(type) {
-    return (type == Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE ||
+    return (type == Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE ||
             this.isNetworkTypeSecondaryMobile(type));
   },
 
   _handleGateways: function(networkId, gateways) {
     let currentNetworkLinks = this.networkInterfaceLinks[networkId];
     if (currentNetworkLinks.gateways.length == 0 ||
         currentNetworkLinks.compareGateways(gateways)) {
       return Promise.resolve();
@@ -760,161 +769,163 @@ NetworkManager.prototype = {
     return Promise.all(promises);
   },
 
   /**
    * Determine the active interface and configure it.
    */
   setAndConfigureActive: function() {
     debug("Evaluating whether active network needs to be changed.");
-    let oldActive = this.active;
+    let oldActive = this._activeNetwork;
 
     if (this._overriddenActive) {
       debug("We have an override for the active network: " +
-            this._overriddenActive.name);
+            this._overriddenActive.info.name);
       // The override was just set, so reconfigure the network.
-      if (this.active != this._overriddenActive) {
-        this.active = this._overriddenActive;
-        this._setDefaultRouteAndProxy(this.active, oldActive);
-        Services.obs.notifyObservers(this.active, TOPIC_ACTIVE_CHANGED, null);
+      if (this._activeNetwork != this._overriddenActive) {
+        this._activeNetwork = this._overriddenActive;
+        this._setDefaultRouteAndProxy(this._activeNetwork, oldActive);
+        Services.obs.notifyObservers(this.activeNetworkInfo,
+                                     TOPIC_ACTIVE_CHANGED, null);
       }
       return;
     }
 
     // The active network is already our preferred type.
-    if (this.active &&
-        this.active.state == Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED &&
-        this.active.type == this._preferredNetworkType) {
+    if (this.activeNetworkInfo &&
+        this.activeNetworkInfo.state == Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED &&
+        this.activeNetworkInfo.type == this._preferredNetworkType) {
       debug("Active network is already our preferred type.");
-      return this._setDefaultRouteAndProxy(this.active, oldActive);
+      return this._setDefaultRouteAndProxy(this._activeNetwork, oldActive);
     }
 
     // Find a suitable network interface to activate.
-    this.active = null;
+    this._activeNetwork = null;
     let anyConnected = false;
 
     for each (let network in this.networkInterfaces) {
-      if (network.state != Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED) {
+      if (network.info.state != Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED) {
         continue;
       }
       anyConnected = true;
 
       // Set active only for default connections.
-      if (network.type != Ci.nsINetworkInterface.NETWORK_TYPE_WIFI &&
-          network.type != Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE) {
+      if (network.info.type != Ci.nsINetworkInfo.NETWORK_TYPE_WIFI &&
+          network.info.type != Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE) {
         continue;
       }
 
-      this.active = network;
-      if (network.type == this.preferredNetworkType) {
-        debug("Found our preferred type of network: " + network.name);
+      this._activeNetwork = network;
+      if (network.info.type == this.preferredNetworkType) {
+        debug("Found our preferred type of network: " + network.info.name);
         break;
       }
     }
 
     return Promise.resolve()
       .then(() => {
-        if (!this.active) {
+        if (!this._activeNetwork) {
           return Promise.resolve();
         }
 
-        return this._setDefaultRouteAndProxy(this.active, oldActive);
+        return this._setDefaultRouteAndProxy(this._activeNetwork, oldActive);
       })
       .then(() => {
-        if (this.active != oldActive) {
-          Services.obs.notifyObservers(this.active, TOPIC_ACTIVE_CHANGED, null);
+        if (this._activeNetwork != oldActive) {
+          Services.obs.notifyObservers(this.activeNetworkInfo,
+                                       TOPIC_ACTIVE_CHANGED, null);
         }
 
         if (this._manageOfflineStatus) {
           Services.io.offline = !anyConnected;
         }
       });
   },
 
-  resolveHostname: function(network, hostname) {
+  resolveHostname: function(aNetworkInfo, aHostname) {
     // Sanity check for null, undefined and empty string... etc.
-    if (!hostname) {
-      return Promise.reject(new Error("hostname is empty: " + hostname));
+    if (!aHostname) {
+      return Promise.reject(new Error("hostname is empty: " + aHostname));
     }
 
-    if (hostname.match(this.REGEXP_IPV4) ||
-        hostname.match(this.REGEXP_IPV6)) {
-      return Promise.resolve([hostname]);
+    if (aHostname.match(this.REGEXP_IPV4) ||
+        aHostname.match(this.REGEXP_IPV6)) {
+      return Promise.resolve([aHostname]);
     }
 
     // Wrap gDNSService.asyncResolveExtended to a promise, which
     // resolves with an array of ip addresses or rejects with
     // the reason otherwise.
     let hostResolveWrapper = aNetId => {
       return new Promise((aResolve, aReject) => {
         // Callback for gDNSService.asyncResolveExtended.
         let onLookupComplete = (aRequest, aRecord, aStatus) => {
           if (!Components.isSuccessCode(aStatus)) {
-            aReject(new Error("Failed to resolve '" + hostname +
+            aReject(new Error("Failed to resolve '" + aHostname +
                               "', with status: " + aStatus));
             return;
           }
 
           let retval = [];
           while (aRecord.hasMore()) {
             retval.push(aRecord.getNextAddrAsString());
           }
 
           if (!retval.length) {
             aReject(new Error("No valid address after DNS lookup!"));
             return;
           }
 
-          debug("hostname is resolved: " + hostname);
+          debug("hostname is resolved: " + aHostname);
           debug("Addresses: " + JSON.stringify(retval));
 
           aResolve(retval);
         };
 
-        debug('Calling gDNSService.asyncResolveExtended: ' + aNetId + ', ' + hostname);
-        gDNSService.asyncResolveExtended(hostname,
+        debug('Calling gDNSService.asyncResolveExtended: ' + aNetId + ', ' + aHostname);
+        gDNSService.asyncResolveExtended(aHostname,
                                          0,
                                          aNetId,
                                          onLookupComplete,
                                          Services.tm.mainThread);
       });
     };
 
     // TODO: |getNetId| will be implemented as a sync call in nsINetworkManager
     //       once Bug 1141903 is landed.
-    return gNetworkService.getNetId(network.name)
+    return gNetworkService.getNetId(aNetworkInfo.name)
       .then(aNetId => hostResolveWrapper(aNetId));
   },
 
-  convertConnectionType: function(network) {
+  convertConnectionType: function(aNetworkInfo) {
     // If there is internal interface change (e.g., MOBILE_MMS, MOBILE_SUPL),
     // the function will return null so that it won't trigger type change event
     // in NetworkInformation API.
-    if (network.type != Ci.nsINetworkInterface.NETWORK_TYPE_WIFI &&
-        network.type != Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE) {
+    if (aNetworkInfo.type != Ci.nsINetworkInfo.NETWORK_TYPE_WIFI &&
+        aNetworkInfo.type != Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE) {
       return null;
     }
 
-    if (network.state == Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED) {
+    if (aNetworkInfo.state == Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED) {
       return CONNECTION_TYPE_NONE;
     }
 
-    switch (network.type) {
-      case Ci.nsINetworkInterface.NETWORK_TYPE_WIFI:
+    switch (aNetworkInfo.type) {
+      case Ci.nsINetworkInfo.NETWORK_TYPE_WIFI:
         return CONNECTION_TYPE_WIFI;
-      case Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE:
+      case Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE:
         return CONNECTION_TYPE_CELLULAR;
     }
   },
 
-  _setDNS: function(aNetwork) {
+  _setDNS: function(aNetworkInfo) {
     return new Promise((aResolve, aReject) => {
-      let dnses = aNetwork.getDnses();
-      let gateways = aNetwork.getGateways();
-      gNetworkService.setDNS(aNetwork.name, dnses.length, dnses,
+      let dnses = aNetworkInfo.getDnses();
+      let gateways = aNetworkInfo.getGateways();
+      gNetworkService.setDNS(aNetworkInfo.name, dnses.length, dnses,
                              gateways.length, gateways, (aError) => {
         if (aError) {
           aReject("setDNS failed");
           return;
         }
         aResolve();
       });
     });
@@ -951,65 +962,66 @@ NetworkManager.prototype = {
           debug("resetRoutingTable failed");
         }
         // Always resolve.
         aResolve();
       });
     });
   },
 
-  _removeDefaultRoute: function(aNetwork) {
+  _removeDefaultRoute: function(aNetworkInfo) {
     return new Promise((aResolve, aReject) => {
-      let gateways = aNetwork.getGateways();
-      gNetworkService.removeDefaultRoute(aNetwork.name, gateways.length,
+      let gateways = aNetworkInfo.getGateways();
+      gNetworkService.removeDefaultRoute(aNetworkInfo.name, gateways.length,
                                          gateways, (aSuccess) => {
         if (!aSuccess) {
           debug("removeDefaultRoute failed");
         }
         // Always resolve.
         aResolve();
       });
     });
   },
 
   _setDefaultRouteAndProxy: function(aNetwork, aOldInterface) {
     return new Promise((aResolve, aReject) => {
-      let gateways = aNetwork.getGateways();
-      let oldInterfaceName = (aOldInterface ? aOldInterface.name : "");
-      gNetworkService.setDefaultRoute(aNetwork.name, gateways.length, gateways,
+      let networkInfo = aNetwork.info;
+      let gateways = networkInfo.getGateways();
+      let oldInterfaceName = (aOldInterface ? aOldInterface.info.name : "");
+      gNetworkService.setDefaultRoute(networkInfo.name, gateways.length, gateways,
                                       oldInterfaceName, (aSuccess) => {
         if (!aSuccess) {
-          gNetworkService.destroyNetwork(aNetwork, function() {
+          gNetworkService.destroyNetwork(networkInfo.name, function() {
             aReject("setDefaultRoute failed");
           });
           return;
         }
         this.setNetworkProxy(aNetwork);
         aResolve();
       });
     });
   },
 
-  setNetworkProxy: function(network) {
+  setNetworkProxy: function(aNetwork) {
     try {
-      if (!network.httpProxyHost || network.httpProxyHost === "") {
+      if (!aNetwork.httpProxyHost || aNetwork.httpProxyHost === "") {
         // Sets direct connection to internet.
         this.clearNetworkProxy();
 
-        debug("No proxy support for " + network.name + " network interface.");
+        debug("No proxy support for " + aNetwork.info.name + " network interface.");
         return;
       }
 
-      debug("Going to set proxy settings for " + network.name + " network interface.");
+      debug("Going to set proxy settings for " + aNetwork.info.name + " network interface.");
 
       // Do not use this proxy server for all protocols.
       Services.prefs.setBoolPref("network.proxy.share_proxy_settings", false);
-      Services.prefs.setCharPref("network.proxy.http", network.httpProxyHost);
-      Services.prefs.setCharPref("network.proxy.ssl", network.httpProxyHost);
-      let port = network.httpProxyPort === 0 ? 8080 : network.httpProxyPort;
+      Services.prefs.setCharPref("network.proxy.http", aNetwork.httpProxyHost);
+      Services.prefs.setCharPref("network.proxy.ssl", aNetwork.httpProxyHost);
+      let port = aNetwork.httpProxyPort === 0 ? 8080 : aNetwork.httpProxyPort;
       Services.prefs.setIntPref("network.proxy.http_port", port);
       Services.prefs.setIntPref("network.proxy.ssl_port", port);
 
       let usePAC;
       try {
         usePAC = Services.prefs.getBoolPref("network.proxy.pac_generator");
       } catch (ex) {}
 
@@ -1017,17 +1029,17 @@ NetworkManager.prototype = {
         Services.prefs.setCharPref("network.proxy.autoconfig_url",
                                    gPACGenerator.generate());
         Services.prefs.setIntPref("network.proxy.type", PROXY_TYPE_PAC);
       } else {
         Services.prefs.setIntPref("network.proxy.type", PROXY_TYPE_MANUAL);
       }
     } catch(ex) {
         debug("Exception " + ex + ". Unable to set proxy setting for " +
-              network.name + " network interface.");
+              aNetwork.info.name + " network interface.");
     }
   },
 
   clearNetworkProxy: function() {
     debug("Going to clear all network proxy.");
 
     Services.prefs.clearUserPref("network.proxy.share_proxy_settings");
     Services.prefs.clearUserPref("network.proxy.http");
@@ -1100,27 +1112,27 @@ let CaptivePortalDetectionHelper = (func
   return {
     EVENT_CONNECT: EVENT_CONNECT,
     EVENT_DISCONNECT: EVENT_DISCONNECT,
     notify: function(eventType, network) {
       switch (eventType) {
         case EVENT_CONNECT:
           // perform captive portal detection on wifi interface
           if (_available && network &&
-              network.type == Ci.nsINetworkInterface.NETWORK_TYPE_WIFI) {
+              network.type == Ci.nsINetworkInfo.NETWORK_TYPE_WIFI) {
             _performDetection(network.name, function() {
               // TODO: bug 837600
               // We can disconnect wifi in here if user abort the login procedure.
             });
           }
 
           break;
         case EVENT_DISCONNECT:
           if (_available &&
-              network.type == Ci.nsINetworkInterface.NETWORK_TYPE_WIFI) {
+              network.type == Ci.nsINetworkInfo.NETWORK_TYPE_WIFI) {
             _abort(network.name);
           }
           break;
       }
     }
   };
 }());
 
--- a/dom/system/gonk/RadioInterfaceLayer.js
+++ b/dom/system/gonk/RadioInterfaceLayer.js
@@ -55,18 +55,18 @@ const kSettingsTimezoneAutoUpdateAvailab
 const NS_PREFBRANCH_PREFCHANGE_TOPIC_ID = "nsPref:changed";
 
 const kPrefRilNumRadioInterfaces = "ril.numRadioInterfaces";
 const kPrefRilDebuggingEnabled = "ril.debugging.enabled";
 
 const RADIO_POWER_OFF_TIMEOUT = 30000;
 const HW_DEFAULT_CLIENT_ID = 0;
 
-const NETWORK_TYPE_WIFI        = Ci.nsINetworkInterface.NETWORK_TYPE_WIFI;
-const NETWORK_TYPE_MOBILE      = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE;
+const NETWORK_TYPE_WIFI        = Ci.nsINetworkInfo.NETWORK_TYPE_WIFI;
+const NETWORK_TYPE_MOBILE      = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE;
 
 // set to true in ril_consts.js to see debug messages
 var DEBUG = RIL.DEBUG_RIL;
 
 function updateDebugFlag() {
   // Read debug setting from pref
   let debugPref;
   try {
@@ -1143,31 +1143,31 @@ RadioInterface.prototype = {
       case kSysClockChangeObserverTopic:
         let offset = parseInt(data, 10);
         if (this._lastNitzMessage) {
           this._lastNitzMessage.receiveTimeInMS += offset;
         }
         this._sntp.updateOffset(offset);
         break;
       case kNetworkConnStateChangedTopic:
-        let network = subject.QueryInterface(Ci.nsINetworkInterface);
-        if (network.state != Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED) {
+        let networkInfo = subject.QueryInterface(Ci.nsINetworkInfo);
+        if (networkInfo.state != Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED) {
           return;
         }
 
         // SNTP can only update when we have mobile or Wifi connections.
-        if (network.type != NETWORK_TYPE_WIFI &&
-            network.type != NETWORK_TYPE_MOBILE) {
+        if (networkInfo.type != NETWORK_TYPE_WIFI &&
+            networkInfo.type != NETWORK_TYPE_MOBILE) {
           return;
         }
 
         // If the network comes from RIL, make sure the RIL service is matched.
-        if (subject instanceof Ci.nsIRilNetworkInterface) {
-          network = subject.QueryInterface(Ci.nsIRilNetworkInterface);
-          if (network.serviceId != this.clientId) {
+        if (subject instanceof Ci.nsIRilNetworkInfo) {
+          networkInfo = subject.QueryInterface(Ci.nsIRilNetworkInfo);
+          if (networkInfo.serviceId != this.clientId) {
             return;
           }
         }
 
         // SNTP won't update unless the SNTP is already expired.
         if (this._sntp.isExpired()) {
           this._sntp.request();
         }
@@ -1237,18 +1237,19 @@ RadioInterface.prototype = {
         this._clockAutoUpdateEnabled = aResult;
         if (!this._clockAutoUpdateEnabled) {
           break;
         }
 
         // Set the latest cached NITZ time if it's available.
         if (this._lastNitzMessage) {
           this.setClockByNitz(this._lastNitzMessage);
-        } else if (gNetworkManager.active && gNetworkManager.active.state ==
-                 Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED) {
+        } else if (gNetworkManager.activeNetworkInfo &&
+                   gNetworkManager.activeNetworkInfo.state ==
+                   Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED) {
           // Set the latest cached SNTP time if it's available.
           if (!this._sntp.isExpired()) {
             this.setClockBySntp(this._sntp.getOffset());
           } else {
             // Or refresh the SNTP.
             this._sntp.request();
           }
         } else {
--- a/dom/system/gonk/TetheringService.js
+++ b/dom/system/gonk/TetheringService.js
@@ -243,17 +243,17 @@ TetheringService.prototype = {
         break;
       case TOPIC_MOZSETTINGS_CHANGED:
         if ("wrappedJSObject" in aSubject) {
           aSubject = aSubject.wrappedJSObject;
         }
         this.handle(aSubject.key, aSubject.value);
         break;
       case TOPIC_CONNECTION_STATE_CHANGED:
-        network = aSubject.QueryInterface(Ci.nsINetworkInterface);
+        network = aSubject.QueryInterface(Ci.nsINetworkInfo);
         debug("Network " + network.type + "/" + network.name +
               " changed state to " + network.state);
         this.onConnectionChanged(network);
         break;
       case TOPIC_XPCOM_SHUTDOWN:
         Services.obs.removeObserver(this, TOPIC_XPCOM_SHUTDOWN);
         Services.obs.removeObserver(this, TOPIC_MOZSETTINGS_CHANGED);
         Services.obs.removeObserver(this, TOPIC_CONNECTION_STATE_CHANGED);
@@ -333,28 +333,28 @@ TetheringService.prototype = {
 
     this.tetheringSettings[SETTINGS_WIFI_DHCPSERVER_STARTIP] = DEFAULT_WIFI_DHCPSERVER_STARTIP;
     this.tetheringSettings[SETTINGS_WIFI_DHCPSERVER_ENDIP]   = DEFAULT_WIFI_DHCPSERVER_ENDIP;
 
     this.tetheringSettings[SETTINGS_DUN_REQUIRED] =
       libcutils.property_get("ro.tethering.dun_required") === "1";
   },
 
-  getNetworkInterface: function(aType, aServiceId) {
-    for each (let network in gNetworkManager.networkInterfaces) {
-      if (network.type == aType) {
+  getNetworkInfo: function(aType, aServiceId) {
+    for each (let networkInfo in gNetworkManager.allNetworkInfo) {
+      if (networkInfo.type == aType) {
         try {
-          if (network instanceof Ci.nsIRilNetworkInterface) {
-            let rilNetwork = network.QueryInterface(Ci.nsIRilNetworkInterface);
+          if (networkInfo instanceof Ci.nsIRilNetworkInfo) {
+            let rilNetwork = networkInfo.QueryInterface(Ci.nsIRilNetworkInfo);
             if (rilNetwork.serviceId != aServiceId) {
               continue;
             }
           }
         } catch (e) {}
-        return network;
+        return networkInfo;
       }
     }
     return null;
   },
 
   handleLastUsbTetheringRequest: function() {
     debug('handleLastUsbTetheringRequest... ' + this._usbTetheringRequestCount);
 
@@ -400,17 +400,17 @@ TetheringService.prototype = {
     this.dunRetryTimer.cancel();
     let connection =
       gMobileConnectionService.getItemByServiceId(this._dataDefaultServiceId);
     let data = connection && connection.data;
     if (data && data.state === "registered") {
       let ril = gRil.getRadioInterface(this._dataDefaultServiceId);
 
       this.dunRetryTimes = 0;
-      ril.setupDataCallByType(Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN);
+      ril.setupDataCallByType(Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN);
       this.dunConnectTimer.cancel();
       this.dunConnectTimer.
         initWithCallback(this.onDunConnectTimerTimeout.bind(this),
                          MOBILE_DUN_CONNECT_TIMEOUT, Ci.nsITimer.TYPE_ONE_SHOT);
       return;
     }
 
     if (this.dunRetryTimes++ >= this.MOBILE_DUN_MAX_RETRIES) {
@@ -425,40 +425,40 @@ TetheringService.prototype = {
     this.dunRetryTimer.
       initWithCallback(this.setupDunConnection.bind(this),
                        MOBILE_DUN_RETRY_INTERVAL, Ci.nsITimer.TYPE_ONE_SHOT);
   },
 
   _dunActiveUsers: 0,
   handleDunConnection: function(aEnable, aCallback) {
     debug("handleDunConnection: " + aEnable);
-    let dun = this.getNetworkInterface(
-      Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN, this._dataDefaultServiceId);
+    let dun = this.getNetworkInfo(
+      Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN, this._dataDefaultServiceId);
 
     if (!aEnable) {
       this._dunActiveUsers--;
       if (this._dunActiveUsers > 0) {
         debug("Dun still needed by others, do not disconnect.")
         return;
       }
 
       this.dunRetryTimes = 0;
       this.dunRetryTimer.cancel();
       this.dunConnectTimer.cancel();
       this._pendingTetheringRequests = [];
 
-      if (dun && (dun.state == Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED)) {
+      if (dun && (dun.state == Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED)) {
         gRil.getRadioInterface(this._dataDefaultServiceId)
-          .deactivateDataCallByType(Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN);
+          .deactivateDataCallByType(Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN);
       }
       return;
     }
 
     this._dunActiveUsers++;
-    if (!dun || (dun.state != Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED)) {
+    if (!dun || (dun.state != Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED)) {
       debug("DUN data call inactive, setup dun data call!")
       this._pendingTetheringRequests.push(aCallback);
       this.dunRetryTimes = 0;
       this.setupDunConnection();
 
       return;
     }
 
@@ -490,33 +490,34 @@ TetheringService.prototype = {
       gNetworkService.enableUsbRndis(false, this.enableUsbRndisResult.bind(this));
       return;
     }
 
     this.tetheringSettings[SETTINGS_USB_ENABLED] = true;
     this._usbTetheringAction = TETHERING_STATE_ONGOING;
 
     if (this.tetheringSettings[SETTINGS_DUN_REQUIRED]) {
-      this.handleDunConnection(true, (aNetwork) => {
-        if (!aNetwork){
+      this.handleDunConnection(true, (aNetworkInfo) => {
+        if (!aNetworkInfo){
           this.usbTetheringResultReport(aEnable, "Dun connection failed");
           return;
         }
-        this._tetheringInterface[TETHERING_TYPE_USB].externalInterface = aNetwork.name;
+        this._tetheringInterface[TETHERING_TYPE_USB].externalInterface =
+          aNetworkInfo.name;
         gNetworkService.enableUsbRndis(true, this.enableUsbRndisResult.bind(this));
       });
       return;
     }
 
-    if (gNetworkManager.active) {
+    if (gNetworkManager.activeNetworkInfo) {
       this._tetheringInterface[TETHERING_TYPE_USB].externalInterface =
-        gNetworkManager.active.name;
+        gNetworkManager.activeNetworkInfo.name;
     } else {
-      let mobile = this.getNetworkInterface(
-        Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE, this._dataDefaultServiceId);
+      let mobile = this.getNetworkInfo(
+        Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE, this._dataDefaultServiceId);
       if (mobile && mobile.name) {
         this._tetheringInterface[TETHERING_TYPE_USB].externalInterface = mobile.name;
       }
     }
     gNetworkService.enableUsbRndis(true, this.enableUsbRndisResult.bind(this));
   },
 
   getUSBTetheringParameters: function(aEnable, aTetheringInterface) {
@@ -594,20 +595,20 @@ TetheringService.prototype = {
       if (this._usbTetheringRequestCount > 0) {
         debug('Perform pending USB tethering requests.');
         this.handleLastUsbTetheringRequest();
       }
     });
   },
 
   // Enable/disable WiFi tethering by sending commands to netd.
-  setWifiTethering: function(aEnable, aNetwork, aConfig, aCallback) {
+  setWifiTethering: function(aEnable, aInterfaceName, aConfig, aCallback) {
     debug("setWifiTethering: " + aEnable);
-    if (!aNetwork) {
-      this.notifyError(true, aCallback, "invalid network information");
+    if (!aInterfaceName) {
+      this.notifyError(true, aCallback, "invalid network interface name");
       return;
     }
 
     if (!aConfig) {
       this.notifyError(true, aCallback, "invalid configuration");
       return;
     }
 
@@ -625,32 +626,34 @@ TetheringService.prototype = {
     this.tetheringSettings[SETTINGS_DUN_REQUIRED] =
       libcutils.property_get("ro.tethering.dun_required") === "1";
 
     if (!aEnable) {
       this.enableWifiTethering(false, aConfig, aCallback);
       return;
     }
 
-    this._tetheringInterface[TETHERING_TYPE_WIFI].internalInterface = aNetwork.name;
+    this._tetheringInterface[TETHERING_TYPE_WIFI].internalInterface =
+      aInterfaceName;
 
     if (this.tetheringSettings[SETTINGS_DUN_REQUIRED]) {
-      this.handleDunConnection(true, (aNetwork) => {
-        if (!aNetwork) {
+      this.handleDunConnection(true, (aNetworkInfo) => {
+        if (!aNetworkInfo) {
           this.notifyError(true, aCallback, "Dun connection failed");
           return;
         }
-        this._tetheringInterface[TETHERING_TYPE_WIFI].externalInterface = aNetwork.name;
+        this._tetheringInterface[TETHERING_TYPE_WIFI].externalInterface =
+          aNetworkInfo.name;
         this.enableWifiTethering(true, aConfig, aCallback);
       });
       return;
     }
 
-    let mobile = this.getNetworkInterface(
-      Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE, this._dataDefaultServiceId);
+    let mobile = this.getNetworkInfo(
+      Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE, this._dataDefaultServiceId);
     // Update the real interface name
     if (mobile && mobile.name) {
       this._tetheringInterface[TETHERING_TYPE_WIFI].externalInterface = mobile.name;
     }
 
     this.enableWifiTethering(true, aConfig, aCallback);
   },
 
@@ -740,67 +743,67 @@ TetheringService.prototype = {
     if (aSuccess) {
       // Update the external interface.
       this._tetheringInterface[TETHERING_TYPE_USB].externalInterface =
         aExternalIfname;
       debug("Change the interface name to " + aExternalIfname);
     }
   },
 
-  onConnectionChanged: function(aNetwork) {
-    if (aNetwork.state != Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED) {
+  onConnectionChanged: function(aNetworkInfo) {
+    if (aNetworkInfo.state != Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED) {
       debug("We are only interested in CONNECTED event");
       return;
     }
 
     if (this.tetheringSettings[SETTINGS_DUN_REQUIRED] &&
-        aNetwork.type === Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN) {
+        aNetworkInfo.type === Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN) {
       this.dunConnectTimer.cancel();
       debug("DUN data call connected, process callbacks.");
       while (this._pendingTetheringRequests.length > 0) {
         let callback = this._pendingTetheringRequests.shift();
         if (typeof callback === 'function') {
-          callback(aNetwork);
+          callback(aNetworkInfo);
         }
       }
       return;
     }
 
     if (!this.tetheringSettings[SETTINGS_USB_ENABLED]) {
       debug("Usb tethering settings is not enabled");
       return;
     }
 
     if (this.tetheringSettings[SETTINGS_DUN_REQUIRED] &&
-        aNetwork.type === Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN &&
+        aNetworkInfo.type === Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN &&
         this._tetheringInterface[TETHERING_TYPE_USB].externalInterface ===
-        aNetwork.name) {
+        aNetworkInfo.name) {
       debug("Dun required and dun interface is the same");
       return;
     }
 
     if (this._tetheringInterface[TETHERING_TYPE_USB].externalInterface ===
-        gNetworkManager.active.name) {
+        gNetworkManager.activeNetworkInfo.name) {
       debug("The active interface is the same");
       return;
     }
 
     let previous = {
       internalIfname: this._tetheringInterface[TETHERING_TYPE_USB].internalInterface,
       externalIfname: this._tetheringInterface[TETHERING_TYPE_USB].externalInterface
     };
 
     let current = {
       internalIfname: this._tetheringInterface[TETHERING_TYPE_USB].internalInterface,
-      externalIfname: aNetwork.name
+      externalIfname: aNetworkInfo.name
     };
 
     let callback = (() => {
       // Update external network interface.
-      debug("Update upstream interface to " + aNetwork.name);
+      debug("Update upstream interface to " + aNetworkInfo.name);
       gNetworkService.updateUpStream(previous, current,
                                      this.onConnectionChangedReport.bind(this));
     });
 
     if (this._usbTetheringAction === TETHERING_STATE_ONGOING) {
       debug("Postpone the event and handle it when state is idle.");
       this.wantConnectionEvent = callback;
       return;
--- a/dom/system/gonk/moz.build
+++ b/dom/system/gonk/moz.build
@@ -11,16 +11,17 @@
 # Unless required by applicable law or agreed to in writing, software
 # distributed under the License is distributed on an "AS IS" BASIS,
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
 XPIDL_SOURCES += [
     'nsIAudioManager.idl',
+    'nsINetworkInterface.idl',
     'nsINetworkInterfaceListService.idl',
     'nsINetworkManager.idl',
     'nsINetworkService.idl',
     'nsINetworkWorker.idl',
     'nsISystemWorkerManager.idl',
     'nsITetheringService.idl',
     'nsIVolume.idl',
     'nsIVolumeMountLock.idl',
--- a/dom/system/gonk/nsIDataCallManager.idl
+++ b/dom/system/gonk/nsIDataCallManager.idl
@@ -1,17 +1,17 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "nsISupports.idl"
-#include "nsINetworkManager.idl"
+#include "nsINetworkInterface.idl"
 
-[scriptable, uuid(b8ce8528-fce8-4b5e-9d0a-c3247296ccaf)]
-interface nsIRilNetworkInterface : nsINetworkInterface
+[scriptable, uuid(501b7041-0754-4ddb-9174-946e2c2ebd83)]
+interface nsIRilNetworkInfo : nsINetworkInfo
 {
   readonly attribute unsigned long serviceId;
   readonly attribute DOMString iccId;
 
   /* The following attributes are for MMS proxy settings. */
   readonly attribute DOMString mmsc;     // Empty string if not set.
   readonly attribute DOMString mmsProxy; // Empty string if not set.
   readonly attribute long      mmsPort;  // -1 if not set.
new file mode 100644
--- /dev/null
+++ b/dom/system/gonk/nsINetworkInterface.idl
@@ -0,0 +1,100 @@
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this file,
+ * You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+#include "nsISupports.idl"
+
+[scriptable, uuid(f439ab5d-64bd-4a6c-8863-30235fa784d2)]
+interface nsINetworkInfo : nsISupports
+{
+  const long NETWORK_STATE_UNKNOWN       = -1;
+  const long NETWORK_STATE_CONNECTING    = 0;
+  const long NETWORK_STATE_CONNECTED     = 1;
+  const long NETWORK_STATE_DISCONNECTING = 2;
+  const long NETWORK_STATE_DISCONNECTED  = 3;
+
+  /**
+   * Current network state, one of the NETWORK_STATE_* constants.
+   *
+   * When this changes, network interface implementations notify with
+   * updateNetworkInterface() API.
+   */
+  readonly attribute long state;
+
+  const long NETWORK_TYPE_UNKNOWN     = -1;
+  const long NETWORK_TYPE_WIFI        = 0;
+  const long NETWORK_TYPE_MOBILE      = 1;
+  const long NETWORK_TYPE_MOBILE_MMS  = 2;
+  const long NETWORK_TYPE_MOBILE_SUPL = 3;
+  const long NETWORK_TYPE_WIFI_P2P    = 4;
+  const long NETWORK_TYPE_MOBILE_IMS  = 5;
+  const long NETWORK_TYPE_MOBILE_DUN  = 6;
+  const long NETWORK_TYPE_MOBILE_FOTA = 7;
+
+  /**
+   * Network type. One of the NETWORK_TYPE_* constants.
+   */
+  readonly attribute long type;
+
+  /**
+   * Interface name of the network interface this network info belongs to.
+   */
+  readonly attribute DOMString name;
+
+  /**
+   * Get the list of ip addresses and prefix lengths, ip address could be IPv4
+   * or IPv6, typically 1 IPv4 or 1 IPv6 or one of each.
+   *
+   * @param ips
+   *        The list of ip addresses retrieved.
+   * @param prefixLengths
+   *        The list of prefix lengths retrieved.
+   *
+   * @returns the length of the lists.
+   */
+  void getAddresses([array, size_is(count)] out wstring ips,
+                    [array, size_is(count)] out unsigned long prefixLengths,
+                    [retval] out unsigned long count);
+
+  /**
+   * Get the list of gateways, could be IPv4 or IPv6, typically 1 IPv4 or 1
+   * IPv6 or one of each.
+   *
+   * @param count
+   *        The length of the list of gateways
+   *
+   * @returns the list of gateways.
+   */
+  void getGateways([optional] out unsigned long count,
+                   [array, size_is(count), retval] out wstring gateways);
+
+  /**
+   * Get the list of dnses, could be IPv4 or IPv6.
+   *
+   * @param count
+   *        The length of the list of dnses.
+   *
+   * @returns the list of dnses.
+   */
+  void getDnses([optional] out unsigned long count,
+                [array, size_is(count), retval] out wstring dnses);
+};
+
+[scriptable, uuid(9a025351-8684-4ab5-a0c1-f21a9f83d405)]
+interface nsINetworkInterface : nsISupports
+{
+  /**
+   * The network information about this network interface.
+   */
+  readonly attribute nsINetworkInfo info;
+
+  /**
+   * The host name of the http proxy server.
+   */
+  readonly attribute DOMString httpProxyHost;
+
+  /*
+   * The port number of the http proxy server.
+   */
+  readonly attribute long httpProxyPort;
+};
--- a/dom/system/gonk/nsINetworkInterfaceListService.idl
+++ b/dom/system/gonk/nsINetworkInterfaceListService.idl
@@ -1,28 +1,29 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#include "nsINetworkManager.idl"
 #include "nsISupports.idl"
 
-[scriptable, uuid(b44d74db-c9d6-41dd-98ae-a56918d6e6ad)]
+interface nsINetworkInfo;
+
+[scriptable, uuid(55779d32-1e28-4f43-af87-09d04bc3cce9)]
 interface nsINetworkInterfaceList : nsISupports
 {
   /**
    * Number of the network interfaces that is available.
    */
   long getNumberOfInterface();
 
   /**
-   * Get the i-th interface from the list.
+   * Get the i-th interface info info from the list.
    * @param interfaceIndex index of interface, from 0 to number of interface - 1.
    */
-  nsINetworkInterface getInterface(in long interfaceIndex);
+  nsINetworkInfo getInterfaceInfo(in long interfaceIndex);
 };
 
 [scriptable, uuid(21d7fc8b-28c4-4a4f-a15e-1f9defbc2cec)]
 interface nsINetworkInterfaceListService : nsISupports
 {
   const long LIST_NOT_INCLUDE_MMS_INTERFACES  = (1 << 0);
   const long LIST_NOT_INCLUDE_SUPL_INTERFACES = (1 << 1);
   const long LIST_NOT_INCLUDE_IMS_INTERFACES  = (1 << 2);
--- a/dom/system/gonk/nsINetworkManager.idl
+++ b/dom/system/gonk/nsINetworkManager.idl
@@ -1,107 +1,21 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "nsISupports.idl"
 
-/**
- * Information about networks that is exposed to network manager API consumers.
- */
-[scriptable, uuid(12da2bfd-0801-40d9-9c2e-768868526065)]
-interface nsINetworkInterface : nsISupports
-{
-  const long NETWORK_STATE_UNKNOWN = -1;
-  const long NETWORK_STATE_CONNECTING = 0;
-  const long NETWORK_STATE_CONNECTED = 1;
-  const long NETWORK_STATE_DISCONNECTING = 2;
-  const long NETWORK_STATE_DISCONNECTED = 3;
-
-  /**
-   * Current network state, one of the NETWORK_STATE_* constants.
-   *
-   * When this changes, network interface implementations notify with
-   * updateNetworkInterface() API.
-   */
-  readonly attribute long state;
-
-  const long NETWORK_TYPE_UNKNOWN     = -1;
-  const long NETWORK_TYPE_WIFI        = 0;
-  const long NETWORK_TYPE_MOBILE      = 1;
-  const long NETWORK_TYPE_MOBILE_MMS  = 2;
-  const long NETWORK_TYPE_MOBILE_SUPL = 3;
-  const long NETWORK_TYPE_WIFI_P2P    = 4;
-  const long NETWORK_TYPE_MOBILE_IMS  = 5;
-  const long NETWORK_TYPE_MOBILE_DUN  = 6;
-  const long NETWORK_TYPE_MOBILE_FOTA = 7;
-
-  /**
-   * Network type. One of the NETWORK_TYPE_* constants.
-   */
-  readonly attribute long type;
-
-  /**
-   * Name of the network interface. This identifier is unique.
-   */
-  readonly attribute DOMString name;
-
-  /**
-   * The host name of the http proxy server.
-   */
-  readonly attribute DOMString httpProxyHost;
-
-  /*
-   * The port number of the http proxy server.
-   */
-  readonly attribute long httpProxyPort;
-
-  /**
-   * Get the list of ip addresses and prefix lengths, ip address could be IPv4
-   * or IPv6, typically 1 IPv4 or 1 IPv6 or one of each.
-   *
-   * @param ips
-   *        The list of ip addresses retrieved.
-   * @param prefixLengths
-   *        The list of prefix lengths retrieved.
-   *
-   * @returns the length of the lists.
-   */
-  void getAddresses([array, size_is(count)] out wstring ips,
-                    [array, size_is(count)] out unsigned long prefixLengths,
-                    [retval] out unsigned long count);
-
-  /**
-   * Get the list of gateways, could be IPv4 or IPv6, typically 1 IPv4 or 1
-   * IPv6 or one of each.
-   *
-   * @param count
-   *        The length of the list of gateways
-   *
-   * @returns the list of gateways.
-   */
-  void getGateways([optional] out unsigned long count,
-                   [array, size_is(count), retval] out wstring gateways);
-
-  /**
-   * Get the list of dnses, could be IPv4 or IPv6.
-   *
-   * @param count
-   *        The length of the list of dnses.
-   *
-   * @returns the list of dnses.
-   */
-  void getDnses([optional] out unsigned long count,
-                [array, size_is(count), retval] out wstring dnses);
-};
+interface nsINetworkInfo;
+interface nsINetworkInterface;
 
 /**
  * Manage network interfaces.
  */
-[scriptable, uuid(b0ab71bf-4b38-4796-8a3c-4141255f4259)]
+[scriptable, uuid(e5ffe335-078e-4b25-87f1-02429bd2e458)]
 interface nsINetworkManager : nsISupports
 {
   /**
    * Register the given network interface with the network manager.
    *
    * Consumers will be notified with the 'network-interface-registered'
    * observer notification.
    *
@@ -136,40 +50,41 @@ interface nsINetworkManager : nsISupport
    * registered.
    *
    * @param network
    *        Network interface to unregister.
    */
   void unregisterNetworkInterface(in nsINetworkInterface network);
 
   /**
-   * Object containing all known network connections, keyed by their
+   * Object containing all known network information, keyed by their
    * network id. Network id is composed of a sub-id + '-' + network
    * type. For mobile network types, sub-id is 'ril' + service id; for
    * non-mobile network types, sub-id is always 'device'.
    */
-  readonly attribute jsval networkInterfaces;
+  readonly attribute jsval allNetworkInfo;
 
   /**
    * The preferred network type. One of the
    * nsINetworkInterface::NETWORK_TYPE_* constants.
    *
    * This attribute is used for setting default route to favor
    * interfaces with given type.  This can be overriden by calling
    * overrideDefaultRoute().
    */
   attribute long preferredNetworkType;
 
   /**
-   * The network interface handling all data traffic.
+   * The network information of the network interface handling all network
+   * traffic.
    *
    * When this changes, the 'network-active-changed' observer
    * notification is dispatched.
    */
-  readonly attribute nsINetworkInterface active;
+  readonly attribute nsINetworkInfo activeNetworkInfo;
 
   /**
    * Override the default behaviour for preferredNetworkType and route
    * all network traffic through the the specified interface.
    *
    * Consumers can observe changes to the active network by subscribing to
    * the 'network-active-changed' observer notification.
    *
@@ -178,34 +93,34 @@ interface nsINetworkManager : nsISupport
    *        a previous override is canceled.
    */
   long overrideActive(in nsINetworkInterface network);
 
   /**
    * Add host route to the specified network into routing table.
    *
    * @param network
-   *        The network interface where the host to be routed to.
+   *        The network information for the host to be routed to.
    * @param host
    *        The host to be added.
    *        The host will be resolved in advance if it's not an ip-address.
    *
    * @return a Promise
    *         resolved if added; rejected, otherwise.
    */
-  jsval addHostRoute(in nsINetworkInterface network,
+  jsval addHostRoute(in nsINetworkInfo network,
                      in DOMString host);
 
   /**
    * Remove host route to the specified network from routing table.
    *
    * @param network
-   *        The network interface where the routing to be removed from.
+   *        The network information for the routing to be removed from.
    * @param host
    *        The host routed to the network.
    *        The host will be resolved in advance if it's not an ip-address.
    *
    * @return a Promise
    *         resolved if removed; rejected, otherwise.
    */
-  jsval removeHostRoute(in nsINetworkInterface network,
+  jsval removeHostRoute(in nsINetworkInfo network,
                         in DOMString host);
 };
--- a/dom/system/gonk/nsITetheringService.idl
+++ b/dom/system/gonk/nsITetheringService.idl
@@ -2,29 +2,29 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "nsISupports.idl"
 
 interface nsINetworkInterface;
 interface nsIWifiTetheringCallback;
 
-[scriptable, uuid(80d65940-bd99-458f-8529-e438c7348087)]
+[scriptable, uuid(993b79df-f10e-4697-a5dc-5981cf8ff7e6)]
 interface nsITetheringService : nsISupports
 {
   /**
    * Enable or disable Wifi Tethering
    *
    * @param enabled
    *        Boolean that indicates whether tethering should be enabled (true) or
    *        disabled (false).
-   * @param networkInterface
-   *        The Wifi network interface with at least name of network interface.
+   * @param interfaceName
+   *        The Wifi network interface name for internal interface.
    * @param config
    *        The Wifi Tethering configuration from settings db.
    * @param callback
    *        Callback function used to report status to WifiManager.
    */
   void setWifiTethering(in boolean enabled,
-                        in nsINetworkInterface networkInterface,
+                        in DOMString interfaceName,
                         in jsval config,
                         in nsIWifiTetheringCallback callback);
 };
\ No newline at end of file
--- a/dom/system/gonk/tests/marionette/head.js
+++ b/dom/system/gonk/tests/marionette/head.js
@@ -4,28 +4,28 @@
 MARIONETTE_CONTEXT = "chrome";
 
 const SETTINGS_KEY_DATA_ENABLED = "ril.data.enabled";
 const SETTINGS_KEY_DATA_APN_SETTINGS  = "ril.data.apnSettings";
 
 const TOPIC_CONNECTION_STATE_CHANGED = "network-connection-state-changed";
 const TOPIC_NETWORK_ACTIVE_CHANGED = "network-active-changed";
 
-const NETWORK_STATE_UNKNOWN = Ci.nsINetworkInterface.NETWORK_STATE_UNKNOWN;
-const NETWORK_STATE_CONNECTING = Ci.nsINetworkInterface.NETWORK_STATE_CONNECTING;
-const NETWORK_STATE_CONNECTED = Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED;
-const NETWORK_STATE_DISCONNECTING = Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTING;
-const NETWORK_STATE_DISCONNECTED = Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED;
+const NETWORK_STATE_UNKNOWN = Ci.nsINetworkInfo.NETWORK_STATE_UNKNOWN;
+const NETWORK_STATE_CONNECTING = Ci.nsINetworkInfo.NETWORK_STATE_CONNECTING;
+const NETWORK_STATE_CONNECTED = Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED;
+const NETWORK_STATE_DISCONNECTING = Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTING;
+const NETWORK_STATE_DISCONNECTED = Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED;
 
-const NETWORK_TYPE_MOBILE = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE;
-const NETWORK_TYPE_MOBILE_MMS = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_MMS;
-const NETWORK_TYPE_MOBILE_SUPL = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_SUPL;
-const NETWORK_TYPE_MOBILE_IMS = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_IMS;
-const NETWORK_TYPE_MOBILE_DUN = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_DUN;
-const NETWORK_TYPE_MOBILE_FOTA = Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_FOTA;
+const NETWORK_TYPE_MOBILE = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE;
+const NETWORK_TYPE_MOBILE_MMS = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_MMS;
+const NETWORK_TYPE_MOBILE_SUPL = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_SUPL;
+const NETWORK_TYPE_MOBILE_IMS = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_IMS;
+const NETWORK_TYPE_MOBILE_DUN = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_DUN;
+const NETWORK_TYPE_MOBILE_FOTA = Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_FOTA;
 
 const networkTypes = [
   NETWORK_TYPE_MOBILE,
   NETWORK_TYPE_MOBILE_MMS,
   NETWORK_TYPE_MOBILE_SUPL,
   NETWORK_TYPE_MOBILE_IMS,
   NETWORK_TYPE_MOBILE_DUN,
   NETWORK_TYPE_MOBILE_FOTA
@@ -139,23 +139,23 @@ function waitForObserverEvent(aTopic) {
  *        A boolean state.
  *
  * @return A deferred promise.
  */
 function setDataEnabledAndWait(aEnabled) {
   let promises = [];
   promises.push(waitForObserverEvent(TOPIC_CONNECTION_STATE_CHANGED)
     .then(function(aSubject) {
-      ok(aSubject instanceof Ci.nsIRilNetworkInterface,
-         "subject should be an instance of nsIRILNetworkInterface");
+      ok(aSubject instanceof Ci.nsIRilNetworkInfo,
+         "subject should be an instance of nsIRilNetworkInfo");
       is(aSubject.type, NETWORK_TYPE_MOBILE,
          "subject.type should be " + NETWORK_TYPE_MOBILE);
       is(aSubject.state,
-         aEnabled ? Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED
-                  : Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED,
+         aEnabled ? Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED
+                  : Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED,
          "subject.state should be " + aEnabled ? "CONNECTED" : "DISCONNECTED");
     }));
   promises.push(setSettings(SETTINGS_KEY_DATA_ENABLED, aEnabled));
 
   return Promise.all(promises);
 }
 
 /**
@@ -170,21 +170,21 @@ function setDataEnabledAndWait(aEnabled)
  * @return A deferred promise.
  */
 function setupDataCallAndWait(aNetworkType) {
   log("setupDataCallAndWait: " + aNetworkType);
 
   let promises = [];
   promises.push(waitForObserverEvent(TOPIC_CONNECTION_STATE_CHANGED)
     .then(function(aSubject) {
-      ok(aSubject instanceof Ci.nsIRilNetworkInterface,
-         "subject should be an instance of nsIRILNetworkInterface");
+      ok(aSubject instanceof Ci.nsIRilNetworkInfo,
+         "subject should be an instance of nsIRilNetworkInfo");
       is(aSubject.type, aNetworkType,
          "subject.type should be " + aNetworkType);
-      is(aSubject.state, Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED,
+      is(aSubject.state, Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED,
          "subject.state should be CONNECTED");
     }));
   promises.push(radioInterface.setupDataCallByType(aNetworkType));
 
   return Promise.all(promises);
 }
 
 /**
@@ -199,21 +199,21 @@ function setupDataCallAndWait(aNetworkTy
  * @return A deferred promise.
  */
 function deactivateDataCallAndWait(aNetworkType) {
   log("deactivateDataCallAndWait: " + aNetworkType);
 
   let promises = [];
   promises.push(waitForObserverEvent(TOPIC_CONNECTION_STATE_CHANGED)
     .then(function(aSubject) {
-      ok(aSubject instanceof Ci.nsIRilNetworkInterface,
-         "subject should be an instance of nsIRILNetworkInterface");
+      ok(aSubject instanceof Ci.nsIRilNetworkInfo,
+         "subject should be an instance of nsIRilNetworkInfo");
       is(aSubject.type, aNetworkType,
          "subject.type should be " + aNetworkType);
-      is(aSubject.state, Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED,
+      is(aSubject.state, Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED,
          "subject.state should be DISCONNECTED");
     }));
   promises.push(radioInterface.deactivateDataCallByType(aNetworkType));
 
   return Promise.all(promises);
 }
 
 /**
--- a/dom/system/gonk/tests/marionette/test_network_active_changed.js
+++ b/dom/system/gonk/tests/marionette/test_network_active_changed.js
@@ -8,42 +8,42 @@ let networkManager =
   Cc["@mozilla.org/network/manager;1"].getService(Ci.nsINetworkManager);
 ok(networkManager,
    "networkManager.constructor is " + networkManager.constructor);
 
 function testInitialState() {
   return getSettings(SETTINGS_KEY_DATA_ENABLED)
     .then((enabled) => {
       is(enabled, false, "data should be off by default");
-      is(networkManager.active, null,
-         "networkManager.active should be null by default");
+      is(networkManager.activeNetworkInfo, null,
+         "networkManager.activeNetworkInfo should be null by default");
     });
 }
 
 function testActiveNetworkChangedBySwitchingDataCall(aDataCallEnabled) {
   log("Test active network by switching dataCallEnabled to " + aDataCallEnabled);
 
   let promises = [];
   promises.push(waitForObserverEvent(TOPIC_NETWORK_ACTIVE_CHANGED));
   promises.push(setSettings(SETTINGS_KEY_DATA_ENABLED, aDataCallEnabled));
 
   return Promise.all(promises).then(function(results) {
     let subject = results[0];
 
     if (aDataCallEnabled) {
-      ok(subject instanceof Ci.nsINetworkInterface,
-         "subject should be an instance of nsINetworkInterface");
-      ok(subject instanceof Ci.nsIRilNetworkInterface,
-         "subject should be an instance of nsIRILNetworkInterface");
+      ok(subject instanceof Ci.nsINetworkInfo,
+         "subject should be an instance of nsINetworkInfo");
+      ok(subject instanceof Ci.nsIRilNetworkInfo,
+         "subject should be an instance of nsIRilNetworkInfo");
       is(subject.type, NETWORK_TYPE_MOBILE,
          "subject.type should be NETWORK_TYPE_MOBILE");
     }
 
-    is(subject, networkManager.active,
-       "subject should be equal with networkManager.active");
+    is(subject, networkManager.activeNetworkInfo,
+       "subject should be equal with networkManager.activeNetworkInfo");
   });
 }
 
 // Start test
 startTestBase(function() {
   return testInitialState()
     // Test active network changed by enabling data call.
     .then(() => testActiveNetworkChangedBySwitchingDataCall(true))
--- a/dom/system/gonk/tests/marionette/test_network_interface_list_service.js
+++ b/dom/system/gonk/tests/marionette/test_network_interface_list_service.js
@@ -1,71 +1,71 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
 MARIONETTE_TIMEOUT = 60000;
 MARIONETTE_HEAD_JS = "head.js";
 
-function getNetworkInterface(aType) {
+function getNetworkInfo(aType) {
   let networkListService =
     Cc["@mozilla.org/network/interface-list-service;1"].
       getService(Ci.nsINetworkInterfaceListService);
   // Get all available interfaces
   let networkList = networkListService.getDataInterfaceList(0);
 
   // Try to get nsINetworkInterface for aType.
   let numberOfInterface = networkList.getNumberOfInterface();
   for (let i = 0; i < numberOfInterface; i++) {
-    let iface = networkList.getInterface(i);
-    if (iface.type === aType) {
-      return iface;
+    let info = networkList.getInterfaceInfo(i);
+    if (info.type === aType) {
+      return info;
     }
   }
 
   return null;
 }
 
 // Test getDataInterfaceList by enabling/disabling mobile data.
 function testGetDataInterfaceList(aMobileDataEnabled) {
   log("Test getDataInterfaceList with mobile data " +
       aMobileDataEnabled ? "enabled" : "disabled");
 
   return setDataEnabledAndWait(aMobileDataEnabled)
-    .then(() => getNetworkInterface(NETWORK_TYPE_MOBILE))
-    .then((networkInterface) => {
-      if (!networkInterface) {
-        ok(false, "Should get an valid nsINetworkInterface for mobile");
+    .then(() => getNetworkInfo(NETWORK_TYPE_MOBILE))
+    .then((networkInfo) => {
+      if (!networkInfo) {
+        ok(false, "Should get an valid nsINetworkInfo for mobile");
         return;
       }
 
-      ok(networkInterface instanceof Ci.nsINetworkInterface,
-         "networkInterface should be an instance of nsINetworkInterface");
+      ok(networkInfo instanceof Ci.nsINetworkInfo,
+         "networkInfo should be an instance of nsINetworkInfo");
 
       let ipAddresses = {};
       let prefixs = {};
       let numOfGateways = {};
       let numOfDnses = {};
-      let numOfIpAddresses = networkInterface.getAddresses(ipAddresses, prefixs);
-      let gateways = networkInterface.getGateways(numOfGateways);
-      let dnses = networkInterface.getDnses(numOfDnses);
+      let numOfIpAddresses = networkInfo.getAddresses(ipAddresses, prefixs);
+      let gateways = networkInfo.getGateways(numOfGateways);
+      let dnses = networkInfo.getDnses(numOfDnses);
 
       if (aMobileDataEnabled) {
         // Mobile data is enabled.
-        is(networkInterface.state, NETWORK_STATE_CONNECTED, "check state");
+        is(networkInfo.state, NETWORK_STATE_CONNECTED, "check state");
         ok(numOfIpAddresses > 0, "check number of ipAddresses");
         ok(ipAddresses.value.length > 0, "check ipAddresses.length");
         ok(prefixs.value.length > 0, "check prefixs.length");
         ok(numOfGateways.value > 0, "check number of gateways");
         ok(prefixs.value.length > 0, "check prefixs.length");
         ok(gateways.length > 0, "check gateways.length");
         ok(numOfDnses.value > 0, "check number of dnses");
         ok(dnses.length > 0, "check dnses.length");
       } else {
         // Mobile data is disabled.
-        is(networkInterface.state, NETWORK_STATE_DISCONNECTED, "check state");
+        is(networkInfo.state, NETWORK_STATE_DISCONNECTED, "check state");
         is(numOfIpAddresses, 0, "check number of ipAddresses");
         is(ipAddresses.value.length, 0, "check ipAddresses.length");
         is(prefixs.value.length, 0, "check prefixs.length");
         is(numOfGateways.value, 0, "check number of gateways");
         is(prefixs.value.length, 0, "check prefixs.length");
         is(gateways.length, 0, "check gateways.length");
         is(numOfDnses.value, 0, "check number of dnses");
         is(dnses.length, 0, "check dnses.length");
--- a/dom/wifi/WifiP2pManager.jsm
+++ b/dom/wifi/WifiP2pManager.jsm
@@ -485,49 +485,54 @@ function P2pStateMachine(aP2pCommand, aN
     address: "",
     deviceName: DEFAULT_P2P_DEVICE_NAME + "_" + libcutils.property_get("ro.build.product"),
     wpsCapabilities: [WPS_METHOD_PBC, WPS_METHOD_KEYPAD, WPS_METHOD_DISPLAY]
   };
 
   let _p2pNetworkInterface = {
     QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInterface]),
 
-    state: Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED,
-    type: Ci.nsINetworkInterface.NETWORK_TYPE_WIFI_P2P,
-    name: P2P_INTERFACE_NAME,
-    ips: [],
-    prefixLengths: [],
-    dnses: [],
-    gateways: [],
+    info: {
+      QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInfo]),
+
+      state: Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED,
+      type: Ci.nsINetworkInfo.NETWORK_TYPE_WIFI_P2P,
+      name: P2P_INTERFACE_NAME,
+      ips: [],
+      prefixLengths: [],
+      dnses: [],
+      gateways: [],
+
+      getAddresses: function (ips, prefixLengths) {
+        ips.value = this.ips.slice();
+        prefixLengths.value = this.prefixLengths.slice();
+
+        return this.ips.length;
+      },
+
+      getGateways: function (count) {
+        if (count) {
+          count.value = this.gateways.length;
+        }
+        return this.gateways.slice();
+      },
+
+      getDnses: function (count) {
+        if (count) {
+          count.value = this.dnses.length;
+        }
+        return this.dnses.slice();
+      }
+    },
+
     httpProxyHost: null,
     httpProxyPort: null,
 
     // help
-    registered: false,
-
-    getAddresses: function (ips, prefixLengths) {
-      ips.value = this.ips.slice();
-      prefixLengths.value = this.prefixLengths.slice();
-
-      return this.ips.length;
-    },
-
-    getGateways: function (count) {
-      if (count) {
-        count.value = this.gateways.length;
-      }
-      return this.gateways.slice();
-    },
-
-    getDnses: function (count) {
-      if (count) {
-        count.value = this.dnses.length;
-      }
-      return this.dnses.slice();
-    }
+    registered: false
   };
 
   //---------------------------------------------------------
   // State machine APIs.
   //---------------------------------------------------------
 
   // Register the observer which is implemented in WifiP2pWorkerObserver.jsm.
   //
@@ -1414,20 +1419,20 @@ function P2pStateMachine(aP2pCommand, aN
       aNetUtil.startDhcpServer(dhcpServerConfig, function (success) {
         if (!success) {
           debug('Failed to start DHCP server');
           onFailure();
           return;
         }
 
         // Update p2p network interface.
-        _p2pNetworkInterface.state = Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED;
-        _p2pNetworkInterface.ips = [GO_NETWORK_INTERFACE.ip];
-        _p2pNetworkInterface.prefixLengths = [GO_NETWORK_INTERFACE.maskLength];
-        _p2pNetworkInterface.gateways = [GO_NETWORK_INTERFACE.ip];
+        _p2pNetworkInterface.info.state = Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED;
+        _p2pNetworkInterface.info.ips = [GO_NETWORK_INTERFACE.ip];
+        _p2pNetworkInterface.info.prefixLengths = [GO_NETWORK_INTERFACE.maskLength];
+        _p2pNetworkInterface.info.gateways = [GO_NETWORK_INTERFACE.ip];
         handleP2pNetworkInterfaceStateChanged();
 
         _groupInfo.networkInterface = _p2pNetworkInterface;
 
         debug('Everything is done. Happy p2p GO~');
         onSuccess();
       });
 
@@ -1449,43 +1454,43 @@ function P2pStateMachine(aP2pCommand, aN
       debug("DHCP request success: " + JSON.stringify(dhcpData.info));
 
       // Update p2p network interface.
       let maskLength =
         netHelpers.getMaskLength(netHelpers.stringToIP(dhcpData.info.mask_str));
       if (!maskLength) {
         maskLength = 32; // max prefix for IPv4.
       }
-      _p2pNetworkInterface.state = Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED;
-      _p2pNetworkInterface.ips = [dhcpData.info.ipaddr_str];
-      _p2pNetworkInterface.prefixLengths = [maskLength];
+      _p2pNetworkInterface.info.state = Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED;
+      _p2pNetworkInterface.info.ips = [dhcpData.info.ipaddr_str];
+      _p2pNetworkInterface.info.prefixLengths = [maskLength];
       if (typeof dhcpData.info.dns1_str == "string" &&
           dhcpData.info.dns1_str.length) {
-        _p2pNetworkInterface.dnses.push(dhcpData.info.dns1_str);
+        _p2pNetworkInterface.info.dnses.push(dhcpData.info.dns1_str);
       }
       if (typeof dhcpData.info.dns2_str == "string" &&
           dhcpData.info.dns2_str.length) {
-        _p2pNetworkInterface.dnses.push(dhcpData.info.dns2_str);
+        _p2pNetworkInterface.info.dnses.push(dhcpData.info.dns2_str);
       }
-      _p2pNetworkInterface.gateways = [dhcpData.info.gateway_str];
+      _p2pNetworkInterface.info.gateways = [dhcpData.info.gateway_str];
       handleP2pNetworkInterfaceStateChanged();
 
       _groupInfo.networkInterface = _p2pNetworkInterface;
 
       debug('Happy p2p client~');
       onSuccess();
     });
   }
 
   function resetP2pNetworkInterface() {
-    _p2pNetworkInterface.state = Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED;
-    _p2pNetworkInterface.ips = [];
-    _p2pNetworkInterface.prefixLengths = [];
-    _p2pNetworkInterface.dnses = [];
-    _p2pNetworkInterface.gateways = [];
+    _p2pNetworkInterface.info.state = Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED;
+    _p2pNetworkInterface.info.ips = [];
+    _p2pNetworkInterface.info.prefixLengths = [];
+    _p2pNetworkInterface.info.dnses = [];
+    _p2pNetworkInterface.info.gateways = [];
   }
 
   function registerP2pNetworkInteface() {
     if (!_p2pNetworkInterface.registered) {
       resetP2pNetworkInterface();
       gNetworkManager.registerNetworkInterface(_p2pNetworkInterface);
       _p2pNetworkInterface.registered = true;
     }
@@ -1518,17 +1523,17 @@ function P2pStateMachine(aP2pCommand, aN
     }
     if (_groupInfo.ifname !== aInfo.ifname ||
         _groupInfo.role   !== aInfo.role) {
       debug('Unmatched group info: ' + JSON.stringify(_groupInfo) +
             ' v.s. ' + JSON.stringify(aInfo));
     }
 
     // Update p2p network interface.
-    _p2pNetworkInterface.state = Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED;
+    _p2pNetworkInterface.info.state = Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED;
     handleP2pNetworkInterfaceStateChanged();
 
     if (P2P_ROLE_GO === aInfo.role) {
       aNetUtil.stopDhcpServer(function(success) {
         debug('Stop DHCP server result: ' + success);
         aCallback(true);
       });
     } else {
--- a/dom/wifi/WifiWorker.js
+++ b/dom/wifi/WifiWorker.js
@@ -398,18 +398,18 @@ var WifiManager = (function() {
     if (!network)
       return;
 
     // If we got here, arg network must be the currentNetwork, so we just update
     // WifiNetworkInterface correspondingly and notify NetworkManager.
     WifiNetworkInterface.httpProxyHost = network.httpProxyHost;
     WifiNetworkInterface.httpProxyPort = network.httpProxyPort;
 
-    if (WifiNetworkInterface.state ==
-        Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED) {
+    if (WifiNetworkInterface.info.state ==
+        Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED) {
       gNetworkManager.updateNetworkInterface(WifiNetworkInterface);
     }
   }
 
   var staticIpConfig = Object.create(null);
   function setStaticIpMode(network, info, callback) {
     let setNetworkKey = getNetworkKey(network);
     let curNetworkKey = null;
@@ -1009,26 +1009,27 @@ var WifiManager = (function() {
     if (enabled === manager.isWifiEnabled(manager.state)) {
       callback("no change");
       return;
     }
 
     if (enabled) {
       manager.state = "INITIALIZING";
       // Register as network interface.
-      WifiNetworkInterface.name = manager.ifname;
+      WifiNetworkInterface.info.name = manager.ifname;
       if (!WifiNetworkInterface.registered) {
         gNetworkManager.registerNetworkInterface(WifiNetworkInterface);
         WifiNetworkInterface.registered = true;
       }
-      WifiNetworkInterface.state = Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED;
-      WifiNetworkInterface.ips = [];
-      WifiNetworkInterface.prefixLengths = [];
-      WifiNetworkInterface.gateways = [];
-      WifiNetworkInterface.dnses = [];
+      WifiNetworkInterface.info.state =
+        Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED;
+      WifiNetworkInterface.info.ips = [];
+      WifiNetworkInterface.info.prefixLengths = [];
+      WifiNetworkInterface.info.gateways = [];
+      WifiNetworkInterface.info.dnses = [];
       gNetworkManager.updateNetworkInterface(WifiNetworkInterface);
 
       prepareForStartup(function() {
         loadDriver(function (status) {
           if (status < 0) {
             callback(status);
             manager.state = "UNINITIALIZED";
             return;
@@ -1163,18 +1164,20 @@ var WifiManager = (function() {
         function getWifiHotspotStatus() {
           wifiCommand.hostapdGetStations(function(result) {
             notify("stationinfoupdate", {station: result});
           });
         }
 
         function doStartWifiTethering() {
           cancelWaitForDriverReadyTimer();
-          WifiNetworkInterface.name = libcutils.property_get("wifi.tethering.interface", manager.ifname);
-          gTetheringService.setWifiTethering(enabled, WifiNetworkInterface,
+          WifiNetworkInterface.info.name =
+            libcutils.property_get("wifi.tethering.interface", manager.ifname);
+          gTetheringService.setWifiTethering(enabled,
+                                             WifiNetworkInterface.info.name,
                                              configuration, function(result) {
             if (result) {
               manager.tetheringState = "UNINITIALIZED";
             } else {
               manager.tetheringState = "COMPLETED";
               wifiCommand.connectToHostapd(function(result) {
                 if (result) {
                   return;
@@ -1778,65 +1781,69 @@ function isWepHexKey(s) {
 let WifiNetworkInterface = {
 
   QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInterface]),
 
   registered: false,
 
   // nsINetworkInterface
 
-  NETWORK_STATE_UNKNOWN:       Ci.nsINetworkInterface.NETWORK_STATE_UNKNOWN,
-  NETWORK_STATE_CONNECTING:    Ci.nsINetworkInterface.CONNECTING,
-  NETWORK_STATE_CONNECTED:     Ci.nsINetworkInterface.CONNECTED,
-  NETWORK_STATE_DISCONNECTING: Ci.nsINetworkInterface.DISCONNECTING,
-  NETWORK_STATE_DISCONNECTED:  Ci.nsINetworkInterface.DISCONNECTED,
-
-  state: Ci.nsINetworkInterface.NETWORK_STATE_UNKNOWN,
-
-  NETWORK_TYPE_WIFI:        Ci.nsINetworkInterface.NETWORK_TYPE_WIFI,
-  NETWORK_TYPE_MOBILE:      Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE,
-  NETWORK_TYPE_MOBILE_MMS:  Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_MMS,
-  NETWORK_TYPE_MOBILE_SUPL: Ci.nsINetworkInterface.NETWORK_TYPE_MOBILE_SUPL,
-
-  type: Ci.nsINetworkInterface.NETWORK_TYPE_WIFI,
-
-  name: null,
-
-  ips: [],
-
-  prefixLengths: [],
-
-  dnses: [],
-
-  gateways: [],
+  NETWORK_STATE_UNKNOWN:       Ci.nsINetworkInfo.NETWORK_STATE_UNKNOWN,
+  NETWORK_STATE_CONNECTING:    Ci.nsINetworkInfo.CONNECTING,
+  NETWORK_STATE_CONNECTED:     Ci.nsINetworkInfo.CONNECTED,
+  NETWORK_STATE_DISCONNECTING: Ci.nsINetworkInfo.DISCONNECTING,
+  NETWORK_STATE_DISCONNECTED:  Ci.nsINetworkInfo.DISCONNECTED,
+
+  NETWORK_TYPE_WIFI:        Ci.nsINetworkInfo.NETWORK_TYPE_WIFI,
+  NETWORK_TYPE_MOBILE:      Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE,
+  NETWORK_TYPE_MOBILE_MMS:  Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_MMS,
+  NETWORK_TYPE_MOBILE_SUPL: Ci.nsINetworkInfo.NETWORK_TYPE_MOBILE_SUPL,
+
+  info: {
+    QueryInterface: XPCOMUtils.generateQI([Ci.nsINetworkInfo]),
+
+    state: Ci.nsINetworkInfo.NETWORK_STATE_UNKNOWN,
+
+    type: Ci.nsINetworkInfo.NETWORK_TYPE_WIFI,
+
+    name: null,
+
+    ips: [],
+
+    prefixLengths: [],
+
+    dnses: [],
+
+    gateways: [],
+
+    getAddresses: function (ips, prefixLengths) {
+      ips.value = this.ips.slice();
+      prefixLengths.value = this.prefixLengths.slice();
+
+      return this.ips.length;
+    },
+
+    getGateways: function (count) {
+      if (count) {
+        count.value = this.gateways.length;
+      }
+      return this.gateways.slice();
+    },
+
+    getDnses: function (count) {
+      if (count) {
+        count.value = this.dnses.length;
+      }
+      return this.dnses.slice();
+    }
+  },
 
   httpProxyHost: null,
 
-  httpProxyPort: null,
-
-  getAddresses: function (ips, prefixLengths) {
-    ips.value = this.ips.slice();
-    prefixLengths.value = this.prefixLengths.slice();
-
-    return this.ips.length;
-  },
-
-  getGateways: function (count) {
-    if (count) {
-      count.value = this.gateways.length;
-    }
-    return this.gateways.slice();
-  },
-
-  getDnses: function (count) {
-    if (count) {
-      count.value = this.dnses.length;
-    }
-    return this.dnses.slice();
-  }
+  httpProxyPort: null
 };
 
 function WifiScanResult() {}
 
 // TODO Make the difference between a DOM-based network object and our
 // networks objects much clearer.
 let netToDOM;
 let netFromDOM;
@@ -2247,18 +2254,18 @@ function WifiWorker() {
         // wifi connection complete, turn on the power saving mode.
         WifiManager.setPowerSavingMode(true);
         // BSSID is read after connected, update it.
         self.currentNetwork.bssid = WifiManager.connectionInfo.bssid;
         break;
       case "DISCONNECTED":
         // wpa_supplicant may give us a "DISCONNECTED" event even if
         // we are already in "DISCONNECTED" state.
-        if ((WifiNetworkInterface.state ===
-             Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED) &&
+        if ((WifiNetworkInterface.info.state ===
+             Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED) &&
              (this.prevState === "INITIALIZING" ||
               this.prevState === "DISCONNECTED" ||
               this.prevState === "INTERFACE_DISABLED" ||
               this.prevState === "INACTIVE" ||
               this.prevState === "UNINITIALIZED")) {
           // When in disconnected mode, need to turn on wifi power saving mode.
           WifiManager.setPowerSavingMode(true);
           return;
@@ -2280,23 +2287,26 @@ function WifiWorker() {
           // We've disconnected from a network because of a call to forgetNetwork.
           // Reconnect to the next available network (if any).
           if (self._reconnectOnDisconnect) {
             self._reconnectOnDisconnect = false;
             WifiManager.reconnect(function(){});
           }
         });
 
-        WifiNetworkInterface.state =
-          Ci.nsINetworkInterface.NETWORK_STATE_DISCONNECTED;
-        WifiNetworkInterface.ips = [];
-        WifiNetworkInterface.prefixLengths = [];
-        WifiNetworkInterface.gateways = [];
-        WifiNetworkInterface.dnses = [];
+        WifiNetworkInterface.info.state =
+          Ci.nsINetworkInfo.NETWORK_STATE_DISCONNECTED;
+
+        // Update network infterface first then clear properties.
         gNetworkManager.updateNetworkInterface(WifiNetworkInterface);
+        WifiNetworkInterface.info.ips = [];
+        WifiNetworkInterface.info.prefixLengths = [];
+        WifiNetworkInterface.info.gateways = [];
+        WifiNetworkInterface.info.dnses = [];
+
 
         break;
       case "WPS_TIMEOUT":
         self._fireEvent("onwpstimeout", {});
         break;
       case "WPS_FAIL":
         self._fireEvent("onwpsfail", {});
         break;
@@ -2328,28 +2338,28 @@ function WifiWorker() {
     }
 
     let netConnect = WifiManager.getHttpProxyNetwork(self.currentNetwork);
     if (netConnect) {
       WifiNetworkInterface.httpProxyHost = netConnect.httpProxyHost;
       WifiNetworkInterface.httpProxyPort = netConnect.httpProxyPort;
     }
 
-    WifiNetworkInterface.state =
-      Ci.nsINetworkInterface.NETWORK_STATE_CONNECTED;
-    WifiNetworkInterface.ips = [this.info.ipaddr_str];
-    WifiNetworkInterface.prefixLengths = [maskLength];
-    WifiNetworkInterface.gateways = [this.info.gateway_str];
+    WifiNetworkInterface.info.state =
+      Ci.nsINetworkInfo.NETWORK_STATE_CONNECTED;
+    WifiNetworkInterface.info.ips = [this.info.ipaddr_str];
+    WifiNetworkInterface.info.prefixLengths = [maskLength];
+    WifiNetworkInterface.info.gateways = [this.info.gateway_str];
     if (typeof this.info.dns1_str == "string" &&
         this.info.dns1_str.length) {
-      WifiNetworkInterface.dnses.push(this.info.dns1_str);
+      WifiNetworkInterface.info.dnses.push(this.info.dns1_str);
     }
     if (typeof this.info.dns2_str == "string" &&
         this.info.dns2_str.length) {
-      WifiNetworkInterface.dnses.push(this.info.dns2_str);
+      WifiNetworkInterface.info.dnses.push(this.info.dns2_str);
     }
     gNetworkManager.updateNetworkInterface(WifiNetworkInterface);
 
     self.ipAddress = this.info.ipaddr_str;
 
     // We start the connection information timer when we associate, but
     // don't have our IP address until here. Make sure that we fire a new
     // connectionInformation event with the IP address the next time the
--- a/media/mtransport/gonk_addrs.cpp
+++ b/media/mtransport/gonk_addrs.cpp
@@ -7,17 +7,17 @@ extern "C" {
 #include <arpa/inet.h>
 #include "r_types.h"
 #include "stun.h"
 #include "addrs.h"
 }
 
 #include <vector>
 #include <string>
-#include "nsINetworkManager.h"
+#include "nsINetworkInterface.h"
 #include "nsINetworkInterfaceListService.h"
 #include "runnable_utils.h"
 #include "nsCOMPtr.h"
 #include "nsMemory.h"
 #include "nsThreadUtils.h"
 #include "nsServiceManagerUtils.h"
 #include "mozilla/SyncRunnable.h"
 
@@ -53,30 +53,30 @@ GetInterfaces(std::vector<NetworkInterfa
 
   // Translate nsINetworkInterfaceList to NetworkInterface.
   int32_t listLength;
   NS_ENSURE_SUCCESS(networkList->GetNumberOfInterface(&listLength),
                     NS_ERROR_FAILURE);
   aInterfaces->clear();
 
   for (int32_t i = 0; i < listLength; i++) {
-    nsCOMPtr<nsINetworkInterface> iface;
-    if (NS_FAILED(networkList->GetInterface(i, getter_AddRefs(iface)))) {
+    nsCOMPtr<nsINetworkInfo> info;
+    if (NS_FAILED(networkList->GetInterfaceInfo(i, getter_AddRefs(info)))) {
       continue;
     }
 
     char16_t **ips = nullptr;
     uint32_t *prefixs = nullptr;
     uint32_t count = 0;
     bool isAddressGot = false;
     NetworkInterface interface;
     memset(&(interface.addr), 0, sizeof(interface.addr));
     interface.addr.sin_family = AF_INET;
 
-    if (NS_FAILED(iface->GetAddresses(&ips, &prefixs, &count))) {
+    if (NS_FAILED(info->GetAddresses(&ips, &prefixs, &count))) {
       continue;
     }
 
     for (uint32_t j = 0; j < count; j++) {
       nsAutoString ip;
 
       ip.Assign(ips[j]);
       if (inet_pton(AF_INET, NS_ConvertUTF16toUTF8(ip).get(),
@@ -89,30 +89,30 @@ GetInterfaces(std::vector<NetworkInterfa
     free(prefixs);
     NS_FREE_XPCOM_ALLOCATED_POINTER_ARRAY(count, ips);
 
     if (!isAddressGot) {
       continue;
     }
 
     nsAutoString ifaceName;
-    if (NS_FAILED(iface->GetName(ifaceName))) {
+    if (NS_FAILED(info->GetName(ifaceName))) {
       continue;
     }
     interface.name = NS_ConvertUTF16toUTF8(ifaceName).get();
 
     int32_t type;
-    if (NS_FAILED(iface->GetType(&type))) {
+    if (NS_FAILED(info->GetType(&type))) {
       continue;
     }
     switch (type) {
-      case nsINetworkInterface::NETWORK_TYPE_WIFI:
+      case nsINetworkInfo::NETWORK_TYPE_WIFI:
         interface.type = NR_INTERFACE_TYPE_WIFI;
         break;
-      case nsINetworkInterface::NETWORK_TYPE_MOBILE:
+      case nsINetworkInfo::NETWORK_TYPE_MOBILE:
         interface.type = NR_INTERFACE_TYPE_MOBILE;
         break;
     }
 
     aInterfaces->push_back(interface);
   }
   return NS_OK;
 }
--- a/netwerk/base/NetStatistics.h
+++ b/netwerk/base/NetStatistics.h
@@ -6,93 +6,94 @@
 
 #ifndef NetStatistics_h__
 #define NetStatistics_h__
 
 #include "mozilla/Assertions.h"
 
 #include "nsCOMPtr.h"
 #include "nsError.h"
+#include "nsINetworkInterface.h"
 #include "nsINetworkManager.h"
 #include "nsINetworkStatsServiceProxy.h"
 #include "nsThreadUtils.h"
 #include "nsProxyRelease.h"
 
 namespace mozilla {
 namespace net {
 
 // The following members are used for network per-app metering.
 const static uint64_t NETWORK_STATS_THRESHOLD = 65536;
 const static char NETWORK_STATS_NO_SERVICE_TYPE[] = "";
 
 inline nsresult
-GetActiveNetworkInterface(nsCOMPtr<nsINetworkInterface> &aNetworkInterface)
+GetActiveNetworkInfo(nsCOMPtr<nsINetworkInfo> &aNetworkInfo)
 {
   MOZ_ASSERT(NS_IsMainThread());
 
   nsresult rv;
   nsCOMPtr<nsINetworkManager> networkManager =
     do_GetService("@mozilla.org/network/manager;1", &rv);
 
   if (NS_FAILED(rv) || !networkManager) {
-    aNetworkInterface = nullptr;
+    aNetworkInfo = nullptr;
     return rv;
   }
 
-  networkManager->GetActive(getter_AddRefs(aNetworkInterface));
+  networkManager->GetActiveNetworkInfo(getter_AddRefs(aNetworkInfo));
 
   return NS_OK;
 }
 
 class SaveNetworkStatsEvent : public nsRunnable {
 public:
   SaveNetworkStatsEvent(uint32_t aAppId,
                         bool aIsInBrowser,
-                        nsMainThreadPtrHandle<nsINetworkInterface> &aActiveNetwork,
+                        nsMainThreadPtrHandle<nsINetworkInfo> &aActiveNetworkInfo,
                         uint64_t aCountRecv,
                         uint64_t aCountSent,
                         bool aIsAccumulative)
     : mAppId(aAppId),
       mIsInBrowser(aIsInBrowser),
-      mActiveNetwork(aActiveNetwork),
+      mActiveNetworkInfo(aActiveNetworkInfo),
       mCountRecv(aCountRecv),
       mCountSent(aCountSent),
       mIsAccumulative(aIsAccumulative)
   {
     MOZ_ASSERT(mAppId != NECKO_NO_APP_ID);
-    MOZ_ASSERT(mActiveNetwork);
+    MOZ_ASSERT(mActiveNetworkInfo);
   }
 
   NS_IMETHOD Run()
   {
     MOZ_ASSERT(NS_IsMainThread());
 
     nsresult rv;
     nsCOMPtr<nsINetworkStatsServiceProxy> mNetworkStatsServiceProxy =
       do_GetService("@mozilla.org/networkstatsServiceProxy;1", &rv);
     if (NS_FAILED(rv)) {
       return rv;
     }
 
     // save the network stats through NetworkStatsServiceProxy
     mNetworkStatsServiceProxy->SaveAppStats(mAppId,
                                             mIsInBrowser,
-                                            mActiveNetwork,
+                                            mActiveNetworkInfo,
                                             PR_Now() / 1000,
                                             mCountRecv,
                                             mCountSent,
                                             mIsAccumulative,
                                             nullptr);
 
     return NS_OK;
   }
 private:
   uint32_t mAppId;
   bool     mIsInBrowser;
-  nsMainThreadPtrHandle<nsINetworkInterface> mActiveNetwork;
+  nsMainThreadPtrHandle<nsINetworkInfo> mActiveNetworkInfo;
   uint64_t mCountRecv;
   uint64_t mCountSent;
   bool mIsAccumulative;
 };
 
 } // namespace mozilla:net
 } // namespace mozilla
 
--- a/netwerk/base/nsIOService.cpp
+++ b/netwerk/base/nsIOService.cpp
@@ -44,16 +44,17 @@
 #include "mozilla/net/NeckoCommon.h"
 #include "mozilla/Telemetry.h"
 #include "mozilla/net/DNS.h"
 #include "CaptivePortalService.h"
 #include "ReferrerPolicy.h"
 
 #ifdef MOZ_WIDGET_GONK
 #include "nsINetworkManager.h"
+#include "nsINetworkInterface.h"
 #endif
 
 #if defined(XP_WIN)
 #include "nsNativeConnectionHelper.h"
 #endif
 
 using namespace mozilla;
 using mozilla::net::IsNeckoChild;
@@ -1316,28 +1317,28 @@ IsWifiActive()
     }
 #ifdef MOZ_WIDGET_GONK
     // On B2G we query the network manager for the active interface
     nsCOMPtr<nsINetworkManager> networkManager =
         do_GetService("@mozilla.org/network/manager;1");
     if (!networkManager) {
         return false;
     }
-    nsCOMPtr<nsINetworkInterface> active;
-    networkManager->GetActive(getter_AddRefs(active));
-    if (!active) {
+    nsCOMPtr<nsINetworkInfo> activeNetworkInfo;
+    networkManager->GetActiveNetworkInfo(getter_AddRefs(activeNetworkInfo));
+    if (!activeNetworkInfo) {
         return false;
     }
     int32_t type;
-    if (NS_FAILED(active->GetType(&type))) {
+    if (NS_FAILED(activeNetworkInfo->GetType(&type))) {
         return false;
     }
     switch (type) {
-    case nsINetworkInterface::NETWORK_TYPE_WIFI:
-    case nsINetworkInterface::NETWORK_TYPE_WIFI_P2P:
+    case nsINetworkInfo::NETWORK_TYPE_WIFI:
+    case nsINetworkInfo::NETWORK_TYPE_WIFI_P2P:
         return true;
     default:
         return false;
     }
 #else
     // On anything else than B2G we return true so than wifi-only
     // apps don't think they are offline.
     return true;
@@ -1428,29 +1429,29 @@ nsIOService::Observe(nsISupports *subjec
         if (mCaptivePortalService) {
             mCaptivePortalService->RecheckCaptivePortal();
         }
     } else if (!strcmp(topic, kNetworkActiveChanged)) {
 #ifdef MOZ_WIDGET_GONK
         if (IsNeckoChild()) {
           return NS_OK;
         }
-        nsCOMPtr<nsINetworkInterface> interface = do_QueryInterface(subject);
+        nsCOMPtr<nsINetworkInfo> interface = do_QueryInterface(subject);
         if (!interface) {
             return NS_ERROR_FAILURE;
         }
         int32_t state;
         if (NS_FAILED(interface->GetState(&state))) {
             return NS_ERROR_FAILURE;
         }
 
         bool wifiActive = IsWifiActive();
         int32_t newWifiState = wifiActive ?
-            nsINetworkInterface::NETWORK_TYPE_WIFI :
-            nsINetworkInterface::NETWORK_TYPE_MOBILE;
+            nsINetworkInfo::NETWORK_TYPE_WIFI :
+            nsINetworkInfo::NETWORK_TYPE_MOBILE;
         if (mPreviousWifiState != newWifiState) {
             // Notify wifi-only apps of their new status
             int32_t status = wifiActive ?
                 nsIAppOfflineInfo::ONLINE : nsIAppOfflineInfo::OFFLINE;
 
             EnumeratorParams params = {this, status};
             mAppsOfflineStatus.EnumerateRead(EnumerateWifiAppsChangingState, &params);
         }
--- a/netwerk/base/nsUDPSocket.cpp
+++ b/netwerk/base/nsUDPSocket.cpp
@@ -806,20 +806,20 @@ nsUDPSocket::InitWithAddress(const NetAd
     rv = aPrincipal->GetIsInBrowserElement(&mIsInBrowserElement);
     if (NS_FAILED(rv)) {
       return rv;
     }
   }
 
 #ifdef MOZ_WIDGET_GONK
   if (mAppId != NECKO_UNKNOWN_APP_ID) {
-    nsCOMPtr<nsINetworkInterface> activeNetwork;
-    GetActiveNetworkInterface(activeNetwork);
-    mActiveNetwork =
-      new nsMainThreadPtrHolder<nsINetworkInterface>(activeNetwork);
+    nsCOMPtr<nsINetworkInfo> activeNetworkInfo;
+    GetActiveNetworkInfo(activeNetworkInfo);
+    mActiveNetworkInfo =
+      new nsMainThreadPtrHolder<nsINetworkInfo>(activeNetworkInfo);
   }
 #endif
 
   uint16_t port;
   if (NS_FAILED(net::GetPort(aAddr, &port))) {
     NS_WARNING("invalid bind address");
     goto fail;
   }
@@ -913,30 +913,30 @@ nsUDPSocket::GetLocalAddr(nsINetAddr * *
 
   return NS_OK;
 }
 
 void
 nsUDPSocket::SaveNetworkStats(bool aEnforce)
 {
 #ifdef MOZ_WIDGET_GONK
-  if (!mActiveNetwork || mAppId == NECKO_UNKNOWN_APP_ID) {
+  if (!mActiveNetworkInfo || mAppId == NECKO_UNKNOWN_APP_ID) {
     return;
   }
 
   if (mByteReadCount == 0 && mByteWriteCount == 0) {
     return;
   }
 
   uint64_t total = mByteReadCount + mByteWriteCount;
   if (aEnforce || total > NETWORK_STATS_THRESHOLD) {
     // Create the event to save the network statistics.
     // the event is then dispathed to the main thread.
     nsRefPtr<nsRunnable> event =
-      new SaveNetworkStatsEvent(mAppId, mIsInBrowserElement, mActiveNetwork,
+      new SaveNetworkStatsEvent(mAppId, mIsInBrowserElement, mActiveNetworkInfo,
                                 mByteReadCount, mByteWriteCount, false);
     NS_DispatchToMainThread(event);
 
     // Reset the counters after saving.
     mByteReadCount = 0;
     mByteWriteCount = 0;
   }
 #endif
--- a/netwerk/base/nsUDPSocket.h
+++ b/netwerk/base/nsUDPSocket.h
@@ -8,17 +8,17 @@
 
 #include "nsIUDPSocket.h"
 #include "mozilla/Mutex.h"
 #include "nsIOutputStream.h"
 #include "nsAutoPtr.h"
 #include "nsCycleCollectionParticipant.h"
 
 #ifdef MOZ_WIDGET_GONK
-#include "nsINetworkManager.h"
+#include "nsINetworkInterface.h"
 #include "nsProxyRelease.h"
 #endif
 
 //-----------------------------------------------------------------------------
 
 class nsUDPSocket final : public nsASocketHandler
                         , public nsIUDPSocket
 {
@@ -67,17 +67,17 @@ private:
   nsCOMPtr<nsIUDPSocketListener>       mListener;
   nsCOMPtr<nsIEventTarget>             mListenerTarget;
   bool                                 mAttached;
   nsRefPtr<nsSocketTransportService>   mSts;
 
   uint64_t   mByteReadCount;
   uint64_t   mByteWriteCount;
 #ifdef MOZ_WIDGET_GONK
-  nsMainThreadPtrHandle<nsINetworkInterface> mActiveNetwork;
+  nsMainThreadPtrHandle<nsINetworkInfo> mActiveNetworkInfo;
 #endif
 };
 
 //-----------------------------------------------------------------------------
 
 class nsUDPMessage : public nsIUDPMessage
 {
 public:
--- a/netwerk/protocol/ftp/nsFtpConnectionThread.cpp
+++ b/netwerk/protocol/ftp/nsFtpConnectionThread.cpp
@@ -1612,20 +1612,20 @@ nsFtpState::Init(nsFtpChannel *channel)
     NS_ASSERTION(channel, "FTP: needs a channel");
 
     mChannel = channel; // a straight ref ptr to the channel
 
     // initialize counter for network metering
     mCountRecv = 0;
 
 #ifdef MOZ_WIDGET_GONK
-    nsCOMPtr<nsINetworkInterface> activeNetwork;
-    GetActiveNetworkInterface(activeNetwork);
-    mActiveNetwork =
-        new nsMainThreadPtrHolder<nsINetworkInterface>(activeNetwork);
+    nsCOMPtr<nsINetworkInfo> activeNetworkInfo;
+    GetActiveNetworkInfo(activeNetworkInfo);
+    mActiveNetworkInfo =
+        new nsMainThreadPtrHolder<nsINetworkInfo>(activeNetworkInfo);
 #endif
 
     mKeepRunning = true;
     mSuppliedEntityID = channel->EntityID();
 
     if (channel->UploadStream())
         mAction = PUT;
 
@@ -2100,17 +2100,17 @@ nsFtpState::SaveNetworkStats(bool enforc
 {
 #ifdef MOZ_WIDGET_GONK
     // Obtain app id
     uint32_t appId;
     bool isInBrowser;
     NS_GetAppInfo(mChannel, &appId, &isInBrowser);
 
     // Check if active network and appid are valid.
-    if (!mActiveNetwork || appId == NECKO_NO_APP_ID) {
+    if (!mActiveNetworkInfo || appId == NECKO_NO_APP_ID) {
         return NS_OK;
     }
 
     if (mCountRecv <= 0) {
         // There is no traffic, no need to save.
         return NS_OK;
     }
 
@@ -2119,17 +2119,17 @@ nsFtpState::SaveNetworkStats(bool enforc
     // threshold.
     if (!enforce && mCountRecv < NETWORK_STATS_THRESHOLD) {
         return NS_OK;
     }
 
     // Create the event to save the network statistics.
     // the event is then dispathed to the main thread.
     nsRefPtr<nsRunnable> event =
-        new SaveNetworkStatsEvent(appId, isInBrowser, mActiveNetwork,
+        new SaveNetworkStatsEvent(appId, isInBrowser, mActiveNetworkInfo,
                                   mCountRecv, 0, false);
     NS_DispatchToMainThread(event);
 
     // Reset the counters after saving.
     mCountRecv = 0;
 
     return NS_OK;
 #else
--- a/netwerk/protocol/ftp/nsFtpConnectionThread.h
+++ b/netwerk/protocol/ftp/nsFtpConnectionThread.h
@@ -13,17 +13,17 @@
 #include "nsIAsyncInputStream.h"
 #include "nsAutoPtr.h"
 #include "nsITransport.h"
 #include "mozilla/net/DNS.h"
 #include "nsFtpControlConnection.h"
 #include "nsIProtocolProxyCallback.h"
 
 #ifdef MOZ_WIDGET_GONK
-#include "nsINetworkManager.h"
+#include "nsINetworkInterface.h"
 #include "nsProxyRelease.h"
 #endif
 
 // ftp server types
 #define FTP_GENERIC_TYPE     0
 #define FTP_UNIX_TYPE        1
 #define FTP_VMS_TYPE         8
 #define FTP_NT_TYPE          9
@@ -213,17 +213,17 @@ private:
 
     nsCOMPtr<nsICancelable>  mProxyRequest;
     bool                     mDeferredCallbackPending;
 
 // These members are used for network per-app metering (bug 855948)
 // Currently, they are only available on gonk.
     uint64_t                           mCountRecv;
 #ifdef MOZ_WIDGET_GONK
-    nsMainThreadPtrHandle<nsINetworkInterface> mActiveNetwork;
+    nsMainThreadPtrHandle<nsINetworkInfo> mActiveNetworkInfo;
 #endif
     nsresult                           SaveNetworkStats(bool);
     void                               CountRecvBytes(uint64_t recvBytes)
     {
         mCountRecv += recvBytes;
         SaveNetworkStats(false);
     }
 };
--- a/netwerk/protocol/http/nsHttpTransaction.cpp
+++ b/netwerk/protocol/http/nsHttpTransaction.cpp
@@ -247,20 +247,20 @@ nsHttpTransaction::Init(uint32_t caps,
     mChannel = do_QueryInterface(eventsink);
     nsCOMPtr<nsIChannel> channel = do_QueryInterface(eventsink);
     if (channel) {
         NS_GetAppInfo(channel, &mAppId, &mIsInBrowser);
     }
 
 #ifdef MOZ_WIDGET_GONK
     if (mAppId != NECKO_NO_APP_ID) {
-        nsCOMPtr<nsINetworkInterface> activeNetwork;
-        GetActiveNetworkInterface(activeNetwork);
-        mActiveNetwork =
-            new nsMainThreadPtrHolder<nsINetworkInterface>(activeNetwork);
+        nsCOMPtr<nsINetworkInfo> activeNetworkInfo;
+        GetActiveNetworkInfo(activeNetworkInfo);
+        mActiveNetworkInfo =
+            new nsMainThreadPtrHolder<nsINetworkInfo>(activeNetworkInfo);
     }
 #endif
 
     nsCOMPtr<nsIHttpChannelInternal> httpChannelInternal =
         do_QueryInterface(eventsink);
     if (httpChannelInternal) {
         rv = httpChannelInternal->GetResponseTimeoutEnabled(
             &mResponseTimeoutEnabled);
@@ -818,17 +818,17 @@ nsHttpTransaction::WriteSegments(nsAHttp
     return rv;
 }
 
 nsresult
 nsHttpTransaction::SaveNetworkStats(bool enforce)
 {
 #ifdef MOZ_WIDGET_GONK
     // Check if active network and appid are valid.
-    if (!mActiveNetwork || mAppId == NECKO_NO_APP_ID) {
+    if (!mActiveNetworkInfo || mAppId == NECKO_NO_APP_ID) {
         return NS_OK;
     }
 
     if (mCountRecv <= 0 && mCountSent <= 0) {
         // There is no traffic, no need to save.
         return NS_OK;
     }
 
@@ -838,17 +838,17 @@ nsHttpTransaction::SaveNetworkStats(bool
     uint64_t totalBytes = mCountRecv + mCountSent;
     if (!enforce && totalBytes < NETWORK_STATS_THRESHOLD) {
         return NS_OK;
     }
 
     // Create the event to save the network statistics.
     // the event is then dispathed to the main thread.
     nsRefPtr<nsRunnable> event =
-        new SaveNetworkStatsEvent(mAppId, mIsInBrowser, mActiveNetwork,
+        new SaveNetworkStatsEvent(mAppId, mIsInBrowser, mActiveNetworkInfo,
                                   mCountRecv, mCountSent, false);
     NS_DispatchToMainThread(event);
 
     // Reset the counters after saving.
     mCountSent = 0;
     mCountRecv = 0;
 
     return NS_OK;
--- a/netwerk/protocol/http/nsHttpTransaction.h
+++ b/netwerk/protocol/http/nsHttpTransaction.h
@@ -14,17 +14,17 @@
 #include "nsThreadUtils.h"
 #include "nsILoadGroup.h"
 #include "nsIInterfaceRequestor.h"
 #include "TimingStruct.h"
 #include "Http2Push.h"
 #include "mozilla/net/DNS.h"
 
 #ifdef MOZ_WIDGET_GONK
-#include "nsINetworkManager.h"
+#include "nsINetworkInterface.h"
 #include "nsProxyRelease.h"
 #endif
 
 //-----------------------------------------------------------------------------
 
 class nsIHttpActivityObserver;
 class nsIEventTarget;
 class nsIInputStream;
@@ -403,17 +403,17 @@ private:
 
 // These members are used for network per-app metering (bug 746073)
 // Currently, they are only available on gonk.
     uint64_t                           mCountRecv;
     uint64_t                           mCountSent;
     uint32_t                           mAppId;
     bool                               mIsInBrowser;
 #ifdef MOZ_WIDGET_GONK
-    nsMainThreadPtrHandle<nsINetworkInterface> mActiveNetwork;
+    nsMainThreadPtrHandle<nsINetworkInfo> mActiveNetworkInfo;
 #endif
     nsresult                           SaveNetworkStats(bool);
     void                               CountRecvBytes(uint64_t recvBytes)
     {
         mCountRecv += recvBytes;
         SaveNetworkStats(false);
     }
     void                               CountSentBytes(uint64_t sentBytes)
--- a/netwerk/protocol/websocket/WebSocketChannel.cpp
+++ b/netwerk/protocol/websocket/WebSocketChannel.cpp
@@ -1371,20 +1371,20 @@ WebSocketChannel::BeginOpenInternal()
   }
 
   if (localChannel) {
     NS_GetAppInfo(localChannel, &mAppId, &mIsInBrowser);
   }
 
 #ifdef MOZ_WIDGET_GONK
   if (mAppId != NECKO_NO_APP_ID) {
-    nsCOMPtr<nsINetworkInterface> activeNetwork;
-    GetActiveNetworkInterface(activeNetwork);
-    mActiveNetwork =
-      new nsMainThreadPtrHolder<nsINetworkInterface>(activeNetwork);
+    nsCOMPtr<nsINetworkInfo> activeNetworkInfo;
+    GetActiveNetworkInfo(activeNetworkInfo);
+    mActiveNetworkInfo =
+      new nsMainThreadPtrHolder<nsINetworkInfo>(activeNetworkInfo);
   }
 #endif
 
   rv = localChannel->AsyncOpen(this, mHttpChannel);
   if (NS_FAILED(rv)) {
     LOG(("WebSocketChannel::BeginOpenInternal: cannot async open\n"));
     AbortSession(NS_ERROR_CONNECTION_REFUSED);
     return;
@@ -3704,17 +3704,17 @@ WebSocketChannel::OnDataAvailable(nsIReq
   return NS_OK;
 }
 
 nsresult
 WebSocketChannel::SaveNetworkStats(bool enforce)
 {
 #ifdef MOZ_WIDGET_GONK
   // Check if the active network and app id are valid.
-  if(!mActiveNetwork || mAppId == NECKO_NO_APP_ID) {
+  if(!mActiveNetworkInfo || mAppId == NECKO_NO_APP_ID) {
     return NS_OK;
   }
 
   uint64_t countRecv = 0;
   uint64_t countSent = 0;
 
   mCountRecv.exchange(countRecv);
   mCountSent.exchange(countSent);
@@ -3730,17 +3730,17 @@ WebSocketChannel::SaveNetworkStats(bool 
   uint64_t totalBytes = countRecv + countSent;
   if (!enforce && totalBytes < NETWORK_STATS_THRESHOLD) {
     return NS_OK;
   }
 
   // Create the event to save the network statistics.
   // the event is then dispathed to the main thread.
   nsRefPtr<nsRunnable> event =
-    new SaveNetworkStatsEvent(mAppId, mIsInBrowser, mActiveNetwork,
+    new SaveNetworkStatsEvent(mAppId, mIsInBrowser, mActiveNetworkInfo,
                               countRecv, countSent, false);
   NS_DispatchToMainThread(event);
 
   return NS_OK;
 #else
   return NS_ERROR_NOT_IMPLEMENTED;
 #endif
 }
--- a/netwerk/protocol/websocket/WebSocketChannel.h
+++ b/netwerk/protocol/websocket/WebSocketChannel.h
@@ -17,17 +17,17 @@
 #include "nsIObserver.h"
 #include "nsIProtocolProxyCallback.h"
 #include "nsIChannelEventSink.h"
 #include "nsIHttpChannelInternal.h"
 #include "nsIStringStream.h"
 #include "BaseWebSocketChannel.h"
 
 #ifdef MOZ_WIDGET_GONK
-#include "nsINetworkManager.h"
+#include "nsINetworkInterface.h"
 #include "nsProxyRelease.h"
 #endif
 
 #include "nsCOMPtr.h"
 #include "nsString.h"
 #include "nsDeque.h"
 #include "mozilla/Atomics.h"
 
@@ -286,17 +286,17 @@ private:
 
 // These members are used for network per-app metering (bug 855949)
 // Currently, they are only available on gonk.
   Atomic<uint64_t, Relaxed>       mCountRecv;
   Atomic<uint64_t, Relaxed>       mCountSent;
   uint32_t                        mAppId;
   bool                            mIsInBrowser;
 #ifdef MOZ_WIDGET_GONK
-  nsMainThreadPtrHandle<nsINetworkInterface> mActiveNetwork;
+  nsMainThreadPtrHandle<nsINetworkInfo> mActiveNetworkInfo;
 #endif
   nsresult                        SaveNetworkStats(bool);
   void                            CountRecvBytes(uint64_t recvBytes)
   {
     mCountRecv += recvBytes;
     SaveNetworkStats(false);
   }
   void                            CountSentBytes(uint64_t sentBytes)
--- a/testing/mozharness/mozharness.json
+++ b/testing/mozharness/mozharness.json
@@ -1,4 +1,4 @@
 {
     "repo": "https://hg.mozilla.org/build/mozharness",
-    "revision": "672af8a8da3e"
+    "revision": "d72df953784c"
 }
--- a/testing/mozharness/scripts/gaia_integration.py
+++ b/testing/mozharness/scripts/gaia_integration.py
@@ -43,16 +43,17 @@ class GaiaIntegrationTest(GaiaTest):
             dirs['abs_gaia_dir'] +
             '/node_modules/marionette-js-runner/host/python/runner-service')
         # Check whether python package is around since there exist versions
         # of gaia that depend on versions of marionette-js-runner without
         # the python stuff.
         if os.path.exists(gaia_runner_service):
             self.install_module('gaia-runner-service', gaia_runner_service)
         env['VIRTUALENV_PATH'] = self.query_virtualenv_path()
+        env['HOST_LOG'] = os.path.join(dirs['abs_log_dir'], 'gecko_output.log')
 
         cmd = [
             'make',
             'test-integration',
             'REPORTER=mocha-tbpl-reporter',
             'TEST_MANIFEST=./shared/test/integration/tbpl-manifest.json',
             'NODE_MODULE_SRC=npm-cache',
             'VIRTUALENV_EXISTS=1'
--- a/toolkit/devtools/discovery/discovery.js
+++ b/toolkit/devtools/discovery/discovery.js
@@ -380,26 +380,26 @@ Discovery.prototype = {
     this._transports.update.destroy();
     this._transports.update = null;
   },
 
   observe: function(subject, topic, data) {
     if (topic !== "network-active-changed") {
       return;
     }
-    let activeNetwork = subject;
-    if (!activeNetwork) {
-      log("No active network");
+    let activeNetworkInfo = subject;
+    if (!activeNetworkInfo) {
+      log("No active network info");
       return;
     }
-    activeNetwork = activeNetwork.QueryInterface(Ci.nsINetworkInterface);
-    log("Active network changed to: " + activeNetwork.type);
+    activeNetworkInfo = activeNetworkInfo.QueryInterface(Ci.nsINetworkInfo);
+    log("Active network changed to: " + activeNetworkInfo.type);
     // UDP sockets go down when the device goes offline, so we'll restart them
     // when the active network goes back to WiFi.
-    if (activeNetwork.type === Ci.nsINetworkInterface.NETWORK_TYPE_WIFI) {
+    if (activeNetworkInfo.type === Ci.nsINetworkInfo.NETWORK_TYPE_WIFI) {
       this._restartListening();
     }
   },
 
   _restartListening: function() {
     if (this._transports.scan) {
       this._stopListeningForScan();
       this._startListeningForScan();