1 /* SPDX-License-Identifier: GPL-2.0-only */
4 #include <cpu/x86/smm.h>
5 #include <device/device.h>
6 #include <drivers/intel/gma/int15.h>
10 #include <southbridge/intel/bd82x6x/pch.h>
12 #include <ec/compal/ene932/ec.h>
14 void mainboard_suspend_resume(void)
16 /* Enable ACPI mode before OS resume */
17 apm_control(APM_CNT_ACPI_ENABLE
);
20 static void mainboard_init(struct device
*dev
)
22 /* Initialize the Embedded Controller */
26 static int parrot_onboard_smbios_data(struct device
*dev
, int *handle
,
27 unsigned long *current
)
30 u8 hardware_version
= parrot_rev();
31 if (hardware_version
< 0x2) { /* DVT vs PVT */
32 len
+= smbios_write_type41(
34 BOARD_TRACKPAD_NAME
, /* name */
35 BOARD_TRACKPAD_IRQ_DVT
, /* instance */
37 BOARD_TRACKPAD_I2C_ADDR
, /* bus */
40 SMBIOS_DEVICE_TYPE_OTHER
); /* device type */
42 len
+= smbios_write_type41(
44 BOARD_TRACKPAD_NAME
, /* name */
45 BOARD_TRACKPAD_IRQ_PVT
, /* instance */
47 BOARD_TRACKPAD_I2C_ADDR
, /* bus */
50 SMBIOS_DEVICE_TYPE_OTHER
); /* device type */
56 static void mainboard_enable(struct device
*dev
)
58 dev
->ops
->init
= mainboard_init
;
59 dev
->ops
->get_smbios_data
= parrot_onboard_smbios_data
;
60 install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_EDP
, GMA_INT15_PANEL_FIT_DEFAULT
, GMA_INT15_BOOT_DISPLAY_DEFAULT
, 0);
63 struct chip_operations mainboard_ops
= {
64 .enable_dev
= mainboard_enable
,