Jump to content

HPET


Pavo
 Share

8 posts in this topic

Recommended Posts

So.... anyone know away to change the _STA method on a device that already has a _STA method in the DSDT without patching the DSDT directly. Was trying to figure it out using a SSDT but getting AE_ALREADY_EXIST error in ACPI.

Original Device:

Device (HPET)
    {
        Name (_HID, EisaId ("PNP0103") /* HPET System Timer */)  // _HID: Hardware ID
        Method (_STA, 0, NotSerialized)  // _STA: Status
        {
            If ((HPEN == One))
            {
                If ((OSVR >= 0x0C))
                {
                    Return (0x0F)
                }

                HPEN = Zero
                Return (One)
            }

            Return (One)
        }

        Method (_CRS, 0, NotSerialized)  // _CRS: Current Resource Settings
        {
            Name (BUF0, ResourceTemplate ()
            {
                IRQNoFlags ()
                    {0}
                IRQNoFlags ()
                    {8}
                Memory32Fixed (ReadOnly,
                    0xFED00000,         // Address Base
                    0x00000400,         // Address Length
                    )
            })
            Return (BUF0) /* \HPET._CRS.BUF0 */
        }
    }

Would like to change it to using SSDT:

Device (HPET)
{
	Name (_HID, EisaId ("PNP0103") /* HPET System Timer */)  // _HID: Hardware ID
    Method (_STA, 0, NotSerialized)  // _STA: Status
    {
		{
			Return (0x0F)
        }
    }

    Method (_CRS, 0, NotSerialized)  // _CRS: Current Resource Settings
    {
		Name (BUF0, ResourceTemplate ()
        {
			IRQNoFlags ()
                {0}
            IRQNoFlags ()
                {8}
            Memory32Fixed (ReadOnly,
                0xFED00000,         // Address Base
                0x00000400,         // Address Length
                )
        })
        Return (BUF0) /* \HPET._CRS.BUF0 */
    }
}

 

  • Like 1
Link to comment
Share on other sites

15 minutes ago, Pavo said:

So.... anyone know away to change the _STA method on a device that already has a _STA method in the DSDT without patching the DSDT directly. Was trying to figure it out using a SSDT but getting AE_ALREADY_EXIST error in ACPI.

Original Device:


Device (HPET)
    {
        Name (_HID, EisaId ("PNP0103") /* HPET System Timer */)  // _HID: Hardware ID
        Method (_STA, 0, NotSerialized)  // _STA: Status
        {
            If ((HPEN == One))
            {
                If ((OSVR >= 0x0C))
                {
                    Return (0x0F)
                }

                HPEN = Zero
                Return (One)
            }

            Return (One)
        }

        Method (_CRS, 0, NotSerialized)  // _CRS: Current Resource Settings
        {
            Name (BUF0, ResourceTemplate ()
            {
                IRQNoFlags ()
                    {0}
                IRQNoFlags ()
                    {8}
                Memory32Fixed (ReadOnly,
                    0xFED00000,         // Address Base
                    0x00000400,         // Address Length
                    )
            })
            Return (BUF0) /* \HPET._CRS.BUF0 */
        }
    }

Would like to change it to using SSDT:


Device (HPET)
{
	Name (_HID, EisaId ("PNP0103") /* HPET System Timer */)  // _HID: Hardware ID
    Method (_STA, 0, NotSerialized)  // _STA: Status
    {
		{
			Return (0x0F)
        }
    }

    Method (_CRS, 0, NotSerialized)  // _CRS: Current Resource Settings
    {
		Name (BUF0, ResourceTemplate ()
        {
			IRQNoFlags ()
                {0}
            IRQNoFlags ()
                {8}
            Memory32Fixed (ReadOnly,
                0xFED00000,         // Address Base
                0x00000400,         // Address Length
                )
        })
        Return (BUF0) /* \HPET._CRS.BUF0 */
    }
}

 

 

Check this stuff.

Link to comment
Share on other sites

if you like HPET with SSDT you have to disable _HID ID via ACPI patches

PNP0103 to PNP010A

Find

504e5030313033

Replace

504e5030313041

Replace

 

Edited by nmano
  • Thanks 1
Link to comment
Share on other sites

24 minutes ago, nmano said:

if you like HPET with SSDT you have to disable _HID address via ACPI patches


PNP0103 to PNP010A

Find

504e5030313033

Replace

504e5030313041

Its not the address that is flagging on, it the _STA method already in the DSDT.

 

1 hour ago, hardcorehenry said:

 

Check this stuff.

Does not work.

  • Like 1
Link to comment
Share on other sites

21 minutes ago, Pavo said:

Its not the address that is flagging on, it the _STA method already in the DSDT.

 

Does not work.

Mine works:

DefinitionBlock ("", "SSDT", 2, "ACDT", "HPET", 0x00000000)
{
    External (_SB_.PCI0.LPCB, DeviceObj)

    Name (\_SB.PCI0.LPCB.HPET._STA, 0x0F)  // _STA: Status
    Name (\_SB.PCI0.LPCB.HPET._CRS, ResourceTemplate ()  // _CRS: Current Resource Settings
    {
        IRQNoFlags ()
            {0,8,11,12}
        Memory32Fixed (ReadWrite,
            0xFED00000,         // Address Base
            0x00000400,         // Address Length
            )
    })
}

Also: _CRS to XCRS, _STA to XSTA (with proper skip value(OpenCore))and IRQ fixes(renames) from script.

 

HPETT.thumb.png.5c692e53d86a1c35641bd693ce91ee42.png

Edited by hardcorehenry
Link to comment
Share on other sites

27 minutes ago, Pavo said:

Its not the address that is flagging on, it the _STA method already in the DSDT.

 

Does not work.

post your DSDT I will check

Link to comment
Share on other sites

28 minutes ago, hardcorehenry said:

Mine works:


DefinitionBlock ("", "SSDT", 2, "ACDT", "HPET", 0x00000000)
{
    External (_SB_.PCI0.LPCB, DeviceObj)

    Name (\_SB.PCI0.LPCB.HPET._STA, 0x0F)  // _STA: Status
    Name (\_SB.PCI0.LPCB.HPET._CRS, ResourceTemplate ()  // _CRS: Current Resource Settings
    {
        IRQNoFlags ()
            {0,8,11,12}
        Memory32Fixed (ReadWrite,
            0xFED00000,         // Address Base
            0x00000400,         // Address Length
            )
    })
}

Also: _CRS to XCRS, _STA to XSTA (with proper skip value(OpenCore))and IRQ fixes(renames) from script.

 

HPETT.thumb.png.5c692e53d86a1c35641bd693ce91ee42.png

Good point, I didn't think about using ACPI patches to change _STA to XSTA.

  • Like 1
Link to comment
Share on other sites

50 minutes ago, Pavo said:

 

Try this

HPET Disable ID

Find

48504554 085F4849 440C41D0 0103

Replace

48504554 085F4849 440C41D0 010A

Edited by nmano
Link to comment
Share on other sites

 Share

×
×
  • Create New...