Merge lp:~liuyq0307/lava-dispatcher/update-mount-partitions into lp:lava-dispatcher
Proposed by
Yongqin Liu
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 473 | ||||
Proposed branch: | lp:~liuyq0307/lava-dispatcher/update-mount-partitions | ||||
Merge into: | lp:lava-dispatcher | ||||
Diff against target: |
56 lines (+16/-10) 2 files modified
lava_dispatcher/config.py (+3/-0) lava_dispatcher/device/master.py (+13/-10) |
||||
To merge this branch: | bzr merge lp:~liuyq0307/lava-dispatcher/update-mount-partitions | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Andy Doan (community) | Approve | ||
Review via email: mp+137106@code.launchpad.net |
This proposal supersedes a proposal from 2012-11-29.
Description of the change
update the source for mount partitions for aosp build and JB4.2 build
Updated according to the review comment.
To post a comment you must log in.
This approach is actually a nice improvement from what we have now. Some
small comments:
On 11/29/2012 05:01 AM, Yongqin Liu wrote: r/config. py' /config. py 2012-11-16 00:47:20 +0000 /config. py 2012-11-29 11:00:29 +0000 android_ org = schema.IntOption() StringOption( ) mountpoint_ path = schema. StringOption( default= "/storage/ sdcard0" ) partitions_ files = schema. StringOption( default= "init.rc" )
> === modified file 'lava_dispatche
> --- lava_dispatcher
> +++ lava_dispatcher
> @@ -66,6 +66,7 @@
> sys_part_
> val = schema.
> sdcard_
> + possible_
Since this is an array, you should declare like: partitions_ files = schema. ListOption( default = [
"init.partition s.rc", "fstab.partitions", "init.rc"])
possible_
> simulator_ version_ command = schema. StringOption( ) StringOption( ) r/default- config/ lava-dispatcher /device- defaults. conf' /default- config/ lava-dispatcher /device- defaults. conf 2012-11-15 14:51:05 +0000 /default- config/ lava-dispatcher /device- defaults. conf 2012-11-29 11:00:29 +0000 _timeout = 240 partitions_ files = init.partitions.rc,
> simulator_command = schema.
>
> === modified file 'lava_dispatche
> --- lava_dispatcher
> +++ lava_dispatcher
> @@ -122,3 +122,8 @@
>
> # how long the disablesuspend script should take to complete
> #disablesuspend
> +
> +# the possible partition files need to be modified for android
> +possible_
> + fstab.partitions,
> + init.rc
Because of my change to config.py above the change to this file isn't
needed now.
> === modified file 'lava_dispatche r/device/ master. py' /device/ master. py 2012-11-21 22:07:45 +0000 /device/ master. py 2012-11-29 11:00:29 +0000 uInitrd_ partitions( session, 'init.rc') uInitrd_ partitions( session, 'init.partition s.rc') board.rc and fstab.* files partitions_ files = string_to_list( _client. config. possible_ partitions_ files)
> --- lava_dispatcher
> +++ lava_dispatcher
> @@ -619,15 +619,24 @@
>
> # The mount partitions have moved from init.rc to init.partitions.rc
> # For backward compatible with early android build, we update both rc files
> - _update_
> - _update_
> + # For omapzoom and aosp and JB4.2 the operation for mounting partitions are
> + # in init.omap4panda
> + possible_
> + session.
> +
due to the config.py change I suggested, you don't need to
"string_to_list" call now.
> + for f in possible_ partitions_ files: is_file_ exist(f) : uInitrd_ partitions( session, f) ANDROID_ TESTER_ PS1) .rc", failok=True)
> + if session.
> + _update_
> + # Will update the PS1 in init.rc in the following
> + # So will not cat the file here
> + if f != 'init.rc':
> + session.run("cat %s" % f, failok=True)
Why the conditional, seems like you should just print it out here and
then delete the call below that always tries to cat it?
>
> session.run(
> 'sed -i "/export PATH/a \ \ \ \ export PS1 \'%s\'" init.rc' %
> target.
>
> session.run("cat init.rc")
> - session.run("cat init.partitions
Why are you keeping the call to "cat init.rc"?