--- smage/branches/alx-0_6_0/core/grub/alx/files/10_alx 2011/09/20 16:17:22 3250 +++ smage/branches/alx-0_6_0/core/grub/alx/files/10_alx 2011/09/22 08:38:55 3251 @@ -28,6 +28,19 @@ CLASS="--class gnu-linux --class gnu --class os" +if [ "x${GRUB_CMDLINE_ALX_HWDETECT}" = "x" ]; then + GRUB_CMDLINE_ALX_HWDETECT="splash=verbose,theme=default hardware-auto-detection" +fi + +if [ "x${GRUB_CMDLINE_ALX_RESET}" = "x" ]; then + GRUB_CMDLINE_ALX_RESET="splash=verbose,theme=default alx-reset-settings" +fi + +if [ "x${GRUB_ALX_FB_FALLBACK}" = "x" ]; then + # use vesafb instead of uvesafb, 1024x768-16@60 + GRUB_ALX_FB_FALLBACK="video=vesafb:mtrr:3,ywrap vga=791" +fi + if [ "x${GRUB_DISTRIBUTOR}" = "x" ] ; then OS=ALX else @@ -53,12 +66,21 @@ # check for special hardware if [ -x "`which hwinfo`" ] -then +then + hwinfo="`hwinfo --bios --storage --pci`" + # zotac - if [ "x`hwinfo --bios --storage --pci | grep -i zotac 2> /dev/null || true`" != x ] + if [ "x`echo ${hwinfo} | grep -i zotac 2> /dev/null || true`" != x ] then GRUB_CMDLINE_LINUX="rootdelay=8 ${GRUB_CMDLINE_LINUX}" fi + + # rangee / VIA CLE-266 chipset + if [ "x`echo ${hwinfo} | grep -i CLE266 2> /dev/null || true`" != x ] + then + # use fallback + GRUB_CMDLINE_LINUX="${GRUB_ALX_FB_FALLBACK} ${GRUB_CMDLINE_LINUX}" + fi fi linux_entry () @@ -185,5 +207,11 @@ linux_entry "${OS}" "${version}" false \ "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}" + linux_entry "${OS} - Re-run hardware detection" "${version}" false \ + "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT} ${GRUB_CMDLINE_ALX_HWDETECT}" + + linux_entry "${OS} - Reset *all* local settings" "${version}" false \ + "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT} ${GRUB_CMDLINE_ALX_RESET}" + list=`echo $list | tr ' ' '\n' | grepvx $linux | tr '\n' ' '` done