[ONE Original Android Development] Phoenix Wright:
[MENTION=4800121]Sultanxda[/MENTION] the new Wifi firmware enforces the CN regulatory domain and there's nothing that can be done to change it (I'm using it on CM12.1). I noticed it because my 5 GHz band is set on a DFS channel (legal in Italy), and it just disappeared:

<6>[ 420.912248] DefaultCountry is CN
<6>[ 420.914603] cfg80211: Calling CRDA for country: CN
<3>[ 420.914761] wlan: [131:F :HDD] pAdapter is null !!
<6>[ 420.914863] cfg80211: Regulatory domain changed to country: CN
<6>[ 420.914916] cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
<6>[ 420.915015] cfg80211: (2402000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm)
<6>[ 420.915113] cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz), (600 mBi, 2300 mBm)
<6>[ 420.915166] cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz), (600 mBi, 2300 mBm)
<6>[ 420.915265] cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (600 mBi, 3000 mBm)
<6>[ 420.915366] cfg80211: (57240000 KHz - 59400000 KHz @ 2160000 KHz), (N/A, 2800 mBm)
<6>[ 420.915421] cfg80211: (59400000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 4400 mBm)
<6>[ 420.915515] cfg80211: (63720000 KHz - 65880000 KHz @ 2160000 KHz), (N/A, 2800 mBm)

However, this can be solved. I looked for "CN" in the configuration files and it's located in WCNSS_qcom_wlan_nv.bin:

The only change needed is from "CNI" to "USO" at 0x1D75.

EDIT: nevermind, changing the "05" to "03" at 0x1D74 and keeping the "CNI" (so it becomes the exact same as in the CM config) works as well. Maybe the "03" means that the default can be changed by the OS.

EDIT2: Yeah, looks like it:

<6>[ 21.328607] DefaultCountry is CN
<6>[ 21.331463] cfg80211: Calling CRDA for country: CN
<3>[ 21.331794] wlan: [4:F :HDD] pAdapter is null !!
<6>[ 21.331961] cfg80211: Regulatory domain changed to country: CN
<6>[ 21.332049] cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
<6>[ 21.332212] cfg80211: (2402000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm)
<6>[ 21.332377] cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz), (600 mBi, 2300 mBm)
<6>[ 21.332467] cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz), (600 mBi, 2300 mBm)
<6>[ 21.332629] cfg80211: (5735000 KHz - 5835000 KHz @ 80000 KHz), (600 mBi, 3000 mBm)
<6>[ 21.332790] cfg80211: (57240000 KHz - 59400000 KHz @ 2160000 KHz), (N/A, 2800 mBm)
<6>[ 21.332879] cfg80211: (59400000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 4400 mBm)
<6>[ 21.333041] cfg80211: (63720000 KHz - 65880000 KHz @ 2160000 KHz), (N/A, 2800 mBm)
[...]
<6>[ 21.877427] cfg80211: Calling CRDA for country: IT
<6>[ 21.877682] cfg80211: Regulatory domain changed to country: IT
<6>[ 21.877731] cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
<6>[ 21.878010] cfg80211: (2402000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm)
<6>[ 21.878114] cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz), (N/A, 2000 mBm)
<6>[ 21.878166] cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz), (N/A, 2000 mBm)
<6>[ 21.878260] cfg80211: (5490000 KHz - 5710000 KHz @ 80000 KHz), (N/A, 2700 mBm)
<6>[ 21.878363] cfg80211: (57240000 KHz - 65880000 KHz @ 2160000 KHz), (N/A, 4000 mBm)