kirkwood: add pogoplug v4

also known as
POGO-V4-A3-02
or
POGO-V4-A3-01

SoC: Marvell 88F6192 800Mhz
SDRAM memory: 128MB
Gigabit ethernet: 1 Marvell 88E1310
Flash memory: 128MB
2 status LEDs (one green one red)
1 "Eject" button on the back (used as "Reset" button)
1 USB 2.0 port (on upper side)
1 sata slot (power + data) for 2.5'' drives (upper side)
2 USB 3.0 ports from a controller on PCIe x1 of the SoC
1 full-size SDcard slot (fits a whole SD card into it)

This device supports the (linux-only) kwboot tool to send
a new uboot over serial console, so it is easy to unbrick
in case the uboot is erased and the device won't boot.

-----
Install instructions:
-----
Since it's not possible to get ssh access to these
devices, the only way to take control is to
solder pins to get TTL serial access.

Case can be opened by removing screws beneath two rubber
feet at back of device, then lifting while prying the
sides of the upper part out to unhook a latch on each
side about 2/3rds of the way toward the front.

Serial connection pins are those labeled "J11", left
of SD as you face SD opening.
Pins are (from left to right, i.e. the first in the list
is the nearest to the SD slot) GND, Rx, Tx.
Do not connect +V pin if you use a USB (self-powered)
TTL-to-USB dongle. Any USB TTL-to-USB converter will work.
Baud rate is 115200, parity "none", databits "8",
flow control "none".

Stock uboot is unable to read ubi partitions (nor usb)
so we will replace it first with our uboot.

Start a TFTP server at IP address 169.254.254.254, and
place the uboot.kwb file in the folder of the server.

Start the serial session and then power up the device.

As soon as you see text on the serial start pressing random
letter keys to stop the boot process.

If you see something like the following line you can proceed:

CE>>

Otherwise if text is still scrolling by you missed the
opportunity, pull the plug and try again.

write

printenv ethaddr

The uboot will write something like this:

ethaddr=00:50:43:00:02:02

This is the device's MAC address, also present in the sticker
under the device.

Write this down as we will need to add it in the
new uboot configuration.

Use the following commands to load the new uboot:

tftp 0x20000 u-boot.kwb

If the uboot confirms that the transfer was successful,
then you can write it to flash with the following commands:

nand erase 0 0x200000
nand write 0x20000 0 0x1c0000

if after the last command the uboot wrote
"xxxx bytes written: OK"
then it was written correctly and we can proceed.

If it did not go well, try again or ask assistence in forums.
Shutting down or rebooting at this time will brick
the device, to unbrick it you will need to use the kwboot
tool from a Linux PC or Virtual Machine.

Now write:

reset

and press enter, the device will reboot and you should see
again text scrolling by.
Press a random key to stop it, and now you should see

pogoplugv4>

We now add the MAC address back, write:

setenv ethaddr '00:50:43:00:02:02'

Confirm that the uboot has understood by writing

printenv ethaddr

If all looks ok, save the setting with

saveenv

At this point the uboot is configured, and we only need to load
the firmware in the flash memory.

Follow the steps below in "Firmware recovery procedure".

----
Firmware recovery procedure
----
The new uboot allows easy recovery from a bad firmware upgrade
where you can't access the device anymore over ssh or luci.

Take a USB flash drive formatted as FAT32, and copy the
initramfs image file in it (it will have "initramfs" in the
file name), then rename it as "initramfs.bin".

Insert the USB drive in the USB 2.0 port of the pogoplug
(the port at the top).

Power up the device, and wait for it to finish booting.

The uboot should find and load the "initramfs.bin"
from usb and if you are connected with serial you should
see the linux kernel boot log (text scrolling by).
Once it is done, press Enter and you will be greeted by
the OpenWRT banner.

If you were not connected with serial just wait a bit and,
you will be able to access it with ssh or luci web interface
(once you find its IP).

The recovery "initramfs" images are run from RAM, so you will
have to do a normal sysupgrade (firmware upgrade) to write
a firmware image to flash memory.

Signed-off-by: Alberto Bursi <alberto.bursi@outlook.it>
openwrt-18.06
Alberto Bursi 2018-01-02 16:07:19 +01:00 committed by Mathias Kresin
parent f5d267df63
commit c19f811c4d
4 changed files with 71 additions and 1 deletions

View File

@ -16,7 +16,8 @@ case "$board" in
"seagate,goflexnet"|\
"raidsonic,ib-nas62x0"|\
"iom,iconnect-1.1"|\
"cloudengines,pogoe02")
"cloudengines,pogoe02"|\
"cloudengines,pogoplugv4")
ucidef_set_interface_lan "eth0" "dhcp"
;;
"linksys,audi"|\

View File

@ -14,6 +14,9 @@ get_status_led() {
cloudengines,pogoe02)
status_led="pogo_e02:orange:fault"
;;
cloudengines,pogoplugv4)
status_led="pogoplugv4:green:health"
;;
linksys,audi)
status_led="audi:green:power"
;;

View File

@ -121,6 +121,13 @@ define Device/cloudengines_pogoe02
endef
TARGET_DEVICES += cloudengines_pogoe02
define Device/cloudengines_pogoplugv4
DEVICE_TITLE := Cloud Engines Pogoplug V4
DEVICE_DTS := kirkwood-pogoplug-series-4
DEVICE_PACKAGES := kmod-usb3
endef
TARGET_DEVICES += cloudengines_pogoplugv4
define Device/raidsonic_ib-nas62x0
DEVICE_TITLE := RaidSonic ICY BOX IB-NAS62x0
DEVICE_DTS := kirkwood-ib62x0

View File

@ -0,0 +1,59 @@
--- a/arch/arm/boot/dts/kirkwood-pogoplug-series-4.dts
+++ b/arch/arm/boot/dts/kirkwood-pogoplug-series-4.dts
@@ -23,6 +23,7 @@
};
chosen {
+ bootargs = "console=ttyS0,115200";
stdout-path = "uart0:115200n8";
};
@@ -36,8 +37,8 @@
eject {
debounce_interval = <50>;
wakeup-source;
- linux,code = <KEY_EJECTCD>;
- label = "Eject Button";
+ linux,code = <KEY_RESTART>;
+ label = "Reset";
gpios = <&gpio0 29 GPIO_ACTIVE_LOW>;
};
};
@@ -136,29 +137,19 @@
#size-cells = <1>;
partition@0 {
- label = "u-boot";
- reg = <0x00000000 0x200000>;
+ label = "uboot";
+ reg = <0x00000000 0x1c0000>;
read-only;
};
- partition@200000 {
- label = "uImage";
- reg = <0x00200000 0x300000>;
- };
-
- partition@500000 {
- label = "uImage2";
- reg = <0x00500000 0x300000>;
+ partition@1c0000 {
+ label = "uboot_env";
+ reg = <0x001c0000 0x40000>;
};
- partition@800000 {
- label = "failsafe";
- reg = <0x00800000 0x800000>;
- };
-
- partition@1000000 {
- label = "root";
- reg = <0x01000000 0x7000000>;
+ partition@200000 {
+ label = "ubi";
+ reg = <0x00200000 0x7e00000>;
};
};
};