Rootfs for PXA270 running with 2.6.26.x

This is a discussion on Rootfs for PXA270 running with 2.6.26.x within the Embedded forums, part of the Help category; Hi all, thanks for reading first! I have a rootfs for 2.6.16 on PXA270, and now updated the kernel to 2.6.26, but the system shows: Kernel panic: not syncing VFS: ...

Go Back   Unix Linux Forum > Unix > Linux > Help > Embedded

FixUnix.com - Unix Linux Forums

Unix Content Register FAQ Calendar Search Today's Posts Mark Forums Read
  #1  
Old 08-20-2008, 03:20 AM
Default Rootfs for PXA270 running with 2.6.26.x

Hi all, thanks for reading first!

I have a rootfs for 2.6.16 on PXA270, and now updated the kernel to
2.6.26, but the system shows:
Kernel panic: not syncing VFS: Unable to mount root fs on unknown
block(2,0)

So I am wondering if my rootfs(originally for 2.6.16) should be
replaced with a 2.6.26-compatible one.
Is there any downloadable one? Or I must use PTXdist to compile one
myself? It seems to take days to compile one using ptx.

Thanks!
Reply With Quote
  #2  
Old 08-20-2008, 08:51 AM
Default Re: Rootfs for PXA270 running with 2.6.26.x

Kcin wrote:

> Hi all, thanks for reading first!
>
> I have a rootfs for 2.6.16 on PXA270, and now updated the kernel to
> 2.6.26, but the system shows:
> Kernel panic: not syncing VFS: Unable to mount root fs on unknown
> block(2,0)


Does your new kernel support the same devices and filesystems to boot from
your media? Where is your root filesystem stored on? Flash? CF? USB?

> So I am wondering if my rootfs(originally for 2.6.16) should be
> replaced with a 2.6.26-compatible one.


Consider to enable OABI in your new kernel. I guess your old root filesystem
using OABI and not the new EABI. The kernel must support it.

> Is there any downloadable one? Or I must use PTXdist to compile one
> myself? It seems to take days to compile one using ptx.


$ ptxdist targetinstall kernel

will only build the kernel for you (if you don't want to build the whole
project).

jbe
Reply With Quote
  #3  
Old 08-21-2008, 03:27 AM
Default Re: Rootfs for PXA270 running with 2.6.26.x

The rootfs is in flash, the partitioning is like this:
Flash: | U-Boot 1.1.4 | uImage (Kernel 2.6.26) | rootfs.jffs2 |

And it's set to mount at:
root=\dev\mtdblock2

I set it to \dev\mtdblock0, then it doesn't show the "unable to mount"
error, but the system cannot boot up. I guess it's because \dev
\mtdblock0 is for u-boot?

How can I switch the kernel to support OABI/EABI? And is it possible
to check whether a rootfs is OABI or EABI??

Many thanks!

On Aug 20, 8:51*pm, Juergen Beisert wrote:
> Kcin wrote:
> > Hi all, thanks for reading first!

>
> > I have a rootfs for 2.6.16 on PXA270, and now updated the kernel to
> > 2.6.26, but the system shows:
> > Kernel panic: not syncing VFS: Unable to mount root fs on unknown
> > block(2,0)

>
> Does your new kernel support the same devices and filesystems to boot from
> your media? Where is your root filesystem stored on? Flash? CF? USB?
>
> > So I am wondering if my rootfs(originally for 2.6.16) should be
> > replaced with a 2.6.26-compatible one.

>
> Consider to enable OABI in your new kernel. I guess your old root filesystem
> using OABI and not the new EABI. The kernel must support it.
>
> > Is there any downloadable one? Or I must use PTXdist to compile one
> > myself? It seems to take days to compile one using ptx.

>
> $ ptxdist targetinstall kernel
>
> will only build the kernel for you (if you don't want to build the whole
> project).
>
> jbe


Reply With Quote
  #4  
Old 08-21-2008, 03:53 AM
Default Re: Rootfs for PXA270 running with 2.6.26.x

Kcin wrote:

> The rootfs is in flash, the partitioning is like this:
> Flash: | U-Boot 1.1.4 | uImage (Kernel 2.6.26) | rootfs.jffs2 |


Does your new kernel know the flash device? Does it know this partition
layout?

Did you enable (kernel):

- CFI Flash device in physical memory map
- (0x00000000) Physical start address of flash mapping
- (0x02000000) Physical length of flash mapping
- (4) Bank width in octets <--- depends on your hardware

-[*] MTD partitioning support
-[*] Command line partition table parsing
- <*> Caching block device access to MTD devices

The kernel should output something like this:

> [...]
> physmap flash device: 2000000 at 0
> phys_mapped_flash: Found 2 x16 devices at 0x0 in 32-bit bank
> Intel/Sharp Extended Query Table at 0x0031
> Using buffer write method
> cfi_cmdset_0001: Erase suspend on write enabled
> 3 cmdlinepart partitions found on MTD device phys_mapped_flash
> Creating 3 MTD partitions on "phys_mapped_flash":
> 0x00000000-0x00040000 : "u-boot"
> 0x00040000-0x00240000 : "kernel"
> 0x00240000-0x02000000 : "root"
> [...]


