usr-sse2 / Black80211-Catalina

Control itlwm using AirPort menu
The Unlicense
191 stars 15 forks source link

Not showing all networks #15

Closed igorkulman closed 4 years ago

igorkulman commented 4 years ago

I run 2 home networks from my router, both using WP2-Personal, 20/40 MHz, 2.4 GHz, auto channel. With the "original" itlwm it connects to the networks just fine, I can see them in HeliPort.

With this fork I do not see my networks in the list and I cannot connect to them. I only see my neighbors networks, but not all of them, some than I see with HeliPort are also missing from the list.

usr-sse2 commented 4 years ago

Is your network shown in log show --last boot --predicate 'sender="Black80211"'? If it's shown, which channel it's actually on?

igorkulman commented 4 years ago

Sometime I see it found on channel 11

2020-08-04 12:48:06.676232+0200 0x1027a    Default     0x0                  0      0    kernel: (Black80211) SSID: K, channel 11
2020-08-04 12:48:06.676234+0200 0x1027a    Default     0x0                  0      0    kernel: (Black80211) Black80211: IOCTL get(11) SCAN_RESULT

and sometimes with an error

BSS Type: 3
PHY Mode: 1
Dwell time: 0
Rest time: 0
Num channels: 6
2020-08-04 12:32:57.105260+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) SSID: K
2020-08-04 12:32:57.105261+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) BSSID: 00:00:00:00:00:00
2020-08-04 12:32:57.105263+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) Reporting previous scan result
2020-08-04 12:32:57.105294+0200 0xfac8     Default     0x0                  0      0    kernel: (Black80211) Black80211: IOCTL get(11) SCAN_RESULT
2020-08-04 12:32:57.105296+0200 0xfac8     Default     0x0                  0      0    kernel: (Black80211) Error: scan result is not ready
2020-08-04 12:32:57.105791+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) Black80211: IOCTL get(19) POWER
2020-08-04 12:32:57.105800+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) Black80211: IOCTL get(15) OP_MODE
2020-08-04 12:32:57.105806+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) Black80211: IOCTL get(15) OP_MODE
2020-08-04 12:32:57.105830+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) Black80211: IOCTL get(27) SUPPORTED_CHANNELS
2020-08-04 12:32:57.105990+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) Black80211: IOCTL get(15) OP_MODE
2020-08-04 12:32:57.105994+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) Black80211: IOCTL set(10) SCAN_REQ
2020-08-04 12:32:57.105997+0200 0x10abd    Default     0x0                  0      0    kernel: (Black80211) Black80211. Scan requested. Type: 1
usr-sse2 commented 4 years ago

