init.qcom.usb.sh: Add support for lun0 as CDROM in mass-storage
Add cdrom as a LUN for mass-storage which can be used for storing system required data. Change-Id: I590cdf61a859dc6be0b06a5791b66c3dfb95bc18
This commit is contained in:
parent
9624032abe
commit
59986c69ce
|
@ -124,3 +124,22 @@ case "$usb_config" in
|
|||
* ) ;; #USB persist config exists, do nothing
|
||||
esac
|
||||
|
||||
#
|
||||
# Add support for exposing lun0 as cdrom in mass-storage
|
||||
#
|
||||
target=`getprop ro.product.device`
|
||||
cdromname="/system/etc/cdrom_install.iso"
|
||||
cdromenable=`getprop persist.service.cdrom.enable`
|
||||
case "$target" in
|
||||
"msm7627a")
|
||||
case "$cdromenable" in
|
||||
0)
|
||||
echo "" > /sys/class/android_usb/android0/f_mass_storage/lun0/file
|
||||
;;
|
||||
1)
|
||||
echo "mounting usbcdrom lun"
|
||||
echo $cdromname > /sys/class/android_usb/android0/f_mass_storage/lun0/file
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
|
|
Loading…
Reference in New Issue