Welcome! Log In Create A New Profile

Advanced

support for Pogo P21?

Posted by gl 
gl
support for Pogo P21?
September 17, 2016 11:05AM
Would the Pogo V3 (OX820) instructions

http://forum.doozan.com/read.php?3,16017,page=1
http://forum.doozan.com/read.php?2,16044

also work for a Pogo P21 (currently running Arch Linux 2.6)?

Here are some details on the device:

cat /proc/cpuinfo
Processor : ARMv6-compatible processor rev 5 (v6l)
Hardware : Oxsemi NAS

cat /proc/mtd
dev: size erasesize name
mtd0: 08000000 00020000 "NAND 128MiB 3,3V 8-bit"
mtd1: 00e00000 00020000 "boot"
mtd2: 07200000 00020000 "rootfs"
Re: support for Pogo P21?
September 17, 2016 01:44PM
gl Wrote:
-------------------------------------------------------
> Would the Pogo V3 (OX820) instructions
>
> http://forum.doozan.com/read.php?3,16017,page=1
> http://forum.doozan.com/read.php?2,16044
>
> also work for a Pogo P21 (currently running Arch
> Linux 2.6)?
>
> Here are some details on the device:
>
> cat /proc/cpuinfo
> Processor : ARMv6-compatible processor rev 5
> (v6l)
> Hardware : Oxsemi NAS
>
> cat /proc/mtd
>
> dev: size erasesize name
> mtd0: 08000000 00020000 "NAND 128MiB 3,3V 8-bit"
> mtd1: 00e00000 00020000 "boot"
> mtd2: 07200000 00020000 "rootfs"

Yes.That's the same box. These OXNAS are Pogo V3. The V3 without SATA is a "Classic". The V3 with SATA is a "Pro".

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
gl
Re: support for Pogo P21?
September 17, 2016 02:54PM
Thank you for the quick response @bodhi

If I'm reading the instructions correctly, Linux 4.x cannot be booted with the "stock" bootloader. Would the 2.6 image still boot after flashing the uBoot update?

Also should I be concerned that my ```cat /proc/mtd``` from above doesn't exactly match the listing provided in the instructions?
Re: support for Pogo P21?
September 17, 2016 03:18PM
gl,

> If I'm reading the instructions correctly, Linux
> 4.x cannot be booted with the "stock" bootloader.

Not true. stock u-boot can boot Linux 4.x with further setup. It has been a long time ago so I don't have this instruction.

> Would the 2.6 image still boot after flashing the
> uBoot update?

No, it won't be right away. Further set up is needed to be able to boot back to stock OS.

> Also should I be concerned that my ```cat
> /proc/mtd``` from above doesn't exactly match the
> listing provided in the instructions?

Stock has 3 mtds (mtd0 is all NAND in stock). We've redefined it to 2 to make it simpler. But stock mtd1 is at the same location as new mtd0, and stock mtd2 is at the same location as new mtd1. So replace that in the installation instruction and you'll be OK. But be careful, flashing to wrong mtd will result in a semi-bricked box!

mtd0 --> mtd1
mtd1 --> mtd2

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
gl
Re: support for Pogo P21?
September 17, 2016 06:31PM
fw_printenv > current_envs.txt
Warning: Bad CRC, using default environment

I tried to change /etc/fw_env.config to mtd1, still shows the same warning. So would /etc/fw_env.config need to be pointed to mtd0 or mtd1 at this time?

Also is this the expected behaviour (on the first install of uBoot)?

Thanks
Re: support for Pogo P21?
September 18, 2016 12:48AM
gl,

> Also is this the expected behaviour (on the first
> install of uBoot)?

Quote

3. Be sure to save your current uBoot image in mtd0, or have a backup image saved somewhere as precaution.

Dumping NAND mtd0:
nanddump --noecc --omitoob -f mtd0 /dev/mtd0
Save envs:
fw_printenv > current_envs.txt
or
blparam > current_envs.txt

Before you flash the new envs image, it is expected that you will see the CRC error. When you are in stock OS, blparam is the correct tool to save current envs.

After you flashed the default envs image, and if the /etc/fw_env.config is correct, you will see no CRC error.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
gl
Re: support for Pogo P21?
September 18, 2016 11:23AM
Flashing environment file fails with:

/usr/sbin/nandwrite -s 1048576 /dev/mtd1 uboot.2013.10-tld-5.ox820.environment
Input file is not page-aligned. Use the padding option.
nandwrite: error!: Data was only partially written due to error
error 0 (Success)

Thoughts on how to correct? Thanks
Re: support for Pogo P21?
September 18, 2016 02:37PM
gl Wrote:
-------------------------------------------------------
> Flashing environment file fails with:
>
> /usr/sbin/nandwrite -s 1048576 /dev/mtd1
> uboot.2013.10-tld-5.ox820.environment
> Input file is not page-aligned. Use the padding
> option.
> nandwrite: error!: Data was only partially written
> due to error
> error 0 (Success)
>
> Thoughts on how to correct? Thanks