Please show more surrounding logs of both cases. The second one is not scan result but a scan request – macOS looks specifically for network with SSID "K" and any BSSID. (These logs are written to /var/log/wifi.log in case you already closed Terminal.

igorkulman commented 4 years ago

Here is the log log.txt

usr-sse2 commented 4 years ago

I've understood the reason. As a workaround, set your channel to 1 until I release a fix.

nemat-rakhmatov commented 4 years ago

It does not work with 5GHz networks, does it? I can see neighbour's 2.4GHz networks, but no my own networks (2.4GHz and 5GHz)

nemat-rakhmatov commented 4 years ago

It does not work with 5GHz networks, does it? I can see neighbour's 2.4GHz networks, but no my own networks (2.4GHz and 5GHz)

I've changed my 2.4GHz wireless channel to 1, and now it connects. My 5GHz channel is 48, it can not be scanned.

usr-sse2 commented 4 years ago

fix-scan.zip Please try this. Scanning when not connected should be fixed except first scanning sequence during system startup.

0xMisagi commented 4 years ago

I had the same problem, my wireless network is on channel 11. Seems like your fix-scan fixed the issue for me.

igorkulman commented 4 years ago

Works for me also, I now see both my networks.

ndhanh96 commented 4 years ago

yeah i was able to use this but don't have fancy feature like your images, still a win though, gps works.

igorkulman commented 4 years ago

yeah i was able to use this but don't have fancy feature like your images, still a win though, gps works.

Just hold Alt when clicking the icon.

ndhanh96 commented 4 years ago

yeah i was able to use this but don't have fancy feature like your images, still a win though, gps works.

Just hold Alt when clicking the icon.

holy moly , mac os is just as confusing as windows

usr-sse2 commented 4 years ago

@ndhanh96 Other menu bar items also have advanced menus with Option-click: for example, Sound, Bluetooth, Battery, Time Machine and WWAN.

igorkulman commented 4 years ago

fix-scan.zip Please try this. Scanning when not connected should be fixed except first scanning sequence during system startup.

Got a reboot after wake up from sleep

panic(cpu 3 caller 0xffffff7f9830e0a6): itlwm: mac clock not ready
Backtrace (CPU 3), Frame : Return Address
0xffffff818cf23a50 : 0xffffff8014f1a65d 
0xffffff818cf23aa0 : 0xffffff8015054a75 
0xffffff818cf23ae0 : 0xffffff80150465fe 
0xffffff818cf23b30 : 0xffffff8014ec0a40 
0xffffff818cf23b50 : 0xffffff8014f19d27 
0xffffff818cf23c50 : 0xffffff8014f1a117 
0xffffff818cf23ca0 : 0xffffff80156c1abc 
0xffffff818cf23d10 : 0xffffff7f9830e0a6 
0xffffff818cf23d20 : 0xffffff7f98307f8a 
0xffffff818cf23d40 : 0xffffff7f9830816e 
0xffffff818cf23d70 : 0xffffff7f982ecbf0 
0xffffff818cf23db0 : 0xffffff7f98300d5e 
0xffffff818cf23e10 : 0xffffff7f98303dbb 
0xffffff818cf23e50 : 0xffffff7f982f638a 
0xffffff818cf23fa0 : 0xffffff8014ec013e 
      Kernel Extensions in backtrace:
         com.zxystd.itlwm(1.0)[11165B20-1DE3-39CC-807F-C0B29C1838F5]@0xffffff7f982c6000->0xffffff7f991e2fff
            dependency: com.apple.iokit.IONetworkingFamily(3.4)[2FA065D5-72F7-3BE5-855C-E45B01AEFBD4]@0xffffff7f960c1000
            dependency: com.apple.iokit.IOPCIFamily(2.9)[B130A8B7-967F-330E-942F-E0BB93C71C56]@0xffffff7f95b02000

BSD process name corresponding to current thread: kernel_task
Boot args: -rtsx_mimic_linux 

Mac OS version:
19G73

Kernel version:
Darwin Kernel Version 19.6.0: Sun Jul  5 00:43:10 PDT 2020; root:xnu-6153.141.1~9/RELEASE_X86_64
Kernel UUID: 783946EA-6F11-3647-BF90-787AEA14B954
Kernel slide:     0x0000000014c00000
Kernel text base: 0xffffff8014e00000
__HIB  text base: 0xffffff8014d00000
System model name: MacBookPro11,1 (Mac-189A3D4F975D5FFC)
System shutdown begun: NO
Panic diags file available: YES (0x0)

System uptime in nanoseconds: 3460125911945
usr-sse2 commented 4 years ago

Use keepsyms=1 to get a report with function names. However, as Black80211 is not in backtrace, it seems to be a bug in itlwm.

igorkulman commented 4 years ago

I know but your itlwm fork does not have issue enabled so reporting here. It is not a bug in the original itlwm as it works for me with sleep just fine.

usr-sse2 commented 4 years ago

Does it happen always or only one time?

igorkulman commented 4 years ago

I switched back to original itlwm and heliport after the restart, but I can test again tomorrow.

I also get a reboot trying to unload your fork of itlwm, maybe it is related.

usr-sse2 commented 4 years ago

macOS retains Black80211, so it can't be unloaded. If you unload itlwm, Black80211 will call functions of destroyed object, I should retain itlwm to prevent unloading.