Esempio n. 1
0
/*
 * In AP S0ix & S3 -> S0 transitions,
 * the chipset_resume hook is called.
 *
 * During S0ix exit, the wake mask for lid open is disabled.
 * All pending events are cleared
 *
 */
void lpc_disable_wake_mask_for_lid_open(void)
{
	if ((chipset_in_state(CHIPSET_STATE_STANDBY | CHIPSET_STATE_ON)) ||
				chipset_in_state(CHIPSET_STATE_ON)) {
		lpc_set_host_event_mask(LPC_HOST_EVENT_WAKE, 0);
		lpc_clear_host_events();
	}
}
Esempio n. 2
0
/*
 * In AP S0ix & S3 -> S0 transitions,
 * the chipset_resume hook is called.
 *
 * During S0ix exit, the wake mask for lid open is disabled.
 * All pending events are cleared
 */
void lpc_disable_wake_mask_for_lid_open(void)
{
	if (chipset_in_state(CHIPSET_STATE_STANDBY | CHIPSET_STATE_ON)) {
		uint32_t mask;

		mask = lpc_get_host_event_mask(LPC_HOST_EVENT_WAKE) &
			~EC_HOST_EVENT_MASK(EC_HOST_EVENT_LID_OPEN);

		lpc_set_host_event_mask(LPC_HOST_EVENT_WAKE, mask);
		lpc_clear_host_events();
	}
}