0003-10_linux-20_linux_xen-detect-udoo-devicetree-file.patch 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. diff -Nur a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
  2. --- a/util/grub.d/10_linux.in 2015-09-27 14:14:45.544730230 -0300
  3. +++ b/util/grub.d/10_linux.in 2015-09-27 18:43:26.911364096 -0300
  4. @@ -139,6 +139,14 @@
  5. initrd ${rel_dirname}/${initrd}
  6. EOF
  7. fi
  8. + if test -d "${rel_dirname}/dtbs/${version}/imx6q-udoo.dtb" ; then
  9. + # TRANSLATORS: Device tree path isn't identifier. Should be translated.
  10. + message="$(gettext_printf "Loading devices tree path ...")"
  11. + sed "s/^/$submenu_indentation/" << EOF
  12. + echo '$(echo "$message" | grub_quote)'
  13. + devicetree ${rel_dirname}/dtbs/${version}/imx6q-udoo.dtb
  14. +EOF
  15. + fi
  16. sed "s/^/$submenu_indentation/" << EOF
  17. }
  18. EOF
  19. @@ -222,6 +230,10 @@
  20. linux_root_device_thisversion=${GRUB_DEVICE}
  21. fi
  22. + if test -d "${dirname}/dtbs/${version}/imx6q-udoo.dtb" ; then
  23. + gettext_printf "Found device tree directory: %s\n" "${dirname}/dtbs/${version}/imx6q-udoo.dtb" >&2
  24. + fi
  25. +
  26. if [ "x$is_top_level" = xtrue ] && [ "x${GRUB_DISABLE_SUBMENU}" != xy ]; then
  27. linux_entry "${OS}" "${version}" simple \
  28. "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}"
  29. diff -Nur a/util/grub.d/20_linux_xen.in b/util/grub.d/20_linux_xen.in
  30. --- a/util/grub.d/20_linux_xen.in 2015-09-27 14:14:45.544730230 -0300
  31. +++ b/util/grub.d/20_linux_xen.in 2015-09-27 18:47:34.953427471 -0300
  32. @@ -132,6 +132,14 @@
  33. module --nounzip ${rel_dirname}/${initrd}
  34. EOF
  35. fi
  36. + if test -d "${rel_dirname}/dtbs/${version}/imx6q-udoo.dtb" ; then
  37. + # TRANSLATORS: Device tree path isn't identifier. Should be translated.
  38. + message="$(gettext_printf "Loading devices tree path ...")"
  39. + sed "s/^/$submenu_indentation/" << EOF
  40. + echo '$(echo "$message" | grub_quote)'
  41. + devicetree ${rel_dirname}/dtbs/${version}/imx6q-udoo.dtb
  42. +EOF
  43. + fi
  44. sed "s/^/$submenu_indentation/" << EOF
  45. }
  46. EOF
  47. @@ -235,6 +243,10 @@
  48. linux_root_device_thisversion=${GRUB_DEVICE}
  49. fi
  50. + if test -d "${dirname}/dtbs/${version}/imx6q-udoo.dtb" ; then
  51. + gettext_printf "Found device tree directory: %s\n" "${dirname}/dtbs/${version}/imx6q-udoo.dtb" >&2
  52. + fi
  53. +
  54. if [ "x$is_top_level" = xtrue ] && [ "x${GRUB_DISABLE_SUBMENU}" != xy ]; then
  55. linux_entry "${OS}" "${version}" "${xen_version}" simple \
  56. "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}" "${GRUB_CMDLINE_XEN} ${GRUB_CMDLINE_XEN_DEFAULT}"