mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 08:43:19 -04:00
MFC r198097
Set the active flag in the PMBR when we install bootcode on a GPT partitioned disk. Some BIOS require this to be set before they will boot the device.
This commit is contained in:
parent
e4692ffe5b
commit
713444a957
1 changed files with 3 additions and 0 deletions
|
|
@ -382,6 +382,9 @@ g_part_gpt_bootcode(struct g_part_table *basetable, struct g_part_parms *gpp)
|
|||
codesz = MIN(codesz, gpp->gpp_codesize);
|
||||
if (codesz > 0)
|
||||
bcopy(gpp->gpp_codeptr, table->mbr, codesz);
|
||||
|
||||
/* Mark the PMBR active since some BIOS require it */
|
||||
table->mbr[DOSPARTOFF] = 0x80; /* status */
|
||||
return (0);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue