Adding support for Avaya WAP9122

Around christmas, I received an Avaya WAP9122 from @Chrizz to add support for the board. I haven't had much time to work on it, so a lot of things aren't working as expected, but I'm making good progress. This post will be updated and will always reflect the current state. The Cavium platform is a bit different to the other platforms I used to work with, so it's taking more time than expected.

Working:

  • TFTP Boot
  • (MMC Boot)
  • Both ethernet ports (partially), see below
  • LEDs
  • button
  • RTC

Code:

TFTP Boot:

  • Build an initramfs image and copy it to your TFTP server root as "openwrt.bin"
  • Attach serial console
  • Interrupt bootloader by pressing [space]
  • Log in to bootloader using admin:admin
  • Run the following commands in boot loader to boot "openwrt.bin" via TFTP from server at 192.168.1.254:
env set serverip 192.168.1.254
env set ipaddr 192.168.1.100
env set bootfile openwrt.bin
tftp
boot 0x20000000

NB: The device can only be powered via PoE. My AP refuses to boot if the serial console is attached while powering it on. I connect the console cable after power up, log into the stock firmware and run configure followed by reboot.

Problems:

  • The PCIe initialization reports an error, but seems to work. Both WiFi cards show up. However, ath10k does not initialize at all.
  • Both ethernet ports only work as long as the link doesn't go down. If link is lost, no packets are sent/received.

Log:

2023/01/23:

  • Finally found out that it's not a Avaya WAP9022, but a Avaya WAP9122. It's based on Octeon-III, not Octeon-II, so I should be using a different base DTS.
  • After a lot of searching, I found a mirror of a Xirrus Octeon Kernel source (https://gitlab.com/gplmirror/xirrus-kernel-uboot-inc/). The source includes a few fixups for the PHY and PCIe bus.

2023/02/25:

  • I understand how the PHY fixup works, but it's difficult to port to the current kernel as the PHY infrastructure has changed significantly. I'll postpone this for now and focus on the WiFi
  • I tried to port a PCIe fixup, but it doesn't work. I'll start to dig deeper into the PCIe and ath10k code to find the problem. I'll temporarily replace the cards to see if the PCIe driver is fine or if there is an incompatibility with these specific cards and ath10k.
  • Two other WiFi cards (Intel, Realtek) do not work either. While they are detected, the cards cannot be initialized due to the same PCIe problems. At least I know now that it's the Octeon PCIe driver, not ath10k.

2023/03/12

  • Did some work on the PCIe problem: MSI interrupts do not fire at all, this might be the cause for non-working PCIe
  • The Octeon SDK contains a lot more code to set up PCIe and other peripherals and it's going to take a while to port this to the current kernel.

2023/09/18

  • Finally, I had a look at the device and the kernel code again: Looks like upstream only supports PCIe on the Octeon-II SoC, while this device is Octeon-III. That explains the incomplete PCIe driver. And this also means that this is way more work than I initially thought (but then, I received a newer device than promised with a newer SoC than expected, so ...).
5 Likes