// Patch Options / Advanced ToolTips
"TT_DVMTPreAlloc32MB" = "Set DVMT pre-alloc to 32 MB to match BIOS setting (stolen mem = 19 MB / fb mem = 9 MB)";
"TT_VRAM2048MB" = "Set VRAM to 2048 MB. Can fix some 4K display glitching (unified mem = 2048 MB)";
"TT_DisableeGPU" = "Disable external GPU (disable-external-gpu)";
"TT_EnableHDMI20" = "HDMI in UHD resolution with 60 fps (enable-hdmi20)";
"TT_DPtoHDMI" = "Convert Display Port connector types to HDMI";
"TT_GfxYTileFix" = "Since macOS Sierra 10.12 update, Skylake's Intel HD 530 integrated graphics has had certain graphical artifacts or 'glitches' in the upper left corner of the menu bar and elsewhere. This does not occur under OS X El Capitan. (AAPL,GfxYTile)";
"TT_UseIntelHDMI" = "If TRUE, hda-gfx=onboard-1 will be injected into the GFX0 and HDEF devices. Also, if an ATI or Nvidia HDMI device is present, they'll be assigned to onboard-2. If FALSE, then ATI or Nvidia devices will get onboard-1 as well as the HDAU device if present.";
"TT_USBPortLimit" = "Inject USB port limit patches if available";
"TT_HotplugRebootFix" = "Set connector pipe values to 18";
"TT_DPCDMaxLinkRate" = "Fix the invalid maximum link rate issue on some laptops (Dell XPS 15 9570, etc.)";
"TT_HDMIInfiniteLoopFix" = "Fix the infinite loop when the graphics driver tries to establish a HDMI connection with a higher pixel clock rate, for example connecting to a 2K/4K display with HDMI 1.4, otherwise the system just hangs (and your builtin laptop display remains black) when you plug in the HDMI cable.\r\r- For those who want to have \"limited\" 2K/4K experience (i.e. 2K@59Hz or 4K@30Hz) with their HDMI 1.4 port, you might find this fix helpful.\r- For those who have a laptop or PC with HDMI 2.0 routed to IGPU and have HDMI output issues, please note that this fix is now succeeded by the LSPCON driver solution, and it is still recommended to enable the LSPCON driver support to have full HDMI 2.0 experience.\r(You might still need this fix temporarily to figure out the connector index of your HDMI port.)";
"TT_FramebufferPortLimit" = "Set the connector index values to -1 (disable) for connectors above limit";
"TT_SpoofAudioDeviceID" = "Spoof HDEF device-id if available";
"TT_SpoofVideoDeviceID" = "Spoof IGPU device-id";
"TT_InjectDeviceID" = "Spoof IGPU device-id";
"TT_InjectFakeIGPU" = "Inject a fake IGPU device";
// Patch Options / LSPCON ToolTips
"TT_LSPCONEnableDriver" = "Recent laptops (Kaby Lake/Coffee Lake-based) are typically equipped with a HDMI 2.0 port. This port could be either routed to IGPU or DGPU, and you can have a confirmation on Windows 10. Intel (U)HD Graphics, however, does not provide native HDMI 2.0 output, so in order to solve this issue OEMs add an additional hardware named LSPCON on the motherboard to convert DisplayPort into HDMI 2.0.\r\rLSPCON works in either Level Shifter (LS) or Protocol Converter (PCON) mode. When the adapter works in LS mode, it is capable of producing HDMI 1.4 signals from DisplayPort, while in PCON mode, it could provide HDMI 2.0 output. Some onboard LSPCON adapters (e.g. the one on Dell XPS 15 9570) have been configured in the firmware to work in LS mode by default, resulting a black screen on handling HDMI 2.0 connections.\r\rStarting from version 1.3.0, WhateverGreen now provides driver support for the onboard LSPCON by automatically configuring the adapter to run in PCON mode on new HDMI connections, and hence solves the black screen issue on some platforms.\r\r- LSPCON driver is only applicable for laptops and PCs with HDMI 2.0 routed to IGPU.\r- LSPCON driver is necessary for all newer platforms unless the new IGPU starts to provide native HDMI 2.0 output.\r- Supported Intel Platform: Skylake, Kaby Lake, Coffee Lake and later.\rSkylake Case: Intel NUC Skull Canyon; Iris Pro 580 + HDMI 2.0 with Parade PS175 LSPCON.\rCoffee Lake Case: Some laptops, e.g. Dell XPS 15 9570, are equipped with HDMI 2.0 and Parade PS175 LSPCON.\r- If you have confirmed that your HDMI 2.0 is routed to IGPU and is working properly right now, you don't need to enable this driver, because your onboard LSPCON might already be configured in the firmware to work in PCON mode.";
// Framebuffer Flags ToolTips
"TT_FBAvoidFastLinkTraining" = "Discovered in AppleIntelFBController::LinkTraining. Disables the use of FastLinkTraining.\rAccording to joevt with zero SKL link training happens at 450 MHz else at 540 MHz";
"TT_FBFramebufferCommonMemory" = "Sets the logic of minStolenMem calculation, when set fStolenMemorySize is not multiplied\rby fFBMemoryCount, assuming fStolenMemorySize counts all framebuffers at once.";
"TT_FBFramebufferCompression" = "Discovered in AppleIntelFramebufferController::getFeatureControl.\rThis is equivalent to setting FBC=1 in the plist FeatureControl section.";
"TT_FBEnableSliceFeatures" = "Discovered in AppleIntelFramebufferController::getFeatureControl.\rThis is equivalent to setting SliceSDEnable=1, EUSDEnable=1, DynamicSliceSwitch=1 in the plist FeatureControl section.";
"TT_FBDynamicFBCEnable" = "Discovered in AppleIntelFramebufferController::getFeatureControl.\rThis is equivalent to setting DynamicFBCEnable=1 in the plist FeatureControl section.";
"TT_FBUseVideoTurbo" = "This sets fUseVideoTurbo=1 and loads GPU turbo frequency from the specific field.\rDefaults to 14, can be overridden by VideoTurboFreq in the plist FeatureControl section.";
"TT_FBForcePowerAlwaysConnected" = "Discovered in AppleIntelFramebuffer::getDisplayStatus.\rEnforces display power reset even on always connected displays (see connector flags CNConnectorAlwaysConnected).";
"TT_FBDisableHighBitrateMode2" = "According to joevt this enforces High Bitrate mode 1, which limits DP bitrate to 8.64 Gbit/s instead of normal 17.28 Gbit/s (HBR2).\rI do not think this is used on Skylake any longer.";
"TT_FBBoostPixelFrequencyLimit" = "This bit is not used on Broadwell and newer but set when fPortCount > 0, i.e. for all online framebuffers.\rOn Haswell it is used by AppleIntelFramebuffer::GetOnlineInfo and is set only on 0x0D260007 (MacBookPro11,3) and 0x0D26000E, which are top models.\rThis appears to boost pixel frequency limit (aka pixel clock) to 540000000 Hz (from the usual 216000000, 320000000, 360000000, 450000000).";
"TT_FBLimit4KSourceSize" = "Discovered in AppleIntelFramebuffer::ValidateSourceSize.\rLimits source size to 4096x4096.";
"TT_FBAlternatePWMIncrement1" = "Discovered in AppleIntelFramebufferController::start.\rThese bits appear to be entirely equivalent and could be used interchangeably. Result in setting:\r- PCH_LP_PARTITION_LEVEL_DISABLE (1 << 12) bit in SOUTH_DSPCLK_GATE_D (0xc2020)\r- LPT_PWM_GRANULARITY (1 << 5) bit in SOUTH_CHICKEN2 (0xc2004)\rSee Linux driver sources (lpt_init_clock_gating, lpt_enable_backlight).\rSince these bits are setting backlight pulse width modularity, there is no sense in setting them without a built-in display (i.e. on desktop).";
"TT_FBAlternatePWMIncrement2" = "Discovered in AppleIntelFramebufferController::start.\rThese bits appear to be entirely equivalent and could be used interchangeably. Result in setting:\r- PCH_LP_PARTITION_LEVEL_DISABLE (1 << 12) bit in SOUTH_DSPCLK_GATE_D (0xc2020)\r- LPT_PWM_GRANULARITY (1 << 5) bit in SOUTH_CHICKEN2 (0xc2004)\rSee Linux driver sources (lpt_init_clock_gating, lpt_enable_backlight).\rSince these bits are setting backlight pulse width modularity, there is no sense in setting them without a built-in display (i.e. on desktop).";
"TT_FBDisableFeatureIPS" = "Discovered in Broadwell AppleIntelFBController::start / AppleIntelFBController::getFeatureControl.\rThis is equivalent to setting DisableFeatureIPS=1 in the plist FeatureControl section.\rIPS stands for Intermediate Pixel Storage";
"TT_FBUnknownFlag_2000" = "";
"TT_FBAllowConnectorRecover" = "Discovered in Broadwell AppleIntelFBController::getOSInformation.\rUsed by AppleIntelFramebufferController::LinkTraining for camellia version 2.\rCan be overridden by -notconrecover boot-arg, which effectively unsets this bit.";
"TT_FBUnknownFlag_8000" = "";
"TT_FBUnknownFlag_10000" = "";
"TT_FBUnknownFlag_20000" = "";
"TT_FBDisableGFMPPFM" = "Discovered in AppleIntelFramebufferController::getFeatureControl.\rThis takes its effect only if GFMPPFM in the plist FeatureControl section is set to 2, otherwise GFMPPFM is off.";
"TT_FBUnknownFlag_80000" = "";
"TT_FBUnknownFlag_100000" = "";
"TT_FBEnableDynamicCDCLK" = "Discovered in AppleIntelFramebufferController::getFeatureControl.\rThis takes its effect only if SupportDynamicCDClk in the plist FeatureControl section is set to 1, otherwise off.\rAlso requires dc6config to be set to 3 (default).";
"TT_FBUnknownFlag_400000" = "";
"TT_FBSupport5KSourceSize" = "Discovered in AppleIntelFramebuffer::enableController.\rUsed by AppleIntelFramebuffer::ValidateSourceSize.\rSetting this bit increases the maximum source size from 4096x4096 to 5120x5120.\rMost likely this enables 5K support via Intel HD.";
"TT_FBUnknownZeroFlags" = "";
// Connector Info ToolTips
"TT_Index" = "Watch out, this is really messy (see AppleIntelFramebufferController::MapFBToPort).\rI am not fully sure why this exists, and recommend setting index to array index (i.e. the sequential number from 0).\r\rThe only accepted values are 0, 1, 2, 3, and -1 (0xFF). When index is equal to array index the logic is simple:\rPort with index    0    is always considered built-in (of LVDS type) regardless of any other values.\rPorts with indexes 1~3  are checked against type, HDMI will allow the use of digital audio, otherwise DP is assumed.\rPort with index    0xFF is ignored and skipped.\r\rWhen index != array index port type will be read from connector[index].type.\rSay, we have 2 active ports:\r0 - [1]     busID 4 type LVDS\r1 - [2]     busID 5 type DP\r2 - [3]     busID 6 type HDMI\r3 - [-1]    busID 0 type Dummy\rThis will result in 2 framebuffers which types will be shifted:\r0 - busID 4 type DP\r1 - busID 5 type HDMI\rIn fact BusID values are also read as connector[index].busID, but are later mapped back via\rAppleIntelFramebufferController::getGMBusIDfromPort by looking up a connector with the specified index.\rThe lookup will stop as soon as a special marker connector (-1) is found. To illustrate, if we have 2 active ports:\r0 - [1]     busID 4 type LVDS\r1 - [2]     busID 5 type DP\r2 - [-1]    busID 6 type HDMI\r3 - [-1]    busID 0 type Dummy\rThe result will be 2 framebuffers which types and the second busID will be shifted:\r0 - busID 4 type DP\r1 - busID 6 type HDMI\rIt is also used for port-number calculation.\r- LVDS displays (more precisely, displays with CNConnectorAlwaysConnected flag set) get port-number 0.\r- Other displays go through index - port-number mapping: 1 - 5, 2 - 6, 3 - 7, or fallback to 0.";
"TT_BusID" = "Proven by AppleIntelFramebufferController::MapFBToPort, by a call to AppleIntelFramebufferController::getGMBusIDfromPort.\rThis is GMBUS (Graphic Management Bus) ID described in https://01.org/sites/default/files/documentation/intel-gfx-prm-osrc-hsw-display_0.pdf.\rThe use could be found in Intel Linux Graphics Driver source code:\rhttps://github.com/torvalds/linux/blob/6481d5ed076e69db83ca75e751ad492a6fb669a7/drivers/gpu/drm/i915/intel_i2c.c#L43\rhttps://github.com/torvalds/linux/blob/605dc7761d2701f73c17183649de0e3044609817/drivers/gpu/drm/i915/i915_reg.h#L3053\rHowever, it should be noted that Apple identifiers are slightly different from Linux driver.\rIn Linux 0 means disabled, however, for Apple it has some special meaning and is used for internal display.\rOther than that the values are the same:\r- GMBUS_PIN_DPC    (4)  HDMIC\r- GMBUS_PIN_DPB    (5)  SDVO, HDMIB\r- GMBUS_PIN_DPD    (6)  HDMID\r- GMBUS_PIN_VGADDC (2)  VGA until Broadwell inclusive.\rSo basically you could use 4, 5, 6 for arbitrary HDMI or DisplayPort displays.\rSince 5 supports SDVO (https://en.wikipedia.org/wiki/Serial_Digital_Video_Out), it may also be used to support DVI displays.\rStarting with Skylake VGA works via SDVO too (instead of a dedicated GMBUS_PIN_VGADDC id).";
"TT_Pipe" = "Appears to be used for grouping ports just like Piker says, but I cannot find the usage.";
"TT_Type" = "Valid Types:\r- Zero\r- Dummy (Always used as dummy, seems to sometimes work as VGA)\r- LVDS (Just like on AMD LVDS is used for eDP)\r- DigitalDVI (This is not eDP despite a common misbelief)\r- SVID\r- VGA\r- DP\r- HDMI\r- AnalogDVI";
"TT_Flags" = "These are connector flags, they have nothing to do with delays regardless of what Piker says.\rI tried to describe some in ConnectorFlags.";
// Connector Flags ToolTips
"TT_CNAlterAppertureRequirements" = "Lets apperture memory to be not required AppleIntelFramebuffer::isApertureMemoryRequired";
"TT_CNUnknownFlag_2" = "";
"TT_CNUnknownFlag_4" = "";
"TT_CNConnectorAlwaysConnected" = "Normally set for LVDS displays (i.e. built-in displays)";
"TT_CNUnknownFlag_10" = "";
"TT_CNUnknownFlag_20" = "";
"TT_CNDisableBlitTranslationTable" = "Disable blit translation table? AppleIntelFramebufferController::ConfigureBufferTranslation";
"TT_CNUseMiscIoPowerWell" = "Used in AppleIntelFramebufferController::setPowerWellState\rActivates MISC IO power well (SKL_DISP_PW_MISC_IO)";
"TT_CNUsePowerWell2" = "Used in AppleIntelFramebufferController::setPowerWellState\rActivates Power Well 2 usage (SKL_PW_CTL_IDX_PW_2)\rMay help with HDMI audio configuration issues\rREF: https://github.com/acidanthera/bugtracker/issues/1189";
"TT_CNUnknownFlag_200" = "";
"TT_CNUnknownFlag_400" = "";
"TT_CNUnknownFlag_800" = "";
"TT_CNUnknownFlag_1000" = "";
"TT_CNUnknownFlag_2000" = "";
"TT_CNUnknownFlag_4000" = "";
"TT_CNUnknownFlag_8000" = "";
"TT_CNUnknownZeroFlags" = "";
