aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2017-06-30 22:59:24 +0200
committerGerd Hoffmann <kraxel@redhat.com>2017-06-30 22:59:24 +0200
commit74d5b98d42db56818b189ede0b6101efb5dc667a (patch)
tree21a0d4191296bd8f75d999e7d56cad4f4b9a8287
parent5a2c4f0a657e0729d25fa1424d25b2572b06930b (diff)
downloadimagefish-74d5b98d42db56818b189ede0b6101efb5dc667a.tar.gz
scripts/config-edid-fixup.sh
-rw-r--r--scripts/config-edid-fixup.sh26
1 files changed, 26 insertions, 0 deletions
diff --git a/scripts/config-edid-fixup.sh b/scripts/config-edid-fixup.sh
new file mode 100644
index 0000000..5bd725c
--- /dev/null
+++ b/scripts/config-edid-fixup.sh
@@ -0,0 +1,26 @@
+#!/bin/sh
+image="$1"
+if test "$image" = ""; then
+ echo "usage: $0 <image>"
+ exit 1
+fi
+
+base="$(dirname $0)"
+edid="ACER-G226HQL-fixed.edid"
+file="${base}/../edid/$edid"
+
+WORK="${TMPDIR-/tmp}/${0##*/}-$$"
+mkdir "$WORK" || exit 1
+trap 'rm -rf "$WORK"' EXIT
+
+cat <<EOF > "$WORK/script"
+
+mkdir /lib/firmware/edid
+copy-in $file /lib/firmware/edid
+
+command "sed -i 's|append|append drm_kms_helper.edid_firmware=edid/$file| /boot/extlinux/extlinux.conf"
+
+EOF
+
+set -ex
+virt-customize -a "$image" --no-network --commands-from-file "$WORK/script"