manual set _UID for PNLS device

Signed-off-by: SergeySlice <isakov-sl@bk.ru>
This commit is contained in:
SergeySlice 2020-01-02 09:29:08 +03:00
parent 916b9cf2d2
commit 8e5bfb6a61
4 changed files with 29 additions and 15 deletions

View File

@ -245,6 +245,8 @@
</dict>
<key>#SuspendOverride</key>
<false/>
<key>PNLF_UID</key>
<string>0x0A</string>
<key>Name</key>
<string>DSDT.aml</string>
<key>ReuseFFFF</key>
@ -527,21 +529,21 @@
<key>Replace</key>
<data>SEQgNjQ1MA==</data>
</dict>
<dict>
<key>Comment</key>
<string>Patch 8 apples</string>
<key>Disabled</key>
<true/>
<key>Find</key>
<data>AQAAdSI=</data>
<key>MatchOS</key>
<string>10.13</string>
<key>Name</key>
<string>IOGraphicsFamily</string>
<key>Replace</key>
<data>AQAA6yI=</data>
</dict>
</array>
<dict>
<key>Comment</key>
<string>Patch 8 apples</string>
<key>Disabled</key>
<true/>
<key>Find</key>
<data>AQAAdSI=</data>
<key>MatchOS</key>
<string>10.13</string>
<key>Name</key>
<string>IOGraphicsFamily</string>
<key>Replace</key>
<data>AQAA6yI=</data>
</dict>
</array>
<key>KernelXCPM</key>
<false/>
<key>PanicNoKextDump</key>

View File

@ -1909,7 +1909,14 @@ UINT32 AddPNLF (UINT8 *dsdt, UINT32 len)
return len;
}
//Slice - add custom UID
if (gSettings.PNLF_UID != 0xFF) {
((CHAR8*)pnlf)[39] = gSettings.PNLF_UID;
}
// _UID reworked by Sherlocks. 2018.10.08
//Slice - it can't depends on video DeviceID. It is hardware ID of LCD screen.
#if 0
Status = gBS->LocateHandleBuffer (
ByProtocol,
&gEfiPciIoProtocolGuid,
@ -2024,6 +2031,7 @@ UINT32 AddPNLF (UINT8 *dsdt, UINT32 len)
}
}
}
#endif
i = adr - 2;
len = move_data(i, dsdt, len, sizeof(pnlf));

View File

@ -1173,6 +1173,7 @@ typedef struct {
BOOLEAN SlpWak;
BOOLEAN UseIntelHDMI;
UINT8 AFGLowPowerState;
UINT8 PNLF_UID;
// UINT8 pad83[4];

View File

@ -5582,6 +5582,9 @@ GetUserSettings(
Prop = GetProperty (Dict2, "Rtc8Allowed");
gSettings.Rtc8Allowed = IsPropertyTrue (Prop);
Prop = GetProperty (Dict2, "PNLF_UID");
gSettings.PNLF_UID = (UINT8)GetPropertyInteger (Prop, 0x0A);
Prop = GetProperty (Dict2, "FixMask");
gSettings.FixDsdt = (UINT32)GetPropertyInteger (Prop, gSettings.FixDsdt);