Unable to flash hAP lite RB941-2nD-TC

I just got your sources via git clone https://github.com/robimarko/openwrt.git and then compiled kernels. I believed this sources contain your SPI NOR patch. Am I right?

Only if you compiled the correct branch

Point me please to correct branch with NOR SPI

It should be under sxt-lte but that branch is really old.
Simply grab the patch from commit and then apply it on current openwrt master

Hi, Robimarko.
Pls excuse my stupid questions. But I need to be pointed :slight_smile:
If I'm going to apply your patch what should I do?

  1. git clone https://github.com/openwrt/openwrt.git
  2. cd ./openwrt
  3. I dont' know how to import your patch here
  4. git am <your_patch>
  5. ./scripts/feeds update -a
  6. ./scripts/feeds install -a
  7. make menuconfig
  8. make j=1 V=s

Simply download this file:

And place it in the same path as you see on github.
And then it should be applied during building

Do you mean this path : openwrt/target/linux/generic/backport-4.9/ 062-pending-0009-mtd-spi-nor-Add-support-for-w25q128jv.patch

and my local path ./ openwrt/target/linux/generic/backport-4.9/ 062-pending-0009-mtd-spi-nor-Add-support-for-w25q128jv.patch

look correct?

Yes, thats the path

Hi there, robimarko.
Pls, take a look to this strange error due compiling with your patch:

Applying /home/my/openwrt/target/linux/generic/backport-4.9/062-pending-0009-mtd-spi-nor-Add-support-for-w25q128jv.patch using plaintext: 
patch: **** Only garbage was found in the patch input.
Patch failed!  Please fix /home/my/openwrt/target/linux/generic/backport-4.9/062-pending-0009-mtd-spi-nor-Add-support-for-w25q128jv.patch!

Well, that means that you did something wrong as patch nornally applied couple of days ago.

How did you fetch it?

I made some mistake during fetching your patch. That's true. Now I trying to simply grab ( copy and then past to my compilation tree) all text of the patch from https://github.com/robimarko/openwrt/commit/c8cf326536afb33caa456b6ff59bb8fe900866f2

and patch was applied successfully.

But maybe you can point me to more simple way to get a patch from git-tree?

Well, simply click on RAW and fetch the download URL and download it using wget

Thank you ! It's work :slight_smile: But if I need to download multiple patches ? Just proceed them all like for one patch?

Well, no smart solution there.
One by one.

Now I've got compiled kernels.
My RB-941 Hap lite already flashed with OpenWRT 18.06 with Generic kernel without your patch. So if I want to flash it with patched compiled firmware, I should to do this:

boot my RB941 with patched openwrt-ar71xx-mikrotik-rb-nor-flash-16M-initramfs-kernel.bin and after that sysupgrade with this patched upgrade openwrt-ar71xx-mikrotik-rb-nor-flash-16M-squashfs-sysupgrade.bin

Am I right?

Yes, initramfs and then sysupgrade

Hi @robimarko , I have the same issue with both a hAP lite and a hAP ac lite. There is an open bug about the same issue with a RBM33G: https://bugs.openwrt.org/index.php?do=details&task_id=1715

Did you have time to submit the patch to OpenWrt? Since it was already submitted upstream it should be accepted. It would be nice to have it in OpenWrt for the next 18.06 release.

I just have a question on your patch: you say that it does not support dual or quad modes, but then you enable SPI_NOR_DUAL_READ and SPI_NOR_QUAD_READ. It seems to work, but is it normal?

It was submitted in June but upstream did not bother to even take a look at it.
I am gonna have to submit it to OpenWrt as more and more people are having issues.

I say that the board does not have dual or quad SPI modes but the SPI NOR memory has per datasheet.

Hi. The only reason I prefer OpenWRT on Mikrotiks rather that RouterOS is proper OpenVPN support. Would you, if your spare time permits, be so kind to compile us kernel and sysupgrade images for hap lite with openvpn-ssl support?

@robimarko I have just submitted your patch to OpenWrt, thanks again!
https://lists.infradead.org/pipermail/openwrt-devel/2018-October/014318.html
https://lists.infradead.org/pipermail/openwrt-devel/2018-October/014319.html

With a bit of chance it will be included in the 18.06.2 release.