Scripts in uInitrd loose execute permissions

Bug #1099486 reported by Tixy (Jon Medhurst)
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Linaro Android
Fix Released
Undecided
Bernhard Rosenkraenzer

Bug Description

vexpress recently added a shell scripts for inclusion into the initrd to be executed at boot (See change http://review.android.git.linaro.org/#change,3240)

This script has the execute permission bit set in git but by the time it ends up in the uInitrd the execute permissions are lost.
I see that after a build has finished, the copy generated in the 'root' directory (out/target/product/vexpress/root) has the correct execute permissions so it seems the problem is in the step where the uInitrd is created.

Changed in linaro-landing-team-arm:
importance: Undecided → High
assignee: nobody → Tixy (Jon Medhurst) (tixy)
milestone: none → 2013.01
Revision history for this message
Bernhard Rosenkraenzer (berolinux) wrote :

This is probably related to the way Android handles filesystem creation (probably done that way to support building on certain retarded wannabe operating systems that don't have proper permissions in their filesystems).

What files get what permissions is defined in system/core/include/private/android_filesystem_config.h

Revision history for this message
Tixy (Jon Medhurst) (tixy) wrote : Re: [Bug 1099486] Re: Scripts in uInitrd loose execute permissions

On Mon, 2013-01-14 at 18:09 +0000, Bernhard Rosenkraenzer wrote:
> What files get what permissions is defined in
> system/core/include/private/android_filesystem_config.h

Thanks for that vital clue :-)

Think it would probably be best to put the script in /sbin/ then?
(Or rename it to match init*)

--
Tixy

Revision history for this message
Bernhard Rosenkraenzer (berolinux) wrote :

Both of those should work -- another option (along the same lines) would be to patch android_filesystem_config.h to make *.sh executable, given that's what shell scripts typically are.

All 3 approaches work for me and I don't have a particular preference.

Changed in linaro-android:
assignee: nobody → Bernhard Rosenkraenzer (berolinux)
milestone: none → 13.01
status: New → Triaged
Revision history for this message
Tixy (Jon Medhurst) (tixy) wrote :

On Mon, 2013-01-14 at 21:59 +0000, Bernhard Rosenkraenzer wrote:
> Both of those should work -- another option (along the same lines) would
> be to patch android_filesystem_config.h to make *.sh executable

I thought of that but the wildcard matching looks like its only
supported at the end of a filename, not the start, as required for
'*.sh'

Revision history for this message
Tixy (Jon Medhurst) (tixy) wrote :

Fixed by moving set_irq_affinity.sh to /sbin/ See: http://review.android.git.linaro.org/#change,3247

Changed in linaro-landing-team-arm:
status: New → Fix Committed
Changed in linaro-android:
status: Triaged → Fix Committed
Ryan Harkin (ryanharkin)
Changed in linaro-landing-team-arm:
status: Fix Committed → Fix Released
Changed in linaro-android:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.