diff --git a/bundled-exts.json b/bundled-exts.json index 0e0a6be78..3eb1ba899 100644 --- a/bundled-exts.json +++ b/bundled-exts.json @@ -1,4 +1,6 @@ { - "thethorgroup.virtio": "https://raw.githubusercontent.com/RedPill-TTG/redpill-virtio/master/rpext-index.json", - "thethorgroup.boot-wait": "https://raw.githubusercontent.com/RedPill-TTG/redpill-boot-wait/master/rpext-index.json" + "thethorgroup.boot-wait": "https://raw.githubusercontent.com/420Xnu/redpill-boot-wait/master/rpext-index.json", + "pocopico.mpt2sas": "https://raw.githubusercontent.com/pocopico/rp-ext/master/mpt2sas/rpext-index.json", + "pocopico.mpt3sas": "https://raw.githubusercontent.com/pocopico/rp-ext/master/mptsas/rpext-index.json", + "pocopico.mptsas": "https://raw.githubusercontent.com/pocopico/rp-ext/master/mpt2sas/rpext-index.json" } diff --git a/config/DS3615xs/7.0-41222/config.json b/config/DS3615xs/7.0-41222/config.json index 96d7d5b1c..d96eb1e0a 100644 --- a/config/DS3615xs/7.0-41222/config.json +++ b/config/DS3615xs/7.0-41222/config.json @@ -65,6 +65,7 @@ "menu_entries": { "RedPill DS3615xs v7.0-41222 Beta (USB, Verbose)": { "options": [ + "savedefault", "set root=(hd0,msdos1)", "echo Loading Linux...", "linux /zImage @@@CMDLINE@@@", @@ -80,6 +81,7 @@ }, "RedPill DS3615xs v7.0-41222 Beta (SATA, Verbose)": { "options": [ + "savedefault", "set root=(hd0,msdos1)", "echo Loading Linux...", "linux /zImage @@@CMDLINE@@@", diff --git a/config/DS3615xs/7.0.1-42218/config.json b/config/DS3615xs/7.0.1-42218/config.json new file mode 100644 index 000000000..3bf5ff130 --- /dev/null +++ b/config/DS3615xs/7.0.1-42218/config.json @@ -0,0 +1,120 @@ +{ + "os": { + "id": "ds3615xs_42218", + "pat_url": "https://global.download.synology.com/download/DSM/release/7.0.1/42218/DSM_DS3615xs_42218.pat", + "sha256": "dddd26891815ddca02d0d53c1d42e8b39058b398a4cc7b49b80c99f851cf0ef7" + }, + + "files": { + "zlinux": { + "name": "zImage", + "sha256": "d29b695612710376734cb5c5b5ae4f2d8afc49ffd640387e1c86010f6c7d2c8a" + }, + "ramdisk": { + "name": "rd.gz", + "sha256": "4c90c3c7ee25b5fcc651552e80a9364d22823c863c834c5f43e3344a3a68af78" + }, + "vmlinux": { + "sha256": "69569a0703fcd0a3a492dd1066eb6c3b90ea41e5793a5eac960d27b6f3afa916" + } + }, + + "patches": { + "_comment": ".bsp patches are applied to FILES using bspatch(1); .patch are applied to DIRECTORIES using patch(1)", + "zlinux": [ + "zImage-001-3615xs-42218-ramdisk-and-header.bsp" + ], + "ramdisk": [ + "@@@COMMON@@@/ramdisk-001-disable-root-pwd.patch", + "@@@COMMON@@@/v7.0.1/ramdisk-002-init-script.patch", + "@@@COMMON@@@/v7.0.1/ramdisk-003-post-init-script.patch" + ] + }, + "synoinfo": { + "maxdisks": "15", + "internalportcfg": "0x78FF", + "esataportcfg": "0x0", + "usbportcfg": "0x8700", + "rss_server": "http://example.com/null.xml", + "rss_server_ssl": "https://example.com/null.xml", + "small_info_path": "https://example.com/null", + "updateurl": "http://example.com/", + "myds_region_api_base_url": "https://example.com" + }, + "grub": { + "template": "@@@COMMON@@@/grub-template.conf", + "base_cmdline": { + "sn": "", + "vid": "0x46f4", + "pid": "0x0001", + "mac1": "", + "netif_num": 1, + + "syno_hw_version": "DS3615xs", + "syno_hdd_powerup_seq": 0, + "HddHotplug": 0, + "vender_format_version": 2, + "console": "ttyS0,115200n8", + "withefi": null, + "elevator": "elevator", + "syno_port_thaw": 1, + "syno_hdd_detect": 0, + "root": "/dev/md0", + "earlycon": "uart8250,io,0x3f8,115200n8" + }, + "menu_entries": { + "RedPill DS3615xs v7.0.1-42218 (USB, Verbose)": { + "options": [ + "savedefault", + "set root=(hd0,msdos1)", + "echo Loading Linux...", + "linux /zImage @@@CMDLINE@@@", + "echo Loading initramfs...", + "initrd /rd.gz /custom.gz", + "echo Starting kernel with USB boot" + ], + "cmdline": { + "earlyprintk": null, + "loglevel": 15, + "log_buf_len": "32M" + } + }, + "RedPill DS3615xs v7.0.1-42218 (SATA, Verbose)": { + "options": [ + "savedefault", + "set root=(hd0,msdos1)", + "echo Loading Linux...", + "linux /zImage @@@CMDLINE@@@", + "echo Loading initramfs...", + "initrd /rd.gz /custom.gz", + "echo Starting kernel with SATA boot" + ], + "cmdline": { + "earlyprintk": null, + "loglevel": 15, + "synoboot_satadom": 1, + "log_buf_len": "32M" + } + } + } + }, + "extra": { + "compress_rd": false, + "ramdisk_copy": { + "@@@EXT@@@/rp-lkm/redpill-linux-v3.10.108.ko": "usr/lib/modules/rp.ko", + "@@@COMMON@@@/iosched-trampoline.sh": "usr/sbin/modprobe" + }, + "bootp1_copy": { + "@@@PAT@@@/GRUB_VER": "GRUB_VER", + "@@@COMMON@@@/EFI/boot/SynoBootLoader.conf": "EFI/BOOT/", + "@@@COMMON@@@/EFI/boot/SynoBootLoader.efi": "EFI/BOOT/" + }, + "bootp2_copy": { + "@@@PAT@@@/GRUB_VER": "GRUB_VER", + "@@@COMMON@@@/EFI": "EFI", + "@@@PAT@@@/grub_cksum.syno": "grub_cksum.syno", + "@@@PAT@@@/rd.gz": "rd.gz", + "@@@PAT@@@/zImage": "zImage" + } + } +} diff --git a/config/DS3615xs/7.0.1-42218/zImage-001-3615xs-42218-ramdisk-and-header.bsp b/config/DS3615xs/7.0.1-42218/zImage-001-3615xs-42218-ramdisk-and-header.bsp new file mode 100644 index 000000000..edea27292 Binary files /dev/null and b/config/DS3615xs/7.0.1-42218/zImage-001-3615xs-42218-ramdisk-and-header.bsp differ diff --git a/config/DS918+/7.0.1-42218/config.json b/config/DS918+/7.0.1-42218/config.json new file mode 100644 index 000000000..7716eb741 --- /dev/null +++ b/config/DS918+/7.0.1-42218/config.json @@ -0,0 +1,127 @@ +{ + "os": { + "id": "ds918+_42218", + "pat_url": "https://global.download.synology.com/download/DSM/release/7.0.1/42218/DSM_DS918%2B_42218.pat", + "sha256": "4fc59b0f0adfdd96467376f50919dde1bf5dcec74e53452e626f9cf7bd52a38c" + }, + + "files": { + "zlinux": { + "name": "zImage", + "sha256": "0df0fe7b86c269a58933e334cde5056cf5a901f705d6fef5cd750f2981b0ca04" + }, + "ramdisk": { + "name": "rd.gz", + "sha256": "016a99d562b0c06be5f36b4d69a7208ccd2dc816de85c9fb1bba3bf493e1e3ec" + }, + "vmlinux": { + "sha256": "c1ca010542e8c34a675f1e072fcd6e8e9169aa7477790772652f4ece3ead467a" + } + }, + + "patches": { + "zlinux": [ + "zImage-001-918p-42218-ramdisk-and-flag-NOP.bsp" + ], + "ramdisk": [ + "@@@COMMON@@@/ramdisk-001-disable-root-pwd.patch", + "@@@COMMON@@@/v7.0.1/ramdisk-002-init-script.patch", + "@@@COMMON@@@/v7.0.1/ramdisk-003-post-init-script.patch" + ] + }, + + "synoinfo": { + "maxdisks": "16", + "internalportcfg": "0xffff", + "esataportcfg": "0x0", + "HddHotplug": "", + "support_led_brightness_adjustment": "", + "support_leds_lp3943": "", + "buzzeroffen": "0xffff", + "rss_server": "http://example.com/null.xml", + "rss_server_ssl": "https://example.com/null.xml", + "small_info_path": "https://example.com/null", + "updateurl": "http://example.com/", + "myds_region_api_base_url": "https://example.com" + }, + + "grub": { + "template": "@@@COMMON@@@/grub-template.conf", + "base_cmdline": { + "sn": "", + "vid": "0x46f4", + "pid": "0x0001", + "mac1": "", + "netif_num": 1, + + "syno_hw_version": "DS918+", + "syno_hdd_powerup_seq": 1, + "HddHotplug": 0, + "vender_format_version": 2, + "console": "ttyS0,115200n8", + "withefi": null, + "elevator": "elevator", + "syno_port_thaw": 1, + "syno_hdd_detect": 0, + "root": "/dev/md0", + "earlycon": "uart8250,io,0x3f8,115200n8" + }, + + "menu_entries": { + "RedPill DS918+ v7.0.1-42218 (USB, Verbose)": { + "options": [ + "savedefault", + "set root=(hd0,msdos1)", + "echo Loading Linux...", + "linux /zImage @@@CMDLINE@@@", + "echo Loading initramfs...", + "initrd /rd.gz /custom.gz", + "echo Starting kernel with USB boot" + ], + "cmdline": { + "earlyprintk": null, + "loglevel": 15, + "log_buf_len": "32M" + } + }, + "RedPill DS918+ v7.0.1-42218 (SATA, Verbose)": { + "options": [ + "savedefault", + "set root=(hd0,msdos1)", + "echo Loading Linux...", + "linux /zImage @@@CMDLINE@@@", + "echo Loading initramfs...", + "initrd /rd.gz /custom.gz", + "echo Starting kernel with SATA boot", + "echo WARNING: SATA boot support on this platform is experimental!" + ], + "cmdline": { + "earlyprintk": null, + "loglevel": 15, + "synoboot_satadom": 2, + "log_buf_len": "32M" + } + } + } + }, + + "extra": { + "compress_rd": false, + "ramdisk_copy": { + "@@@EXT@@@/rp-lkm/redpill-linux-v4.4.180+.ko": "usr/lib/modules/rp.ko", + "@@@COMMON@@@/iosched-trampoline.sh": "usr/sbin/modprobe" + }, + "bootp1_copy": { + "@@@PAT@@@/GRUB_VER": "GRUB_VER", + "@@@COMMON@@@/EFI": "EFI" + }, + "bootp2_copy": { + "@@@PAT@@@/GRUB_VER": "GRUB_VER", + "@@@COMMON@@@/EFI": "EFI", + "@@@PAT@@@/grub_cksum.syno": "grub_cksum.syno", + "@@@PAT@@@/rd.gz": "rd.gz", + "@@@PAT@@@/zImage": "zImage" + } + } +} + diff --git a/config/DS918+/7.0.1-42218/zImage-001-918p-42218-ramdisk-and-flag-NOP.bsp b/config/DS918+/7.0.1-42218/zImage-001-918p-42218-ramdisk-and-flag-NOP.bsp new file mode 100644 index 000000000..050598491 Binary files /dev/null and b/config/DS918+/7.0.1-42218/zImage-001-918p-42218-ramdisk-and-flag-NOP.bsp differ diff --git a/config/_common/v7.0.1/ramdisk-002-init-script.patch b/config/_common/v7.0.1/ramdisk-002-init-script.patch new file mode 100644 index 000000000..0a7df9d08 --- /dev/null +++ b/config/_common/v7.0.1/ramdisk-002-init-script.patch @@ -0,0 +1,17 @@ +This patch is hand-crafted and fuzzy by design to apply to as many systems as possible. +See https://www.gnu.org/software/diffutils/manual/html_node/Inexact.html for details regarding this process. +This patch CONTENTS should be kept THE SAME for both new and old files structure with the difference of only file which +is patched (linuxrc.syno vs linuxrc.syno.impl) +Syno changed structure of their files somewhere in v7 (for some platforms in v7-RC, for some in v7-mid-cycle) by +renaming some boot scripts from the usual structure. However, the logic of them didn't change. +--- a/linuxrc.syno.impl ++++ b/linuxrc.syno.impl +@@ -155,6 +155,8 @@ fi + # insert basic USB modules for detect f401/FDT + echo "Insert basic USB modules..." + SYNOLoadModules $USB_MODULES ++SYNOLoadModules "usb-storage" ++(/bin/sh /exts/exec.sh load_kmods && /bin/sh /exts/exec.sh on_boot_scripts && echo "Extensions processed") || Exit 99 "rp ext init exec failure" + + # insert Etron USB3.0 drivers + diff --git a/config/_common/v7.0.1/ramdisk-003-post-init-script.patch b/config/_common/v7.0.1/ramdisk-003-post-init-script.patch new file mode 100644 index 000000000..146721ad1 --- /dev/null +++ b/config/_common/v7.0.1/ramdisk-003-post-init-script.patch @@ -0,0 +1,36 @@ +This patch is hand-crafted and fuzzy by design to apply to as many systems as possible. +See https://www.gnu.org/software/diffutils/manual/html_node/Inexact.html for details regarding this process. +This patch CONTENTS should be kept logically the same for both v6 and v7 versions with the only exception of uppercase +functions or quotes in v7, to make diffing and management of these patches easier. +--- a/usr/sbin/init.post ++++ b/usr/sbin/init.post +@@ -18,5 +18,28 @@ if [ "$UniqueRD" = "nextkvmx64" ]; then + fi + Mount "$RootDevice" /tmpRoot -o barrier=1 + ++#################################################################################### ++SED_PATH='/tmpRoot/usr/bin/sed' ++ ++@@@CONFIG-MANIPULATORS-TOOLS@@@ ++ ++@@@CONFIG-GENERATED@@@ ++ ++UPSTART="/tmpRoot/usr/share/init" ++ ++if ! echo; then ++ _replace_in_file '^start on' '#start on' $UPSTART/tty.conf ++ _replace_in_file "console output" "console none" $UPSTART/syno_poweroff_task.conf ++ _replace_in_file "console output" "console none" $UPSTART/burnin_loader.conf ++ _replace_in_file "console output" "console none" $UPSTART/udevtrigger.conf ++ _replace_in_file "console output" "console none" $UPSTART/bs-poweroff.conf ++ _replace_in_file "console output" "console none" $UPSTART/udevd.conf ++else ++ _replace_in_file '^#start on' 'start on' $UPSTART/tty.conf ++fi ++ ++(/bin/sh /exts/exec.sh on_os_load_scripts && echo "OS load extensions processed") || Exit 99 "rp ext post exec failure" ++############################################################################################ ++ + Mkdir -p /tmpRoot/initrd + + Umount /proc >/dev/null 2>&1 diff --git a/ext/virtio-4.4.180+/rng-core.ko b/ext/virtio-4.4.180+/rng-core.ko new file mode 100644 index 000000000..0942c936a Binary files /dev/null and b/ext/virtio-4.4.180+/rng-core.ko differ diff --git a/ext/virtio-4.4.180+/virtio-rng.ko b/ext/virtio-4.4.180+/virtio-rng.ko new file mode 100644 index 000000000..593003890 Binary files /dev/null and b/ext/virtio-4.4.180+/virtio-rng.ko differ diff --git a/user_config.json b/user_config.json new file mode 100644 index 000000000..80a4a9e28 --- /dev/null +++ b/user_config.json @@ -0,0 +1,10 @@ +{ + "extra_cmdline": { + "pid": "", + "vid": "", + "sn": "", + "mac1": "" + }, + "synoinfo": {}, + "ramdisk_copy": {} +}