Skip to contentSkip to conversation

Support BSD loading from unnested partition (e.g. on GPT)

PATCH New Vladimir 'phcoder' Serbinenko 1 participant 1 message Jun 1, 2009

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Support BSD loading from unnested partition (e.g. on GPT)

Hello. Currently if BSD partition is unnested grub2 passes to bsd as if it was booting from 'a' partition. Here is a fix

Signature · 2 lines
Regards
Vladimir 'phcoder' Serbinenko
loader/i386/bsd.c +3 -1
index ab3a635..b329927 100644
@@ -82,7 +82,9 @@ grub_bsd_get_device (grub_uint32_t * biosdev,
 {
   char *p;
 
-  *biosdev = *unit = *slice = *part = 0;
+  *biosdev = *unit = 0;
+  *slice = 0xfe;
+  *part = 0xff;
   p = grub_env_get ("root");
   if ((p) && ((p[0] == 'h') || (p[0] == 'f')) && (p[1] == 'd') &&
       (p[2] >= '0') && (p[2] <= '9'))