Skip to content

Commit

Permalink
Merge pull request #57 from xen0n/provisioner-more-boards
Browse files Browse the repository at this point in the history
feat(provision): add support for four new boards
  • Loading branch information
xen0n authored Jan 28, 2024
2 parents a81240b + 676a37d commit b9cd9d2
Showing 1 changed file with 112 additions and 0 deletions.
112 changes: 112 additions & 0 deletions ruyi/device/provision_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,48 @@ def postinst_oerv_on_milkv_pioneer_nvme_models() -> None:
],
"postinst_fn": postinst_oerv_on_milkv_pioneer_nvme_models,
},
{
"id": "oerv-awol-d1-base",
"display_name": "openEuler RISC-V (base system) for Allwinner D1",
"packages": [
"board-image/oerv-awol-d1-base",
],
},
{
"id": "oerv-awol-d1-xfce",
"display_name": "openEuler RISC-V (XFCE) for Allwinner D1",
"packages": [
"board-image/oerv-awol-d1-xfce",
],
},
{
"id": "oerv-starfive-visionfive-base",
"display_name": "openEuler RISC-V (base system) for StarFive VisionFive",
"packages": [
"board-image/oerv-starfive-visionfive-base",
],
},
{
"id": "oerv-starfive-visionfive-xfce",
"display_name": "openEuler RISC-V (XFCE) for StarFive VisionFive",
"packages": [
"board-image/oerv-starfive-visionfive-xfce",
],
},
{
"id": "oerv-starfive-visionfive2-base",
"display_name": "openEuler RISC-V (base system) for StarFive VisionFive2",
"packages": [
"board-image/oerv-starfive-visionfive2-base",
],
},
{
"id": "oerv-starfive-visionfive2-xfce",
"display_name": "openEuler RISC-V (XFCE) for StarFive VisionFive2",
"packages": [
"board-image/oerv-starfive-visionfive2-xfce",
],
},
{
"id": "oerv-sipeed-lpi4a-8g-headless",
"display_name": "openEuler RISC-V (headless) for Sipeed LicheePi 4A (8G RAM)",
Expand Down Expand Up @@ -228,6 +270,36 @@ class DeviceDecl(TypedDict):
],
}

DEVICE_AWOL_D1DEV: DeviceDecl = {
"id": "awol-d1dev",
"display_name": "Allwinner Nezha D1",
"variants": [
{
"id": "generic",
"display_name": "Allwinner Nezha D1 (generic variant)",
"supported_combos": [
"oerv-awol-d1-base",
"oerv-awol-d1-xfce",
],
},
],
}

DEVICE_SIPEED_LICHEERV: DeviceDecl = {
"id": "sipeed-licheerv",
"display_name": "Sipeed Lichee RV",
"variants": [
{
"id": "generic",
"display_name": "Sipeed Lichee RV (generic variant)",
"supported_combos": [
"oerv-awol-d1-base",
"oerv-awol-d1-xfce",
],
},
],
}

DEVICE_SIPEED_LPI4A: DeviceDecl = {
"id": "sipeed-lpi4a",
"display_name": "Sipeed LicheePi 4A",
Expand All @@ -253,10 +325,44 @@ class DeviceDecl(TypedDict):
],
}

DEVICE_STARFIVE_VISIONFIVE: DeviceDecl = {
"id": "starfive-visionfive",
"display_name": "StarFive VisionFive",
"variants": [
{
"id": "generic",
"display_name": "StarFive VisionFive (generic variant)",
"supported_combos": [
"oerv-starfive-visionfive-base",
"oerv-starfive-visionfive-xfce",
],
},
],
}

DEVICE_STARFIVE_VISIONFIVE2: DeviceDecl = {
"id": "starfive-visionfive2",
"display_name": "StarFive VisionFive2",
"variants": [
{
"id": "generic",
"display_name": "StarFive VisionFive2 (generic variant)",
"supported_combos": [
"oerv-starfive-visionfive2-base",
"oerv-starfive-visionfive2-xfce",
],
},
],
}

DEVICES: list[DeviceDecl] = [
DEVICE_AWOL_D1DEV,
DEVICE_MILKV_DUO,
DEVICE_MILKV_PIONEER,
DEVICE_SIPEED_LICHEERV,
DEVICE_SIPEED_LPI4A,
DEVICE_STARFIVE_VISIONFIVE,
DEVICE_STARFIVE_VISIONFIVE2,
]


Expand Down Expand Up @@ -638,8 +744,14 @@ def flash_fastboot(img_paths: PartitionMapDecl, _: PartitionMapDecl) -> int:
"board-image/buildroot-sdk-milkv-duo256m": STRATEGY_WHOLE_DISK_DD,
"board-image/buildroot-sdk-milkv-duo256m-python": STRATEGY_WHOLE_DISK_DD,
"board-image/buildroot-sdk-milkv-duo-python": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-awol-d1-base": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-awol-d1-xfce": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-sg2042-milkv-pioneer-base": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-sg2042-milkv-pioneer-xfce": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-starfive-visionfive-base": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-starfive-visionfive-xfce": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-starfive-visionfive2-base": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-starfive-visionfive2-xfce": STRATEGY_WHOLE_DISK_DD,
"board-image/oerv-sipeed-lpi4a-headless": STRATEGY_BOOT_ROOT_FASTBOOT,
"board-image/oerv-sipeed-lpi4a-xfce": STRATEGY_BOOT_ROOT_FASTBOOT,
"board-image/revyos-sg2042-milkv-pioneer": STRATEGY_WHOLE_DISK_DD,
Expand Down

0 comments on commit b9cd9d2

Please sign in to comment.