• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/* SPDX-License-Identifier: GPL-2.0-only */
2
3#include <intelblocks/gpio.h>
4
5Method (PGPM, 1, Serialized)
6{
7	For (Local0 = 0, Local0 < 6, Local0++)
8	{
9		\_SB.PCI0.CGPM (Local0, Arg0)
10	}
11}
12
13/*
14 * Method called from _PTS prior to system sleep state entry
15 * Enables dynamic clock gating for all 5 GPIO communities
16 */
17Method (MPTS, 1, Serialized)
18{
19	\_SB.PCI0.LPCB.EC0.PTS (Arg0)
20	PGPM (MISCCFG_GPIO_PM_CONFIG_BITS)
21}
22
23/*
24 * Method called from _WAK prior to system sleep state wakeup
25 * Disables dynamic clock gating for all 5 GPIO communities
26 */
27Method (MWAK, 1, Serialized)
28{
29	PGPM (0)
30	\_SB.PCI0.LPCB.EC0.WAK (Arg0)
31}
32
33/*
34 * S0ix Entry/Exit Notifications
35 * Called from \_SB.PEPD._DSM
36 */
37Method (MS0X, 1, Serialized)
38{
39	If (Arg0 == 1) {
40		/* S0ix Entry */
41		PGPM (MISCCFG_GPIO_PM_CONFIG_BITS)
42	} Else {
43		/* S0ix Exit */
44		PGPM (0)
45	}
46}
47