• Home
  • Help
  • Search
  • Login
  • Register
  Show Posts
Pages: [1]
1  General Category / General Discussion / 3G USB Stick on SheevaPlug on: May 31, 2013, 03:54:42 AM
HI,
I have Alcatel 3G USB stick. Do you have any suggestion on how to adopt it to Debian?
Alternatively can you suggest any other stick that is supported by Debian?

Thanks.
2  General Category / General Discussion / Re: UBIFS failure on SheevaPlug Basic on: November 09, 2012, 02:34:05 AM
I'm still fighting.
Please help me.

1. Problem Description
---------------------------------
1.1 Setup
I have a SheevaPlug running Debian. System is installed on nand Flash.
Installation process is following:
- First I boot up with USB stick and Debian installer images on it
- Get Debian Installed and running on USB stick
- Run the commands below to get it moved to Flash:

ubiformat /dev/mtd2 -s 512
ubiattach /dev/ubi_ctrl -m 2
ubimkvol /dev/ubi0 -N rootfs -m

mount -t ubifs ubi0:rootfs /mnt
mkdir /tmp/rootfs
mount -o bind / /tmp/rootfs/

cp -a /tmp/rootfs/* /mnt/
cp -a /boot /mnt/

- Make required changes in u-boot configuration and system starts to work.

1.2 Failure
Everything is all right until I get power surge
After that system fails with:

Marvell>> boot

UBI: mtd1 is detached from ubi0
Creating 1 MTD partitions on "nand0":
0x000000500000-0x000020000000 : "mtd=2"
UBI: attaching mtd1 to ubi0
UBI: physical eraseblock size:   131072 bytes (128 KiB)
UBI: logical eraseblock size:    129024 bytes
UBI: smallest flash I/O unit:    2048
UBI: sub-page size:              512
UBI: VID header offset:          512 (aligned 512)
UBI: data offset:                2048
UBI: attached mtd1 to ubi0
UBI: MTD device name:            "mtd=2"
UBI: MTD device size:            507 MiB
UBI: number of good PEBs:        4055
UBI: number of bad PEBs:         1
UBI: max. allowed volumes:       128
UBI: wear-leveling threshold:    4096
UBI: number of internal volumes: 1
UBI: number of user volumes:     1
UBI: available PEBs:             0
UBI: total number of reserved PEBs: 4055
UBI: number of PEBs reserved for bad PEB handling: 40
UBI: max/mean erase counter: 1/0
UBIFS: recovery needed
Error reading superblock on volume 'ubi:rootfs'!
UBIFS not mounted, use ubifs mount to mount volume first!
UBIFS not mounted, use ubifs mount to mount volume first!
Wrong Image Format for bootm command
ERROR: can't get kernel image!

1.3 Recovery
If I run again from the USB stick and mount Flash partition Debian
kernel manage to recover it:

root@debian:~# mount -t ubifs ubi0:rootfs /mnt
[  306.205029] UBIFS: recovery needed
[  309.341987] UBIFS: recovery completed
[  309.345705] UBIFS: mounted UBI device 0, volume 0, name "rootfs"
[  309.351738] UBIFS: file system size:   515192832 bytes (503118 KiB,
491 MiB, 3993 LEBs)
[  309.359789] UBIFS: journal size:       25804800 bytes (25200 KiB,
24 MiB, 200 LEBs)
[  309.367495] UBIFS: media format:       w4/r0 (latest is w4/r0)
[  309.373352] UBIFS: default compressor: lzo
[  309.377479] UBIFS: reserved for root:  4952683 bytes (4836 KiB)

2. Fixing
======
2.1. My first direction is to update u-boot with latest patches. There
is a chance it will let u-boot be able to mount broken partition.
There is another thread here where I work on it "Latest SheevaPlug u-boot"

2.2.
My second plan is to separate rootfs partition into two partitions.
One would be read only and will keep all static data. The second
partition will be RW and will contain changing data.
Actually all I need is to
1. Arrange let's say /flash_rw partiotion
2. Make rootfs partition read only
3. Fix u-boot settings
And here I'm not sure how to do all this.

2.3. u-boot
I assume I should start with changing partitioning in u-boot:
Currently I have
mtdparts mtdparts=orion_nand:0xa0000@0x0(u-boot),0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs)

How to split rootfs into two partitions?

============
Do you think such approach will help to survive power surges?
What should be next steps?

Thanks a lot.
3  General Category / General Discussion / UBIFS failure on SheevaPlug Basic on: October 28, 2012, 02:48:03 AM
HI,
I'm straggle from UBIFS failure on my box that happens after power short. The boot in this case looks like:

Code:
Marvell>> boot
UBI: mtd1 is detached from ubi0
Creating 1 MTD partitions on "nand0":
0x000000500000-0x000020000000 : "mtd=2"
UBI: attaching mtd1 to ubi0
UBI: physical eraseblock size:   131072 bytes (128 KiB)
UBI: logical eraseblock size:    129024 bytes
UBI: smallest flash I/O unit:    2048
UBI: sub-page size:              512
UBI: VID header offset:          512 (aligned 512)
UBI: data offset:                2048
UBI: attached mtd1 to ubi0
UBI: MTD device name:            "mtd=2"
UBI: MTD device size:            507 MiB
UBI: number of good PEBs:        4055
UBI: number of bad PEBs:         1
UBI: max. allowed volumes:       128
UBI: wear-leveling threshold:    4096
UBI: number of internal volumes: 1
UBI: number of user volumes:     1
UBI: available PEBs:             0
UBI: total number of reserved PEBs: 4055
UBI: number of PEBs reserved for bad PEB handling: 40
UBI: max/mean erase counter: 1/0
UBIFS: recovery needed
Error reading superblock on volume 'ubi:rootfs'!
UBIFS not mounted, use ubifs mount to mount volume first!
UBIFS not mounted, use ubifs mount to mount volume first!
Wrong Image Format for bootm command
ERROR: can't get kernel image!
Marvell>>
 

The recovery is to boot from USB stick and mount UBIFS partition:

Code:
root@debian:~# mount -t ubifs ubi0:rootfs /mnt
[  306.205029] UBIFS: recovery needed
[  309.341987] UBIFS: recovery completed
[  309.345705] UBIFS: mounted UBI device 0, volume 0, name "rootfs"
[  309.351738] UBIFS: file system size:   515192832 bytes (503118 KiB, 491 MiB, 3993 LEBs)
[  309.359789] UBIFS: journal size:       25804800 bytes (25200 KiB, 24 MiB, 200 LEBs)
[  309.367495] UBIFS: media format:       w4/r0 (latest is w4/r0)
[  309.373352] UBIFS: default compressor: lzo
[  309.377479] UBIFS: reserved for root:  4952683 bytes (4836 KiB)

Looks like mount can recover partition while u-boot can't.
Here are the questions I try to answer to go on:
  • Why it happens. I mean why I get broken UBIFS that can not be recovered. I read about UBIFS and they state that it is oriented to recover from power shorts
  • Shoul I better use another file system? Like JFFS2 for example? What usually is used on SheevaPlug
  • Maybe a latest u-boot version cat treat ubifs recovery better?
  • What else can be done to make system more stable

Thanks a lot
4  Hardware and U-Boot firmware / U-Boot stuff / UBIFS: recovery needed on: October 19, 2012, 10:50:00 AM
I have installed debian on my SheevaPlug. After a few days of working it fails and reboot gives me following:


Marvell>> boot
UBI: mtd1 is detached from ubi0
Creating 1 MTD partitions on "nand0":
0x000000500000-0x000020000000 : "mtd=2"
UBI: attaching mtd1 to ubi0
UBI: physical eraseblock size:   131072 bytes (128 KiB)
UBI: logical eraseblock size:    129024 bytes
UBI: smallest flash I/O unit:    2048
UBI: sub-page size:              512
UBI: VID header offset:          512 (aligned 512)
UBI: data offset:                2048
UBI: attached mtd1 to ubi0
UBI: MTD device name:            "mtd=2"
UBI: MTD device size:            507 MiB
UBI: number of good PEBs:        4055
UBI: number of bad PEBs:         1
UBI: max. allowed volumes:       128
UBI: wear-leveling threshold:    4096
UBI: number of internal volumes: 1
UBI: number of user volumes:     1
UBI: available PEBs:             0
UBI: total number of reserved PEBs: 4055
UBI: number of PEBs reserved for bad PEB handling: 40
UBI: max/mean erase counter: 1/0
UBIFS: recovery needed
Error reading superblock on volume 'ubi:rootfs'!
UBIFS not mounted, use ubifs mount to mount volume first!
UBIFS not mounted, use ubifs mount to mount volume first!
Wrong Image Format for bootm command
ERROR: can't get kernel image!
Marvell>>


More likely problem is related to file system overflow caused by my process that writes too much debug output via syslog.

Once I have recovered by
- booting with USB stick,
- mounting Flash partition
- removing log files from /mount/var/log/messages
After that I can boot again from Flash.

But now board is not at my hands and all I can do is to ask customer to enter a commands via RS232 terminal.

My questions are:
  • Is where any wayt to recover it with uboot commands only?
  • What actually happens? I mean what is problematic in u-boot output above and where actually the problem starts?

Thanks a lot.
5  Hardware and U-Boot firmware / U-Boot stuff / Re: Recover after u-boot erase on: January 28, 2012, 12:18:56 AM
HI,
I have recovered with SheevaPlug Installer.
I was able to run it only under my Linux because FTDI driver for Windows did not work.

But I have to say that support level and code quality from Globalscale (or Marvell not sure who did it) is under any expectations.
- There is no documentation.
- I had to fix PHP script
- In README no mention about requirements to preinstall libusb-0.1 and ftdilib. I had to do it before I was able to reflash bootloader with JTAG via USB.
- On Windows drivers set is not working. I've seen thread where people managed to run I, I could not and has passed to Linux.
 
6  Hardware and U-Boot firmware / U-Boot stuff / Recover after u-boot erase on: January 25, 2012, 12:01:15 PM
How to recover u-boot?

After doing following I've lost the SheevaPlug. What can be done?

TFTP from server 192.168.1.100; our IP address is 192.168.1.110
Filename 'u-boot.kwb'.
Load address: 0x8000000
Loading: #################################################################
         ########
done
Bytes transferred = 372512 (5af20 hex)
Marvell>> nand erase 0x0 0xa0000

NAND erase: device 0 offset 0x0, size 0xa0000
Erasing at 0x80000 -- 100% complete.
OK
Marvell>> nand write 0x0800000 0x0 0xa0000

NAND write: device 0 offset 0x0, size 0xa0000
 655360 bytes written: OK
Marvell>> reset

NOTHING
7  Hardware and U-Boot firmware / Hardware / Accessing additional UARTS on: January 24, 2012, 08:45:07 AM
Hi,
I'm about to give up with my sheevaplug basic.

For my application I need at least one COM port to communicate with external device. the /dev/ttyS0 available on J7 UART connector is used by U-boot and kernel and I do not want to touch it.
There are 3 additional ports ttyS1,2,3. I'm trying to find out if they are available somewhere on PCB. Unfortunately the schematics officially available is not up to date and I can't how CPU UARTs are routed on PCB to try to catch them. I wrote a number of messages to globascale with request to provide update schematics but so far no luck.

Any help before I send my board back for refund?
8  General Category / General Discussion / Re: apt-get update failing to find servers on: January 24, 2012, 04:52:01 AM
Hi,
So what is the resolution? I can't 
app-get install gcc
9  General Category / General Discussion / cross compilation on windows or native on: January 24, 2012, 01:14:12 AM
Hi,
I have received my sheevaplug baic and starting to work on it.
I have successfully connected to plug via USB-RS232 and SSH. I'm not a new in Linux word but can't say i'm a freak.

First of all I'm trying to arrange a working environment.  Most of my PC's are Windows based and I'm used to work under Windows with my favorite editors. Although I can use VI and not bad in Unix prompts (mostly bash). So my regular environment is Windows PC with Cygwin terminal.

1. My first question is if there is a way to build gcc cross compiler to run under Cygwin?
2. Is it possible to install native gcc into sheevaplug?

I have installed gcc on my Linux remote host and manage to run Hello World application. But it would be much more convenient for me to work on my Windows host with SSH to sheevaplug.
Thanks for the info.
Pages: [1]