You've flashed the wrong file!

Do step 9 and 10 again.

Quote

9. Erase 1 block starting 0x00100000
/usr/sbin/flash_erase /dev/mtd0 0x00100000 1
Expected output
Erasing 128 Kibyte @ 100000 -- 100 % complete

10. Flash uboot environment to 0x00100000
/usr/sbin/nandwrite -s 1048576 /dev/mtd0 uboot.2013.10-tld-5.ox820.environment.img
Expected output
Writing data to block 8 at offset 0x100000

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
gl
Re: support for Pogo P21?
September 18, 2016 08:33PM
Thank you, good catch. I repeated step 9 and 10 (now with the correct filename :) ), but still see

fw_printenv > current_envs.txt
Warning: Bad CRC, using default environment

I went ahead and repeated steps 6-10, but fw_printenv still doesn't show the expected values.

What am I to try next?
Re: support for Pogo P21?
September 19, 2016 06:24AM
gl Wrote:
-------------------------------------------------------
> Thank you, good catch. I repeated step 9 and 10
> (now with the correct filename :) ), but still
> see
>
> fw_printenv > current_envs.txt
> Warning: Bad CRC, using default environment
>
> I went ahead and repeated steps 6-10, but
> fw_printenv still doesn't show the expected
> values.
>
> What am I to try next?


Post output of

cat /etc/fw_env.config

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
gl
Re: support for Pogo P21?
September 19, 2016 05:19PM
cat /etc/fw_env.config
# Configuration file for fw_(printenv/saveenv) utility.
# Up to two entries are valid, in this case the redundant
# environment sector is assumed present.
# Notice, that the "Number of sectors" is ignored on NOR.

# MTD device name Device offset Env. size Flash sector size Number of sectors
/dev/mtd1 0xc0000 0x20000 0x20000

I also tried to change to /dev/tmd0 (same result).

Thanks
Re: support for Pogo P21?
September 19, 2016 05:35PM
You are probably using the wrong rootfs. Check this Oxnas rootfs and kernel thread:

http://forum.doozan.com/read.php?2,16044

where are you at?

uname -a

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)



Edited 1 time(s). Last edit at 09/19/2016 05:38PM by bodhi.
gl
Re: support for Pogo P21?
September 19, 2016 06:57PM
Yes, rootfs will be next thing to tackle (considering that currently Archlinux with 2.6 kernel is installed, hence I do not have dpkg ...)

uname -a
Linux pogo 2.6.31.6_SMP_820 #6 SMP Thu Jun 14 19:49:57 CDT 2012 armv6l GNU/Linux

But at this time, my understanding is that I need to complete the uboot installation, and see the right values from fw_printenv (which I do not see as per above)

Thanks
Re: support for Pogo P21?
September 19, 2016 07:37PM
See in the u-boot installation thread:
http://forum.doozan.com/read.php?3,16017

1st step in flashing instruction.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
gl
Re: support for Pogo P21?
September 19, 2016 07:43PM
@bodhi, yes http://forum.doozan.com/read.php?3,16017 are the instructions I'm following.

As discussed earlier in this thread, this is what my device shows:

cat /proc/mtd
dev: size erasesize name
mtd0: 08000000 00020000 "NAND 128MiB 3,3V 8-bit"
mtd1: 00e00000 00020000 "boot"
mtd2: 07200000 00020000 "rootfs"

and you directed me to use /dev/mtd1 (instead of /dev/mtd0 during flashing)

Did I misunderstand?
Re: support for Pogo P21?
September 20, 2016 12:51AM
gl,

Look closely, the first number is 0x00100000
1. uBoot envs config and mtd partitions must be defined as followed in your rootfs 

cat /etc/fw_env.config 
# pogoplug v3
  /dev/mtd0               0x00100000      0x20000         0x20000

So replacing mtd0 with mtd1
/dev/mtd1               0x00100000      0x20000         0x20000

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
gl
Re: support for Pogo P21?
September 20, 2016 07:16PM
Got it. I completed steps 11-14 from http://forum.doozan.com/read.php?3,16017 and seeing the right env values.

Would the next step be installing roots Debian-3.17.0-oxnas-tld-1-rootfs-bodhi.tar.bz2 from http://forum.doozan.com/read.php?2,16044 on the SD card?

Thanks
Re: support for Pogo P21?
September 20, 2016 07:37PM
gl Wrote:
-------------------------------------------------------
>
> Would the next step be installing roots
> Debian-3.17.0-oxnas-tld-1-rootfs-bodhi.tar.bz2
> from http://forum.doozan.com/read.php?2,16044 on
> the SD card?

Yes, but on a USB drive. Or if you have SD card inside USB adapter. I'd recommend to install this on a USB flash drive (Sandisk is the most reliable brand for booting).

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: