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

ar71xx: add support for RB LHG 5nD #925

Closed
wants to merge 2 commits into from
Closed

ar71xx: add support for RB LHG 5nD #925

wants to merge 2 commits into from

Conversation

f00b4r0
Copy link
Contributor

@f00b4r0 f00b4r0 commented Mar 7, 2017

This patch adds support for the MikroTik RouterBOARD LHG 5
https://routerboard.com/RBLHG-5nD

Specifications:

  • SoC: Atheros AR9344 (600MHz)
  • RAM: 64MB
  • Storage: 16MB NOR SPI flash
  • Wireless: builtin AR9344 5GHz, 2x2:2
  • Ethernet: 1x100M

Leveraged the existing SPI NOR code. Tested on actual hardware. Sysupgrade works.

@nbd168
Copy link
Contributor

nbd168 commented Mar 7, 2017

Merged to my staging tree, thanks.

@nbd168 nbd168 closed this Mar 7, 2017
@nbd168
Copy link
Contributor

nbd168 commented Mar 7, 2017

Reopening to leave some more time for review

@nbd168 nbd168 reopened this Mar 7, 2017
@@ -549,7 +616,7 @@ static void __init rbspi_952_750r2_setup(u32 flags)
}

/*
* Init the hAP hardware.
A* Init the hAP hardware (QCA953x).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A*, typo?

@@ -26,12 +26,12 @@ TARGET_DEVICES += nand-64m nand-large

define Device/rb-nor-flash-16M
DEVICE_TITLE := MikroTik RouterBoard with 16 MB SPI NOR flash
DEVICE_PACKAGES := rbcfg
DEVICE_PACKAGES := rbcfg rssileds
Copy link
Member

@pepe2k pepe2k Mar 7, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do all below boards need rssileds package?

@f00b4r0
Copy link
Contributor Author

f00b4r0 commented Mar 7, 2017

I have removed rssileds, although I think it's absurd to remove a package that is < 10KB uncompressed on a platform with 16MB storage. Especially considering how several boards on that platform could use it (besides the LHG5). At this point we don't need rbcfg either. my 2c.

@pepe2k
Copy link
Member

pepe2k commented Mar 7, 2017

I have removed rssileds, although I think it's absurd to remove a package that is < 10KB uncompressed on a platform with 16MB storage. Especially considering how several boards on that platform could use it (besides the LHG5). my 2c.

But the LED definitions are still in the code (etc/board.d/01_leds).
Have you considered separated images for these devices like we do in general, in ar71xx target?

Cheers,
Piotr

@f00b4r0
Copy link
Contributor Author

f00b4r0 commented Mar 7, 2017

Yes, this has been discussed before. The point being that all the SPI NOR devices share a very common platform. Like their nand counterpart, they can all run from the same image.

@f00b4r0
Copy link
Contributor Author

f00b4r0 commented Mar 7, 2017

reinstated rssileds as per irc discussion

This patch adds support for the MikroTik RouterBOARD LHG 5
https://routerboard.com/RBLHG-5nD

Specifications:
- SoC: Atheros AR9344 (600MHz)
- RAM: 64MB
- Storage: 16MB NOR SPI flash
- Wireless: builtin AR9344 5GHz, 2x2:2
- Ethernet: 1x100M

Initial flash via initramfs, like all other RB devices.

Signed-off-by: Thibaut VARENE <hacks@slashdirt.org>
@pepe2k
Copy link
Member

pepe2k commented Mar 13, 2017

@nbd168 no more comments from me about this one (rssileds was discussed and solved on irc), IMHO can be merged.

Cheers,
Piotr

When the device name doesn't already contain "RouterBOARD", this patch adds
this string to the machine name.

Most NOR devices already have "RouterBOARD" in their hardware-stored device name,
but not all of them.

This patch also makes the code more robust against buffer overflows.

Signed-off-by: Thibaut VARENE <hacks@slashdirt.org>
@pepe2k pepe2k self-assigned this Mar 14, 2017
@pepe2k
Copy link
Member

pepe2k commented Mar 14, 2017

@f00b4r0, thank you for your contribution, I have merged your changes into my staging tree.

@pepe2k pepe2k closed this Mar 14, 2017
@f00b4r0 f00b4r0 deleted the lhg5 branch March 15, 2017 23:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants