[FIX][Cm12/12.1] Wifi Connectivity Issues/Drops

Search This thread

DjDiabolik

Senior Member
Jun 25, 2014
632
140

There's the exact reply you want to quote "http://xdaforums.com/showpost.php?p=61506445&postcount=5475" ??

There's present a totally newest .ini file "https://drive.google.com/file/d/0B6BS4V_hlZC7UUxRV1p5bEN4OGs/view".

It's safe ?? What's the difference between stock file and this ??

*EDIT*
The stock COS12.1 ini file have all value....:
HostNSOffload it's setted to 0 (i have set to 1)
HostARPOffloaad it's setted to 1 (i have leaved to 1)
and the:
gEnableActiveModeOffload it's setted to 1 (i have untoched)

For test i have need only to set NSOffload from 0 to 1................. need some time for some test............

Someone can says to or explain what's this value do ?
#Scan offload
gEnableDirectedScanOffload=0
 
Last edited:

DjDiabolik

Senior Member
Jun 25, 2014
632
140
For me SET TO 1 the HostNSOffload TO 1 it's COMPLETELY USELESS.............................. It's unbelievable nothing can be developing about this stupid bug:
It's exist a mode to obtain a log for explain wtf complain the wi-fi module for example ??

If i try to flash the recent CM13 ???? This stupid bug persist ?
 

Pablo.x

Senior Member
Mar 6, 2014
866
319
OnePlus 6T
For me SET TO 1 the HostNSOffload TO 1 it's COMPLETELY USELESS.............................. It's unbelievable nothing can be developing about this stupid bug:
It's exist a mode to obtain a log for explain wtf complain the wi-fi module for example ??

If i try to flash the recent CM13 ???? This stupid bug persist ?
It doesn't persist on cm13 or cm12.1, just on COS12.1

Enviado desde mi A0001 mediante Tapatalk
 
  • Like
Reactions: DjDiabolik

Top Liked Posts

  • There are no posts matching your filters.
  • 12
    Usually i switch on WiFi and disable mobile data manually while at home. It turns out that i don't receive any Push Notifications like WhatsApp, Threema, Facebook and GMail/Inbox (those who are using gcm) when the device is connected to WiFi solely and the screen is locked. If i unlock the device after a certain amount of time, a bunch of notifications are popping up. This is reproducable and won't occur on mobile data. Just do the following, while i.e. at home:

    1. Connect to WiFi
    2. Deactivate your Mobile Data
    3. Lock your screen and let your Device rest for a couple of seconds
    4. Tell someone to send you a Mail to your Gmail Account (or on any other GCM-Push related way)

    You probably may notice that your device won't wake up to notify you about this incoming message until you pick it up and unlock it. I have tested this since weeks with multiple official nightlies of CM12, custom builds and even unofficial CM12.1 builds, they all show the same behaviour. Even with official CM11s this issue persists, but can be worked around by unchecking "WiFi Optimizations" in advanced WiFi-Settings. Unfortunately Lollipop doesn't have this WiFi Optimization trigger anymore. Ofc "Keep WiFi on during sleep" is set to "always". After all tests i came to the conclusion that the device simply gets no wakelock trigger from notifications if connected to WiFi solely. I've fixed this for me by fiddeling with the configuration files (root needed).

    Open /system/etc/wifi/WCNSS_qcom_cfg.ini and change

    Code:
    hostNSOffload=0
    to
    Code:
    hostNSOffload=1

    After this change and a reboot, your device should be able to wake up from incoming notifications instantly while on WiFi. Some custom ROM, like SlimSaber have set this out of the box, while official cm nightlies and other custom ROM, like exodus, haven't.
    3
    worked for me

    Would be nice. I'm hunting this issue down since January, so far, as said, without any real solution other than using another router. it works anywhere except at home, so i know exactly how annoying this is. It's not that big problem to use mobile data when screen is off, but is pisses me off, if i just forget this sometimes and miss urgend messages from WhatsApp or Threema, coz they're arriving hours later. As desribed above, there is a way to prevent the OnePlus to not filter the WiFi Broadcasts. You just have to edit this one line in the configuration manually, but it comes at the cost of battery.

    I wanna share my experience with the WiFi after upgrading to cm 12.1 , I tried flashing different ROMs like blispop, uber, temasek, nightly cm12.1, candy but I always had the Wi-Fi drops. The WiFi would show its connected but I can't even browse using the internet using my home WiFi. Turns out its the router compatibility as it connected to other WiFi just fine.

    Sometimes toggling airplane mode on/off works but only temporary, restarting the router also works temporary. The permanent fix for me was assigning static IP address. I tried on the ROMs above except uber and my WiFi stayed on all the time and I got notified even when the phone was asleep and got really good internet speed based on my subscription.

    Here's how to assign static IP:

    Open settings - long click on the WiFi name - click modify network - scroll down you'll see static IP address and gateway option - now on your laptop/computer connected to the Wi-Fi open command prompt (type cmd in search for windows) - in the command prompt type "ipconfig" (without the quote) - you'll see plenty of details then look for ipv4 and gateway - the ipv4 would start with 192.XXX.XXX.xxx that is your static IP - input that in your phone settings with the gateway number - connect your WiFi and voila no more problems

    I hope it helps :good::)
    3
    I too tried all the tweaks, but nothing worked. The only solution I found was running this app in the background.
    https://play.google.com/store/apps/details?id=com.roy.wifimonitor&hl=en
    3
    @Jur1nator Okay, just navigate to your /system/addon.d/ and open 50-cm.sh to another file like i.e. "66-fix_wifi.sh".
    Remove the line at top that backups hosts (coz 50-cm.sh does that already), navigate straight to the end to where post-restore starts and copy/paste the following:
    Code:
    busybox sed -i -n -e :a -e '1,4!{P;N;D;};N;ba' /system/etc/wifi/WCNSS_qcom_cfg.ini
    echo "# Fix Notifications with some routers while on WiFi and sleeping" >> /system/etc/wifi/WCNSS_qcom_cfg.ini 
    echo "gEnableActiveModeOffload=1" >> /system/etc/wifi/WCNSS_qcom_cfg.ini
    echo "hostNSOffload=1" >> /system/etc/wifi/WCNSS_qcom_cfg.ini
    echo "END" >> /system/etc/wifi/WCNSS_qcom_cfg.ini
    so the end of your script should look like this:
    Code:
      ;;
      post-restore)
        busybox sed -i -n -e :a -e '1,4!{P;N;D;};N;ba' /system/etc/wifi/WCNSS_qcom_cfg.ini
        echo "# Fix Notifications with some routers while on WiFi and sleeping" >> /system/etc/wifi/WCNSS_qcom_cfg.ini 
        echo "gEnableActiveModeOffload=1" >> /system/etc/wifi/WCNSS_qcom_cfg.ini
        echo "hostNSOffload=1" >> /system/etc/wifi/WCNSS_qcom_cfg.ini
        echo "END" >> /system/etc/wifi/WCNSS_qcom_cfg.ini
      ;;
    esac

    This ensures that after every dirty flash the Offload-Parameters will be set automatically again.
    2
    I put the interesting commit into my cm12.1 kernel, which comes out tomorrow.

    If all goes well I can look to back port it to cm12 and maybe even cm11(s).

    Let's see. First we need opinions on the test kernel tomorrow.

    Andi