← Back to team overview

ubuntu-phone team mailing list archive

Re: [Porting] Need help with porting problems - initrd / mount

 

Hi,

I also have the same problem and I do not yet overcome it (due to some lack
of time for this task).
You can refer https://lists.launchpad.net/ubuntu-phone/msg05006.html to get
some more info on it.

Per my understanding (probably not 100% correct) the process of deploying
Ubuntu is the following
1. It relies on recovery procedure. AOSP/Codeaurora does not have the same
recovery procedure as CM, so you will need to do additional changes in it
(beyond porting phablet itself). Specifically, some busybox utilities
should be integrated into recovery
2. There are 2 models of deploying/running ubuntu:
-  first one (older) is using /data/ubuntu folder for the
hardware-independent ubuntu filesystem. This model is deprecated and you
(most likely) won't be able to use it (it depends on what phablet branch
did you ported, I suppose. Since you already see initrd procedure, you use
the newer model). Recovery procedure unpacks autodeploy.zip into
/data/ubuntu
- second is using /data/system.img for ubuntu. This system.img seems
created by phablet-flash utility by creating some specific script and
placing it to /cache partition and running recovery. Probably there is a
procedure to convert old model to new one (I did not finish with learning
it). The problem with this utility is that it does allow you to work with
some predefined/supported devices.
This new model is also using your built (or original, from stock)
system.img (converted to EXT2,3or4) as the android image to be run/used in
LXC container. This is accomplished by phablet-flash, I guess.

At the moment I'm considering 2 ways to proceed:
1. Create the ubuntu system.img manually or while building Android parts.
2. Modify phablet-flash to create the ubuntu system.img for my device.




2013/11/21 Ivo Stoyanov <ivostoy@xxxxxxxxx>

> Greetings,
>
> I need help related to UT porting to new device. I am not kernel dev and I
> struggling for 2nd week.
>
> I followed the porting guide, I am able to build and boot the kernel.
> Stuck with some mount/partition problems...
>
> My goal is Inforce Computing IFC6410 MSM8960 dev.board.
> I have working Android 4.1 kernel from IFC and also Nexus4 (mako) device
> and build to compare to.
>
> I see mounting errors during boot.
> [    6.175919] initrd: mounting /dev/mmcblk0p13
> [    6.185106] EXT3-fs (mmcblk0p13): error: couldn't mount because of
> unsupported optional features (40)
> [    6.252159] EXT2-fs (mmcblk0p13): error: couldn't mount because of
> unsupported optional features (44)
> [    6.343262] EXT4-fs (mmcblk0p13): recovery complete
> [    6.348084] EXT4-fs (mmcblk0p13): mounted filesystem with ordered data
> mode. Opts: (null)
> [    6.356233] initrd: Couldn't find a system partition.
> Couldn't find a system partition. Spawning adbd ...
>
> Luckily I can do adb shell - and I see only initrd barebone system.
>
> p13 is userdata.img. For some reason the image smaller than I'd expect.
>
> Initially I used same partitions as Android but noticed system and usr are
> too small so I tried to bump them.
>
> Here is related part of BoardConfig:
>
> BOARD_KERNEL_CMDLINE := console=ttyHSL0,115200,n8
> androidboot.hardware=msm8960
>
> BOARD_MKBOOTIMG_ARGS := --ramdisk_offset 0x01600000
>
> # from mako
> #BOARD_BOOTIMAGE_PARTITION_SIZE := 23068672 # 22M
> #BOARD_RECOVERYIMAGE_PARTITION_SIZE := 23068672 # 22M
> #BOARD_SYSTEMIMAGE_PARTITION_SIZE := 880803840 # 840M
> #BOARD_USERDATAIMAGE_PARTITION_SIZE := 6189744128 # 5.9G
> #BOARD_FLASH_BLOCK_SIZE := 131072 # (BOARD_KERNEL_PAGESIZE * 64)
>
> TARGET_USERIMAGES_USE_EXT4 := true
> BOARD_BOOTIMAGE_PARTITION_SIZE := 0x00A00000
> BOARD_RECOVERYIMAGE_PARTITION_SIZE := 0x00A00000
>
> #BOARD_USERDATAIMAGE_PARTITION_SIZE:= 10 737 418 240 # 10G?
> BOARD_USERDATAIMAGE_PARTITION_SIZE :=  1547436032 # 6189744128
> TARGET_USERIMAGES_USE_EXT4 := true
>
> #BOARD_SYSTEMIMAGE_PARTITION_SIZE := 536870912
> BOARD_SYSTEMIMAGE_PARTITION_SIZE := 880803840 # 840M
>
> BOARD_CACHEIMAGE_PARTITION_SIZE := 33554432
> BOARD_PERSISTIMAGE_PARTITION_SIZE := 5242880
> BOARD_TOMBSTONESIMAGE_PARTITION_SIZE := 268435456
> BOARD_FLASH_BLOCK_SIZE := 131072 # (BOARD_KERNEL_PAGESIZE * 64)
>
> BOARD_USES_SECURE_SERVICES := true
>
> Any help is appreciated.
>
> Thanks
> -Ivo
>
> --
> Mailing list: https://launchpad.net/~ubuntu-phone
> Post to     : ubuntu-phone@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~ubuntu-phone
> More help   : https://help.launchpad.net/ListHelp
>
>

References