pentoo-livecd: add some silly warnings for people using nvidia on amd cpu

This commit is contained in:
Rick Farina (Zero_Chaos) 2019-02-06 16:00:25 -05:00
parent aaeffe8467
commit 060f89bf21
No known key found for this signature in database
GPG key ID: A5DD1427DD11F94A

View file

@ -57,6 +57,10 @@ start() {
blacklist nouveau
#fix pax flags for hardened
handle_pax
if [ "$(uname -i)" = "AuthenticAMD" ] && ! grep -q 'mem_encrypt=off' /proc/cmdline; then
ewarn "This setup is extremely unlikely to work without adding 'mem_encrypt=off' to the kernel line"
fi
fi
#check for intel gpu
@ -108,6 +112,9 @@ start() {
switch_to_nouveau
fi
else
if [ "$(uname -i)" = "AuthenticAMD" ] && ! grep -q 'mem_encrypt=off' /proc/cmdline; then
ewarn "This setup is extremely unlikely to work without adding 'mem_encrypt=off' to the kernel line"
fi
#first we detect if the nvidia binary driver can actually support the hardware
NV_TARBALL="$(FETCHCOMMAND="false" RESUMECOMMAND="false" FEATURES="-getbinpkg" emerge --color=n -f nvidia-drivers --nodeps 2> /dev/zero | \
grep "run BLAKE2B SHA512 size ;-) ..." | awk '{print $2}')"