summaryrefslogtreecommitdiffstats
path: root/package
diff options
context:
space:
mode:
Diffstat (limited to 'package')
-rw-r--r--package/kexec-tools/Makefile1
-rw-r--r--package/kexec-tools/files/kexec.sh5
2 files changed, 6 insertions, 0 deletions
diff --git a/package/kexec-tools/Makefile b/package/kexec-tools/Makefile
index d31aeaa85..6274cb81c 100644
--- a/package/kexec-tools/Makefile
+++ b/package/kexec-tools/Makefile
@@ -48,6 +48,7 @@ define Package/kexec-tools/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kexec $(1)/usr/bin/
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kdump $(1)/usr/bin/
+ $(INSTALL_BIN) ./files/kexec.sh $(1)/usr/bin/kexec.mtd
endef
$(eval $(call BuildPackage,kexec-tools))
diff --git a/package/kexec-tools/files/kexec.sh b/package/kexec-tools/files/kexec.sh
new file mode 100644
index 000000000..8871d8aeb
--- /dev/null
+++ b/package/kexec-tools/files/kexec.sh
@@ -0,0 +1,5 @@
+#!/bin/sh
+. /etc/functions.sh
+cmdline="$(cat /proc/cmdline)"
+kernel="$(find_mtd_part kernel)"
+kexec -l $kernel --command-line=$cmdline