mirror of
https://gitee.com/openharmony/startup_init
synced 2024-12-11 12:47:08 +00:00
!1196 move init.usb.configfs.cfg to drivers
Merge pull request !1196 from 吴成文/master
This commit is contained in:
commit
f7b45cf7e5
@ -110,11 +110,6 @@ if (defined(ohos_lite)) {
|
||||
part_name = "init"
|
||||
}
|
||||
|
||||
ohos_prebuilt_etc("init.usb.configfs.cfg") {
|
||||
source = "//base/startup/init/services/etc/init.usb.configfs.cfg"
|
||||
part_name = "init"
|
||||
}
|
||||
|
||||
ohos_prebuilt_para("ohos.para") {
|
||||
source = "//base/startup/init/services/etc/param/ohos.para"
|
||||
install_images = [
|
||||
@ -223,7 +218,6 @@ if (defined(ohos_lite)) {
|
||||
":init.cfg",
|
||||
":init.reboot",
|
||||
":init.usb.cfg",
|
||||
":init.usb.configfs.cfg",
|
||||
":misc.cfg",
|
||||
":ohos.para",
|
||||
":ohos.para.dac",
|
||||
|
@ -1,98 +0,0 @@
|
||||
{
|
||||
"jobs" : [{
|
||||
"name" : "param:sys.usb.config=none && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.config=none && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"write /config/usb_gadget/g1/UDC none",
|
||||
"stop hdcd",
|
||||
"setparam sys.usb.ffs.ready 0",
|
||||
"write /config/usb_gadget/g1/bDeviceClass 0",
|
||||
"write /config/usb_gadget/g1/bDeviceSubClass 0",
|
||||
"write /config/usb_gadget/g1/bDeviceProtocol 0",
|
||||
"rm /config/usb_gadget/g1/configs/b.1/f1",
|
||||
"rm /config/usb_gadget/g1/configs/b.1/rndis.rn0",
|
||||
"rmdir /config/usb_gadget/g1/functions/rndis.rn0",
|
||||
"rm /config/usb_gadget/g1/configs/b.1/mass_storage.usb",
|
||||
"rmdir /config/usb_gadget/g1/functions/mass_storage.usb",
|
||||
"setparam sys.usb.state ${sys.usb.config}"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:startup.service.ctl.hdcd=5",
|
||||
"condition" : "startup.service.ctl.hdcd=5",
|
||||
"cmds" : [
|
||||
"setparam sys.usb.ffs.ready 0"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:sys.usb.config=hdc && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.config=hdc && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"start hdcd"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:sys.usb.ffs.ready=1 && param:sys.usb.config=hdc && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.ffs.ready=1 && sys.usb.config=hdc && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration hdc",
|
||||
"symlink /config/usb_gadget/g1/functions/ffs.hdc /config/usb_gadget/g1/configs/b.1/f1",
|
||||
"write /config/usb_gadget/g1/UDC ${sys.usb.controller}",
|
||||
"setparam sys.usb.state ${sys.usb.config}"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:sys.usb.config=rndis && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.config=rndis && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"mkdir /config/usb_gadget/g1/functions/rndis.rn0",
|
||||
"write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration rndis",
|
||||
"symlink /config/usb_gadget/g1/functions/rndis.rn0 /config/usb_gadget/g1/configs/b.1/rndis.rn0",
|
||||
"write /config/usb_gadget/g1/UDC ${sys.usb.controller}",
|
||||
"setparam sys.usb.state ${sys.usb.config}"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:sys.usb.config=rndis_hdc && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.config=rndis_hdc && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"mkdir /config/usb_gadget/g1/functions/rndis.rn0",
|
||||
"symlink /config/usb_gadget/g1/functions/rndis.rn0 /config/usb_gadget/g1/configs/b.1/rndis.rn0",
|
||||
"start hdcd"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:sys.usb.ffs.ready=1 && param:sys.usb.config=rndis_hdc && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.ffs.ready=1 && sys.usb.config=rndis_hdc && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration rndis_hdc",
|
||||
"symlink /config/usb_gadget/g1/functions/ffs.hdc /config/usb_gadget/g1/configs/b.1/f1",
|
||||
"write /config/usb_gadget/g1/UDC ${sys.usb.controller}",
|
||||
"setparam sys.usb.state ${sys.usb.config}"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:sys.usb.config=storage && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.config=storage && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"mkdir /config/usb_gadget/g1/functions/mass_storage.usb",
|
||||
"write /config/usb_gadget/g1/functions/mass_storage.usb/lun.0/file /dev/block/mmcblk0p11",
|
||||
"write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration mass_storage",
|
||||
"symlink /config/usb_gadget/g1/functions/mass_storage.usb /config/usb_gadget/g1/configs/b.1/mass_storage.usb",
|
||||
"write /config/usb_gadget/g1/UDC ${sys.usb.controller}",
|
||||
"setparam sys.usb.state ${sys.usb.config}"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:sys.usb.config=storage_hdc && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.config=storage_hdc && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"mkdir /config/usb_gadget/g1/functions/mass_storage.usb",
|
||||
"write /config/usb_gadget/g1/functions/mass_storage.usb/lun.0/file /dev/block/mmcblk0p11",
|
||||
"symlink /config/usb_gadget/g1/functions/mass_storage.usb /config/usb_gadget/g1/configs/b.1/mass_storage.usb",
|
||||
"start hdcd"
|
||||
]
|
||||
}, {
|
||||
"name" : "param:sys.usb.ffs.ready=1 && param:sys.usb.config=storage_hdc && param:sys.usb.configfs=1",
|
||||
"condition" : "sys.usb.ffs.ready=1 && sys.usb.config=storage_hdc && sys.usb.configfs=1",
|
||||
"cmds" : [
|
||||
"write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration storage_hdc",
|
||||
"symlink /config/usb_gadget/g1/functions/ffs.hdc /config/usb_gadget/g1/configs/b.1/f1",
|
||||
"write /config/usb_gadget/g1/UDC ${sys.usb.controller}",
|
||||
"setparam sys.usb.state ${sys.usb.config}"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
Loading…
Reference in New Issue
Block a user