Why does vold require an fstab named with ro.hardware?

860 views
Skip to first unread message

Kyle Russell

unread,
Feb 3, 2014, 10:07:36 AM2/3/14
to android...@googlegroups.com
Why did vold switch from loading the filename "vold.fstab" to "fstab.${ro.hardware}"?  It seems like there's only one fstab file that ever gets loaded, and it's difficult to determine the "ro.hardware" property value during a build, which is when you need to know the filename to install the fstab file into an image.  (In other words, the filename change seems to introduce more variability, especially during the build, that doesn't really buy anything.)  Can anyone help explain?

rishi gupta

unread,
Feb 4, 2014, 10:39:09 AM2/4/14
to android...@googlegroups.com
In simple terms, ro.hardware is constant value whose value can be seen from build.prop.
ro.hardware is mainly used for setting many properties, configuration files etc.

Kyle Russell

unread,
Feb 4, 2014, 11:15:28 AM2/4/14
to android...@googlegroups.com
I've not seen anywhere that ro.hardware gets set based on build.prop.  init sets ro.hardware based on the "Hardware" entry in /proc/cpuinfo (or an optional kernel command line argument), which is not based on a particular Android build, but underlying CPU arch.  When building Android for different devices, it seems like this introduces an additional dependency on Android's build to make sure you install the fstab file with the appropriate name.  Why not just leave the name "vold.fstab"?

rishi gupta

unread,
Feb 5, 2014, 1:30:03 AM2/5/14
to krusse...@gmail.com, android...@googlegroups.com
Yes, it introduces variability yet it might also be required. For example; default init.rc imports "import /init.${ro.hardware}.rc" to include OEM specific stuffs.

The main purpose seems to be "provide enough margin to OEM" for their configurations.
adb shell getprop gives [ro.hardware]: [qcom] in my case.

AOSP has to contain both common file and way to include vendor specific file.


--
--
unsubscribe: android-porti...@googlegroups.com
website: http://groups.google.com/group/android-porting
 
---
You received this message because you are subscribed to a topic in the Google Groups "android-porting" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/android-porting/2gQUHLsV19c/unsubscribe.
To unsubscribe from this group and all its topics, send an email to android-porti...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages