Blame SOURCES/generate_crashkernel_default.sh
|
Justin Vreeland |
794355 |
#!/bin/bash
|
|
Justin Vreeland |
794355 |
kernelver=$1 && shift
|
|
Justin Vreeland |
794355 |
arch=$1 && shift
|
|
Justin Vreeland |
794355 |
rootfs=$1 && shift
|
|
Justin Vreeland |
794355 |
|
|
Justin Vreeland |
794355 |
output="${rootfs}/lib/modules/${kernelver}/crashkernel.default"
|
|
Justin Vreeland |
794355 |
|
|
Justin Vreeland |
794355 |
case $arch in
|
|
Justin Vreeland |
794355 |
x86_64|s390*)
|
|
Justin Vreeland |
794355 |
ck_cmdline="crashkernel=1G-4G:192M,4G-64G:256M,64G-:512M"
|
|
Justin Vreeland |
794355 |
;;
|
|
Justin Vreeland |
794355 |
arm64|aarch64)
|
|
Justin Vreeland |
794355 |
ck_cmdline="crashkernel=2G-:448M"
|
|
Justin Vreeland |
794355 |
;;
|
|
Justin Vreeland |
794355 |
powerpc|ppc64*)
|
|
Justin Vreeland |
794355 |
ck_cmdline="crashkernel=2G-4G:384M,4G-16G:512M,16G-64G:1G,64G-128G:2G,128G-:4G"
|
|
Justin Vreeland |
794355 |
;;
|
|
Justin Vreeland |
794355 |
*)
|
|
Justin Vreeland |
794355 |
ck_cmdline=""
|
|
Justin Vreeland |
794355 |
;;
|
|
Justin Vreeland |
794355 |
esac
|
|
Justin Vreeland |
794355 |
|
|
Justin Vreeland |
794355 |
cat > "$output" <
|
|
Justin Vreeland |
794355 |
$ck_cmdline
|
|
Justin Vreeland |
794355 |
EOF
|