Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 101128
b: refs/heads/master
c: 065cb3d
h: refs/heads/master
v: v3
  • Loading branch information
H. Peter Anvin committed Jul 14, 2008
1 parent b40a287 commit 4c32314
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3bf2e77453a87c22eb57ed4926760ac131c84459
refs/heads/master: 065cb3dfe24978651caedfa54da585388ad15dde
13 changes: 11 additions & 2 deletions trunk/arch/x86/kernel/acpi/sleep.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,16 +60,25 @@ int acpi_save_state_mem(void)
header->video_mode = saved_video_mode;

header->wakeup_jmp_seg = acpi_wakeup_address >> 4;

/*
* Set up the wakeup GDT. We set these up as Big Real Mode,
* that is, with limits set to 4 GB. At least the Lenovo
* Thinkpad X61 is known to need this for the video BIOS
* initialization quirk to work; this is likely to also
* be the case for other laptops or integrated video devices.
*/

/* GDT[0]: GDT self-pointer */
header->wakeup_gdt[0] =
(u64)(sizeof(header->wakeup_gdt) - 1) +
((u64)(acpi_wakeup_address +
((char *)&header->wakeup_gdt - (char *)acpi_realmode))
<< 16);
/* GDT[1]: real-mode-like code segment */
/* GDT[1]: big real mode-like code segment */
header->wakeup_gdt[1] =
GDT_ENTRY(0x809b, acpi_wakeup_address, 0xfffff);
/* GDT[2]: real-mode-like data segment */
/* GDT[2]: big real mode-like data segment */
header->wakeup_gdt[2] =
GDT_ENTRY(0x8093, acpi_wakeup_address, 0xfffff);

Expand Down

0 comments on commit 4c32314

Please sign in to comment.