You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
788 B
23 lines
788 B
package main
|
|
|
|
const (
|
|
miscDevice = "/dev/mmcblk0p2"
|
|
bootDevice = "/dev/mmcblk0p3"
|
|
rootfsDevice = "/dev/mmcblk0p6"
|
|
userdataDevice = "/dev/mmcblk0p8"
|
|
bootSizePath = "/sys/class/block/mmcblk0p3/size"
|
|
rootfsSizePath = "/sys/class/block/mmcblk0p6/size"
|
|
)
|
|
|
|
type recoveryPartition struct {
|
|
DevicePath string
|
|
UEventPath string
|
|
Name string
|
|
}
|
|
|
|
var recoveryPartitionContract = []recoveryPartition{
|
|
{DevicePath: miscDevice, UEventPath: "/sys/class/block/mmcblk0p2/uevent", Name: "misc"},
|
|
{DevicePath: bootDevice, UEventPath: "/sys/class/block/mmcblk0p3/uevent", Name: "boot"},
|
|
{DevicePath: rootfsDevice, UEventPath: "/sys/class/block/mmcblk0p6/uevent", Name: "rootfs"},
|
|
{DevicePath: userdataDevice, UEventPath: "/sys/class/block/mmcblk0p8/uevent", Name: "userdata"},
|
|
}
|
|
|