Merge pull request #6362 from stangri/master-luci-app-advanced-reboot
luci-app-advanced-reboot: add support for Linksys and Xiaomi devices …
This commit is contained in:
commit
9628bd504c
9 changed files with 69 additions and 6 deletions
|
@ -5,7 +5,7 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_LICENSE:=GPL-3.0-or-later
|
PKG_LICENSE:=GPL-3.0-or-later
|
||||||
PKG_MAINTAINER:=Stan Grishin <stangri@melmac.net>
|
PKG_MAINTAINER:=Stan Grishin <stangri@melmac.net>
|
||||||
PKG_VERSION:=1.0.1-3
|
PKG_VERSION:=1.0.1-8
|
||||||
|
|
||||||
LUCI_TITLE:=Advanced Linksys Reboot Web UI
|
LUCI_TITLE:=Advanced Linksys Reboot Web UI
|
||||||
LUCI_URL:=https://docs.openwrt.melmac.net/luci-app-advanced-reboot/
|
LUCI_URL:=https://docs.openwrt.melmac.net/luci-app-advanced-reboot/
|
||||||
|
|
|
@ -5,6 +5,11 @@
|
||||||
'require uci';
|
'require uci';
|
||||||
'require fs';
|
'require fs';
|
||||||
|
|
||||||
|
var pkg = {
|
||||||
|
get Name() { return 'luci-app-advanced-reboot'; },
|
||||||
|
get URL() { return 'https://docs.openwrt.melmac.net/' + pkg.Name + '/'; }
|
||||||
|
};
|
||||||
|
|
||||||
return view.extend({
|
return view.extend({
|
||||||
translateTable: {
|
translateTable: {
|
||||||
NO_BOARD_NAME : function(args) { return _('Unable to find Device Board Name.')},
|
NO_BOARD_NAME : function(args) { return _('Unable to find Device Board Name.')},
|
||||||
|
@ -213,9 +218,13 @@ return view.extend({
|
||||||
body.appendChild(partitions_table);
|
body.appendChild(partitions_table);
|
||||||
} else {
|
} else {
|
||||||
body.appendChild(E('p', { 'class' : 'alert-message warning'},
|
body.appendChild(E('p', { 'class' : 'alert-message warning'},
|
||||||
device_info.rom_board_name ? _("Warning: Device (%s) is unknown or isn't a dual-partition device!").format(device_info.rom_board_name)
|
device_info.rom_board_name ? _("Warning: Device (%s) is unknown or isn't a dual-firmware device!" + "%s" +
|
||||||
|
"If you are seeing this on an OpenWrt dual-firmware supported device," + "%s" + "please refer to " +
|
||||||
|
"%sHow to add a new device section of the README%s.").format(device_info.rom_board_name, "<br /><br />", "<br />",
|
||||||
|
"<a href=\"" + pkg.URL + "#how-to-add-a-new-device\" target=\"_blank\">", "</a>" )
|
||||||
: _('Warning: Unable to obtain device information!')
|
: _('Warning: Unable to obtain device information!')
|
||||||
));
|
));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
body.appendChild(E('hr'));
|
body.appendChild(E('hr'));
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
/etc/init.d/rpcd reload
|
|
||||||
rm -rf /var/luci-modulecache/; rm -f /var/luci-indexcache;
|
rm -rf /var/luci-modulecache/; rm -f /var/luci-indexcache;
|
||||||
|
[ -x /etc/init.d/rpcd ] && /etc/init.d/rpcd reload
|
||||||
exit 0
|
exit 0
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# Copyright 2017-2020 Stan Grishin (stangri@melmac.net)
|
# Copyright 2017-2020 Stan Grishin (stangri@melmac.ca)
|
||||||
# shellcheck disable=SC2039,SC1091,SC3043,SC3057,SC3060
|
# shellcheck disable=SC2039,SC1091,SC3043,SC3057,SC3060
|
||||||
|
|
||||||
readonly devices_dir="/usr/share/advanced-reboot/devices/"
|
readonly devices_dir="/usr/share/advanced-reboot/devices/"
|
||||||
|
|
|
@ -12,4 +12,3 @@
|
||||||
"bootEnv2Partition1Value": "run nandboot",
|
"bootEnv2Partition1Value": "run nandboot",
|
||||||
"bootEnv2Partition2Value": "run altnandboot"
|
"bootEnv2Partition2Value": "run altnandboot"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,14 @@
|
||||||
|
{
|
||||||
|
"vendorName": "Linksys",
|
||||||
|
"deviceName": "EA8100v2",
|
||||||
|
"boardNames": [ "linksys,ea8100-v2" ],
|
||||||
|
"partition1MTD": "mtd5",
|
||||||
|
"partition2MTD": "mtd7",
|
||||||
|
"labelOffset": 32,
|
||||||
|
"bootEnv1": "boot_part",
|
||||||
|
"bootEnv1Partition1Value": 1,
|
||||||
|
"bootEnv1Partition2Value": 2,
|
||||||
|
"bootEnv2": null,
|
||||||
|
"bootEnv2Partition1Value": null,
|
||||||
|
"bootEnv2Partition2Value": null
|
||||||
|
}
|
|
@ -0,0 +1,14 @@
|
||||||
|
{
|
||||||
|
"vendorName": "Linksys",
|
||||||
|
"deviceName": "WHW01 V1 (Velop)",
|
||||||
|
"boardNames": [ "linksys,whw01" ],
|
||||||
|
"partition1MTD": "mtd9",
|
||||||
|
"partition2MTD": "mtd11",
|
||||||
|
"labelOffset": 192,
|
||||||
|
"bootEnv1": "boot_part",
|
||||||
|
"bootEnv1Partition1Value": 1,
|
||||||
|
"bootEnv1Partition2Value": 2,
|
||||||
|
"bootEnv2": null,
|
||||||
|
"bootEnv2Partition1Value": null,
|
||||||
|
"bootEnv2Partition2Value": null
|
||||||
|
}
|
|
@ -0,0 +1,14 @@
|
||||||
|
{
|
||||||
|
"vendorName": "Xiaomi",
|
||||||
|
"deviceName": "AX3600",
|
||||||
|
"boardNames": [ "xiaomi,ax3600" ],
|
||||||
|
"partition1MTD": "mtd12",
|
||||||
|
"partition2MTD": "mtd13",
|
||||||
|
"labelOffset": 266432,
|
||||||
|
"bootEnv1": "flag_boot_rootfs",
|
||||||
|
"bootEnv1Partition1Value": 0,
|
||||||
|
"bootEnv1Partition2Value": 1,
|
||||||
|
"bootEnv2": "flag_last_success",
|
||||||
|
"bootEnv2Partition1Value": 0,
|
||||||
|
"bootEnv2Partition2Value": 1
|
||||||
|
}
|
|
@ -0,0 +1,14 @@
|
||||||
|
{
|
||||||
|
"vendorName": "Xiaomi",
|
||||||
|
"deviceName": "AX9000",
|
||||||
|
"boardNames": [ "xiaomi,ax9000" ],
|
||||||
|
"partition1MTD": "mtd20",
|
||||||
|
"partition2MTD": "mtd21",
|
||||||
|
"labelOffset": 266432,
|
||||||
|
"bootEnv1": "flag_boot_rootfs",
|
||||||
|
"bootEnv1Partition1Value": 0,
|
||||||
|
"bootEnv1Partition2Value": 1,
|
||||||
|
"bootEnv2": "flag_last_success",
|
||||||
|
"bootEnv2Partition1Value": 0,
|
||||||
|
"bootEnv2Partition2Value": 1
|
||||||
|
}
|
Loading…
Reference in a new issue