> And it's set to mount at:
> root=\dev\mtdblock2
>
> I set it to \dev\mtdblock0, then it doesn't show the "unable to mount"
> error, but the system cannot boot up. I guess it's because \dev
> \mtdblock0 is for u-boot?


Sure. Only the rootfs.jffs2 partition contains a valid filesystem. BTW:
Maybe the jffs2 filesystem format changes between 2.6.16 and 2.6.26?

> How can I switch the kernel to support OABI/EABI?


$ ptxdist kernelconfig
-> Kernel Features
-> enable "Use the ARM EABI to compile the kernel"
-> enable "Allow old ABI binaries to run with this kernel"

> And is it possible to check whether a rootfs is OABI or EABI??


Don't know. But if you are running a 2.6.16 kernel it must be OABI.

jbe
Reply With Quote
  #5  
Old 08-22-2008, 08:50 PM
Default Re: Rootfs for PXA270 running with 2.6.26.x

For the kernel config, I have these setting:
CONFIG_MTD_PHYSMAP=y
CONFIG_MTD_PHYSMAP_START=0x00000000
CONFIG_MTD_PHYSMAP_LEN=0x2000000
CONFIG_MTD_PHYSMAP_BANKWIDTH=4

And I have this argument in uboot:
mtdparts=phys_mapped_flash:256k(u-boot)ro,2048k(kernel),-rs

From the web, I found that the rootfs should be mounted in 1f01
instead of 1f02 between different versions. Does it explain why my
rootfs cannot be mounted in mtd2 when I use 2.6.26 kernel?

And I am suggested to type these two commands when updating the
kernel:
# flash_unlock /dev/mtd0
# flashcp -v /tmp/u-boot.bin /dev/mtd0

What do they do really?

Thanks!

On Aug 21, 3:53*pm, Juergen Beisert wrote:
> Kcin wrote:
> > The rootfs is in flash, the partitioning is like this:
> > Flash: | U-Boot 1.1.4 | uImage (Kernel 2.6.26) | rootfs.jffs2 |

>
> Does your new kernel know the flash device? Does it know this partition
> layout?
>
> Did you enable (kernel):
>
> - CFI Flash device in physical memory map
> - (0x00000000) Physical start address of flash mapping
> - (0x02000000) Physical length of flash mapping
> - (4) * Bank width in octets *<--- depends on your hardware
>
> -[*] * MTD partitioning support
> *-[*] * * Command line partition table parsing
> - <*> * Caching block device access to MTD devices
>
> The kernel should output something like this:
>
>
>
> > [...]
> > physmap flash device: 2000000 at 0
> > phys_mapped_flash: Found 2 x16 devices at 0x0 in 32-bit bank
> > *Intel/Sharp Extended Query Table at 0x0031
> > Using buffer write method
> > cfi_cmdset_0001: Erase suspend on write enabled
> > 3 cmdlinepart partitions found on MTD device phys_mapped_flash
> > Creating 3 MTD partitions on "phys_mapped_flash":
> > 0x00000000-0x00040000 : "u-boot"
> > 0x00040000-0x00240000 : "kernel"
> > 0x00240000-0x02000000 : "root"
> > [...]
> > And it's set to mount at:
> > root=\dev\mtdblock2

>
> > I set it to \dev\mtdblock0, then it doesn't show the "unable to mount"
> > error, but the system cannot boot up. I guess it's because \dev
> > \mtdblock0 is for u-boot?

>
> Sure. Only the rootfs.jffs2 partition contains a valid filesystem. BTW:
> Maybe the jffs2 filesystem format changes between 2.6.16 and 2.6.26?
>
> > How can I switch the kernel to support OABI/EABI?

>
> $ ptxdist kernelconfig
> *-> Kernel Features
> * *-> enable "Use the ARM EABI to compile the kernel"
> * * *-> enable "Allow old ABI binaries to run with this kernel"
>
> > And is it possible to check whether a rootfs is OABI or EABI??

>
> Don't know. But if you are running a 2.6.16 kernel it must be OABI.
>
> jbe


Reply With Quote
  #6  
Old 08-23-2008, 03:54 PM
Default Re: Rootfs for PXA270 running with 2.6.26.x

Kcin wrote:
> From the web, I found that the rootfs should be mounted in 1f01
> instead of 1f02 between different versions.


??????????????????

> And I am suggested to type these two commands when updating the
> kernel:
> # flash_unlock /dev/mtd0
> # flashcp -v /tmp/u-boot.bin /dev/mtd0


Can also be done from inside U-Boot. Much easier.

jbe

Reply With Quote
Reply

Thread Tools


All times are GMT -5. The time now is 10:40 AM.

In an effort to better serve ads to our visitors, cookies are used on Fixunix.com. For more information, check out our Privacy Policy.

Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
Ad Management by RedTyger