Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FS#3279 - mac80211 doesn't see AR9820 minipci adapter at mt7621 board #8149

Open
openwrt-bot opened this issue Aug 8, 2020 · 4 comments
Open
Labels

Comments

@openwrt-bot
Copy link

AelxG:

Device: Unielec 7621-06 mt7621 with 64M Flash with Atheros AR9820 mini pcie adapter
Software: trunk

After sysupgrade -n with trunk image kernel does not recognize Atheros adapter:

root@router:~# lspci -k
00:00.0 PCI bridge: Device 0e8d:0801 (rev 01)
00:01.0 PCI bridge: Device 0e8d:0801 (rev 01)
01:00.0 SATA controller: ASMedia Technology Inc. ASM1062 Serial ATA Controller (rev 02)
Subsystem: ASMedia Technology Inc. Device 1060
Kernel driver in use: ahci
02:00.0 Ethernet controller: Qualcomm Atheros AR5008 Wireless Network Adapter (rev 01)

There is no interesting at dmesg output exсepts this:

[ 1.028161] mt7621-pci 1e140000.pcie: Parsing DT failed
[ 1.140760] mt7621-pci 1e140000.pcie: Error applying setting, reverse things back

Also there is no any messages about enabling pci002:00.0 device.

If mac80211 removed (with depended packets) adapter initialized correctly:

root@router:~# lspci -k
00:00.0 PCI bridge: Device 0e8d:0801 (rev 01)
00:01.0 PCI bridge: Device 0e8d:0801 (rev 01)
01:00.0 SATA controller: ASMedia Technology Inc. ASM1062 Serial ATA Controller (rev 02)
Subsystem: ASMedia Technology Inc. Device 1060
Kernel driver in use: ahci
02:00.0 Ethernet controller: Qualcomm Atheros AR982X Wireless Network Adapter (rev 01)

Image built by myself, downloaded snapshot from openwrt.org does not run at all.

The same card at the same device works perfectly with 19.07.3:

root@router:~# lspci -k
00:00.0 PCI bridge: Device 0e8d:0801 (rev 01)
00:01.0 PCI bridge: Device 0e8d:0801 (rev 01)
01:00.0 SATA controller: ASMedia Technology Inc. ASM1062 Serial ATA Controller (rev 02)
Subsystem: ASMedia Technology Inc. Device 1060
Kernel driver in use: ahci
02:00.0 Network controller: Qualcomm Atheros AR928X Wireless Network Adapter (PCI-Express) (rev 01)
Subsystem: Qualcomm Atheros Device 3099
Kernel driver in use: ath9k

@openwrt-bot
Copy link
Author

AelxG:

Sorry, adapter is 9280, not 9820.

Also I noted the next differencies between dmesg outputs.

Kernel 4.14:

pci002:00.0: [168c:002a] type 00 class 0x020000

Kernel 5.4:

pci002:00.0: [168c:ff1c] type 00 class 0x020000

@openwrt-bot
Copy link
Author

acoul:

this is probably due to missing kmod-owl-loader as noted in still open BUGs [[https://bugs.openwrt.org/index.php?do=details&task_id=1734|#1734]], [[https://bugs.openwrt.org/index.php?do=details&task_id=2750|#2750]] & couple of other places

@openwrt-bot
Copy link
Author

AelxG:

Please note that the trunk from 3 November works fine without kmod-owl-loader.

Also as it is described at https://openwrt.org/packages/pkgdata/kmod-owl-loader, that module is required when you have only wifi chip on board, and calibration data stored at factory partition of Flash.

By in my case I use full mini-PCIe cards with firmware on card so kmod-owl-loader looks unnecessary. And factory partition on my router is empty (!) and contains only MAC address.

Also 19.0x versions works fine also without kmod-owl-loader.

p.s. but I will try to compile trunk with it and check.

@openwrt-bot
Copy link
Author

AelxG:

Update. This patch fully resolve this issue:

---
drivers/staging/mt7621-pci/pci-mt7621.c | 1 +
1 file changed, 1 insertion(+)

--- a/drivers/staging/mt7621-pci/pci-mt7621.c 2021-01-26 14:36:41.761773605 +0300
+++ b/drivers/staging/mt7621-pci/pci-mt7621.c 2021-01-28 14:23:04.015990292 +0300
@@ -502,6 +502,7 @@
int err;

rt_sysc_m32(PERST_MODE_MASK, PERST_MODE_GPIO, MT7621_GPIO_MODE);
  • mdelay(100);
mt7621_pcie_reset_assert(pcie);
mt7621_pcie_reset_rc_deassert(pcie);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant