mirror of
https://review.haiku-os.org/haiku
synced 2025-01-31 10:47:14 +01:00
32a3bddfdf
Using the page attribute table to set the memory type on a per page mapping basis is the more modern and flexible approach to physical memory type handling compared to using MTRRs. Most of the needed infrastructure was already in place, as setting the page table entry attributes was already done for uncachable and write-back memory types. Using the PAT now also allows to set the last remaining memory type of write-combining through the PTE flags. The PAT is configured to have entry 4 mean write-combining and the PAT bit in the PTE is set to point to that. When PAT is supported and not disabled, MTRRs are completely ignored and left as set up by the system firmware, where the basic uncachable and RAM ranges are supposed to be set up. These configurations are then overridden by the PTE flags as needed. Change-Id: I0a74b3fc7d3ba9fa384251290ce41621b69d3a02 Reviewed-on: https://review.haiku-os.org/c/haiku/+/8340 Reviewed-by: waddlesplash <waddlesplash@gmail.com>
26 lines
1002 B
C
26 lines
1002 B
C
/*
|
|
* Copyright 2004-2009, Axel Dörfler, axeld@pinc-software.de.
|
|
* Distributed under the terms of the MIT License.
|
|
*/
|
|
#ifndef _SYSTEM_SAFEMODE_DEFS_H
|
|
#define _SYSTEM_SAFEMODE_DEFS_H
|
|
|
|
|
|
#define B_SAFEMODE_DISABLE_USER_ADD_ONS "disable_user_addons"
|
|
#define B_SAFEMODE_DISABLE_IDE_DMA "disable_ide_dma"
|
|
#define B_SAFEMODE_DISABLE_IOAPIC "disable_ioapic"
|
|
#define B_SAFEMODE_DISABLE_ACPI "disable_acpi"
|
|
#define B_SAFEMODE_DISABLE_APIC "disable_apic"
|
|
#define B_SAFEMODE_DISABLE_X2APIC "disable_x2apic"
|
|
#define B_SAFEMODE_DISABLE_SMEP_SMAP "disable_smep_smap"
|
|
#define B_SAFEMODE_DISABLE_APM "disable_apm"
|
|
#define B_SAFEMODE_DISABLE_SMP "disable_smp"
|
|
#define B_SAFEMODE_DISABLE_PAT "disable_pat"
|
|
#define B_SAFEMODE_DISABLE_HYPER_THREADING "disable_hyperthreading"
|
|
#define B_SAFEMODE_FAIL_SAFE_VIDEO_MODE "fail_safe_video_mode"
|
|
#define B_SAFEMODE_4_GB_MEMORY_LIMIT "4gb_memory_limit"
|
|
#define B_SAFEMODE_256_TB_MEMORY_LIMIT "256tb_memory_limit"
|
|
|
|
|
|
#endif /* _SYSTEM_SAFEMODE_DEFS_H */
|