M1cha / android_device_xiaomi_aries

Xiaomi MI2
24 stars 25 forks source link

wifi can't connect, phone reboots when turning wifi on/off #29

Closed pcppcp closed 10 years ago

pcppcp commented 10 years ago

After the 21/1 update, phone seems to be not able to connect to certain wpa2 protected wifi network. In settings -> wifi it tries to connect repeatedly, failing on "obtaining IP address" message.

Another problem, maybe related to this, is reboot of the phone when wifi is turned off/on manually. System just shuts off after maybe ten seconds after switching wifi back on.

dmesg of failed attempt to connect to a wlan

<6>[   64.794231] wlan(0) 00:00:00:00:00:00 Standalone
<6>[   64.794475] cfg80211: Calling CRDA to update world regulatory domain
<7>[   64.795330] ieee80211 phy0: info: cfg80211 reg_notifier callback for country 00
<7>[   64.795330] ieee80211 phy0: country: CZ set by driver
<6>[   64.795330] cfg80211: World regulatory domain updated:
<6>[   64.795666] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
<6>[   64.795788] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
<6>[   64.795910] cfg80211:   (2457000 KHz - 2482000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
<6>[   64.795971] cfg80211:   (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
<6>[   64.796093] cfg80211:   (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
<6>[   64.796215] cfg80211:   (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
<3>[   65.381291] wlan: [768:E :PE ] wlan_cfgGetInt: 351: Not valid cfg id 1
<6>[   65.389317] wlan: connected to 00:21:27:de:35:9c
<6>[   65.389409] wlan(10) 00:21:27:de:35:9c Standalone
<3>[   65.453135] init: untracked pid 2855 exited
<3>[   67.146772] wlan: [779:E :SME] sme_FTUpdateKey: Unhandled state=0
<3>[   67.147108] wlan: [779:E :SME] sme_FTUpdateKey: Unhandled state=0
<3>[   69.340302] qtaguid: iface_stat: stat_update() wlan0 not found
<6>[   69.484510] setting pm_qos in msm_pcm_playback_copy with 1000
<6>[   69.484571] done setting pm_qos in msm_pcm_playback_copy
<3>[   69.999298] qtaguid: iface_stat: stat_update() wlan0 not found
<6>[   74.869311] updating pm_qos value to default msm_pcm_playback_close
<6>[   74.869464] done updating pm_qos value to default msm_pcm_playback_close
<6>[   74.897604] SLIM_CL: skip reconfig sequence
<3>[   76.679749] qtaguid: iface_stat: stat_update() wlan0 not found
<3>[   76.975797] qtaguid: iface_stat: stat_update() wlan0 not found
<3>[   80.344727] qtaguid: iface_stat: stat_update() wlan0 not found
<6>[   83.115397] adjust_soc: ibat_ua = 26000, vbat_uv = 4177090, soc = 99, batt_temp=189
<3>[   83.334228] qtaguid: iface_stat: stat_update() wlan0 not found
<3>[   84.405402] wlan: [768:E :SME] pmcTrafficTimerExpired: 1036: Remain in power active DHCP threshold reached FALLBACK to enable enter BMPS
<3>[   85.409003] wlan: [768:E :SME] sme_QosPmcDeviceStateUpdateInd: 7219: nothing to process in PMC state 6
<3>[   86.596490] qtaguid: iface_stat: stat_update() wlan0 not found
<3>[   87.104715] qtaguid: iface_stat: stat_update() wlan0 not found
<3>[   89.390996] qtaguid: iface_stat: stat_update() wlan0 not found
<3>[   89.678895] qtaguid: iface_stat: stat_update() wlan0 not found
<3>[   92.749763] qtaguid: iface_stat: stat_update() wlan0 not found
<6>[   93.566519] setting pm_qos in msm_pcm_playback_copy with 1000
<6>[   93.566610] done setting pm_qos in msm_pcm_playback_copy
<6>[   96.685304] updating pm_qos value to default msm_pcm_playback_close
<6>[   96.685853] done updating pm_qos value to default msm_pcm_playback_close
<6>[   96.715428] SLIM_CL: skip reconfig sequence
<3>[   97.828048] wlan: [768:E :SME] csrNeighborRoamIndicateDisconnect: 3742: Disconnect indication on session 0 in state 2
<3>[   97.828261] wlan: [768:E :TL ]  ----> CRegion 0, hRSSI -33, Alpha 5
<3>[   97.828444] wlan: [768:E :TL ]  ----> CRegion 0, hRSSI -33, Alpha 5
<3>[   97.828872] wlan: [768:E :HDD] hdd_tdlsStatusUpdate: DEL_ALL_TDLS_PEER_IND staIdx 0 00:00:00:00:00:00 
<3>[   97.828872] 
<3>[   97.829848] wlan: [768:E :PE ] limDeactivateAndChangeTimer: 1438: Deactivated probe after hb timer
<3>[   97.829940] wlan: [768:E :PE ] limSendDisassocCnf: 3507: FT Preauth Session (ec448000,0) Cleanup
<6>[   97.841446] wlan: disconnected
<6>[   97.841538] wlan(0) 00:00:00:00:00:00 Standalone
<6>[   97.845353] cfg80211: Calling CRDA to update world regulatory domain
<7>[   97.845841] ieee80211 phy0: info: cfg80211 reg_notifier callback for country 00
<7>[   97.845872] ieee80211 phy0: country: CZ set by driver
<6>[   97.845902] cfg80211: World regulatory domain updated:
<6>[   97.846055] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
<6>[   97.846146] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
<6>[   97.846238] cfg80211:   (2457000 KHz - 2482000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
<6>[   97.846390] cfg80211:   (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
<6>[   97.846574] cfg80211:   (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
<6>[   97.846665] cfg80211:   (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
<3>[   98.355409] wlan: [768:E :HDD] hdd_tx_rx_pkt_cnt_stat_timer_handler: Disable split scan
<3>[   98.502456] wlan: [768:E :PE ] wlan_cfgGetInt: 351: Not valid cfg id 1
<6>[   98.510209] wlan: connected to 00:21:27:de:35:9c
<6>[   98.510331] wlan(10) 00:21:27:de:35:9c Standalone
<3>[   99.164138] wlan: [779:E :SME] sme_FTUpdateKey: Unhandled state=0
<3>[   99.165847] wlan: [779:E :SME] sme_FTUpdateKey: Unhandled state=0
<3>[  100.333496] qtaguid: iface_stat: stat_update() wlan0 not found

logcat just before reboot

D/WifiService(  604): setWifiEnabled: true pid=4119, uid=1000
W/Netd    (  170): No subsystem found in netlink event
D/NetlinkEvent(  170): Unexpected netlink message. type=0x11
W/Netd    (  170): No subsystem found in netlink event
D/NetlinkEvent(  170): Unexpected netlink message. type=0x11
M1cha commented 10 years ago

can u post last_kmsg after the reboot?

pcppcp commented 10 years ago

it's somewhat verbose, so i posted it to the pastebin.

http://pastebin.com/Yx6zTTgY

M1cha commented 10 years ago

and this just happens with the latest release? because I didn't change anything wifi related. Maybe you should try to update to the latest modem firmware, too

pcppcp commented 10 years ago

bug with wifi unable to switch back on did appear with 3/1 build, but the phone didn't reset. How do i update the firmware? Do i have to boot MIUI for that?

M1cha commented 10 years ago

u can download a flashable zip from here: http://xiaomi.eu/community/threads/radio-all-xiaomi-mi2-radio-thread.19846/

pcppcp commented 10 years ago

Great! It seems the new radio (3.5.17) did fix the reboot issue. I still can't connect, but there may be a problem with the router, as even the other phone won't get an IP. I think you can close this bug now. Thanks for your help!