158a2109fSRaul E Rangel // SPDX-License-Identifier: GPL-2.0 258a2109fSRaul E Rangel // Trace events for the ChromeOS Embedded Controller 358a2109fSRaul E Rangel // 458a2109fSRaul E Rangel // Copyright 2019 Google LLC. 558a2109fSRaul E Rangel 658a2109fSRaul E Rangel #define TRACE_SYMBOL(a) {a, #a} 758a2109fSRaul E Rangel 858a2109fSRaul E Rangel // Generate the list using the following script: 958a2109fSRaul E Rangel // sed -n 's/^#define \(EC_CMD_[[:alnum:]_]*\)\s.*/\tTRACE_SYMBOL(\1), \\/p' include/linux/mfd/cros_ec_commands.h 1058a2109fSRaul E Rangel #define EC_CMDS \ 1158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PROTO_VERSION), \ 1258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HELLO), \ 1358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_VERSION), \ 1458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_READ_TEST), \ 1558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_BUILD_INFO), \ 1658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_CHIP_INFO), \ 1758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_BOARD_VERSION), \ 1858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_READ_MEMMAP), \ 1958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_CMD_VERSIONS), \ 2058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_COMMS_STATUS), \ 2158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_TEST_PROTOCOL), \ 2258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_PROTOCOL_INFO), \ 2358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GSV_PAUSE_IN_S5), \ 2458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_FEATURES), \ 2558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_FLASH_INFO), \ 2658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_FLASH_READ), \ 2758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_FLASH_WRITE), \ 2858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_FLASH_ERASE), \ 2958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_FLASH_PROTECT), \ 3058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_FLASH_REGION_INFO), \ 3158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_VBNV_CONTEXT), \ 3258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PWM_GET_FAN_TARGET_RPM), \ 3358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PWM_SET_FAN_TARGET_RPM), \ 3458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PWM_GET_KEYBOARD_BACKLIGHT), \ 3558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PWM_SET_KEYBOARD_BACKLIGHT), \ 3658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PWM_SET_FAN_DUTY), \ 3758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PWM_SET_DUTY), \ 3858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PWM_GET_DUTY), \ 3958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_LIGHTBAR_CMD), \ 4058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_LED_CONTROL), \ 4158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_VBOOT_HASH), \ 4258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_MOTION_SENSE_CMD), \ 4358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_USB_CHARGE_SET_MODE), \ 4458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PSTORE_INFO), \ 4558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PSTORE_READ), \ 4658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PSTORE_WRITE), \ 4758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_RTC_GET_VALUE), \ 4858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_RTC_GET_ALARM), \ 4958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_RTC_SET_VALUE), \ 5058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_RTC_SET_ALARM), \ 5158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PORT80_LAST_BOOT), \ 5258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PORT80_READ), \ 5358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_THERMAL_SET_THRESHOLD), \ 5458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_THERMAL_GET_THRESHOLD), \ 5558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_THERMAL_AUTO_FAN_CTRL), \ 5658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_TMP006_GET_CALIBRATION), \ 5758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_TMP006_SET_CALIBRATION), \ 5858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_TMP006_GET_RAW), \ 5958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_MKBP_STATE), \ 6058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_MKBP_INFO), \ 6158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_MKBP_SIMULATE_KEY), \ 6258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_MKBP_SET_CONFIG), \ 6358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_MKBP_GET_CONFIG), \ 6458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_KEYSCAN_SEQ_CTRL), \ 6558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_NEXT_EVENT), \ 6658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_TEMP_SENSOR_GET_INFO), \ 6758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_GET_B), \ 6858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_GET_SMI_MASK), \ 6958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_GET_SCI_MASK), \ 7058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_GET_WAKE_MASK), \ 7158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_SET_SMI_MASK), \ 7258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_SET_SCI_MASK), \ 7358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_CLEAR), \ 7458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_SET_WAKE_MASK), \ 7558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_EVENT_CLEAR_B), \ 7658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_SWITCH_ENABLE_BKLIGHT), \ 7758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_SWITCH_ENABLE_WIRELESS), \ 7858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GPIO_SET), \ 7958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GPIO_GET), \ 8058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_I2C_READ), \ 8158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_I2C_WRITE), \ 8258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CHARGE_CONTROL), \ 8358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CONSOLE_SNAPSHOT), \ 8458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CONSOLE_READ), \ 8558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_BATTERY_CUT_OFF), \ 8658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_USB_MUX), \ 8758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_LDO_SET), \ 8858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_LDO_GET), \ 8958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_POWER_INFO), \ 9058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_I2C_PASSTHRU), \ 9158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HANG_DETECT), \ 9258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CHARGE_STATE), \ 9358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CHARGE_CURRENT_LIMIT), \ 9458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_EXTERNAL_POWER_LIMIT), \ 9558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_HOST_SLEEP_EVENT), \ 9658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_SB_READ_WORD), \ 9758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_SB_WRITE_WORD), \ 9858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_SB_READ_BLOCK), \ 9958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_SB_WRITE_BLOCK), \ 10058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_BATTERY_VENDOR_PARAM), \ 10158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CODEC_I2S), \ 10258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_REBOOT_EC), \ 10358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_GET_PANIC_INFO), \ 10458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_ACPI_READ), \ 10558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_ACPI_WRITE), \ 10658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_ACPI_QUERY_EVENT), \ 10758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CEC_WRITE_MSG), \ 10858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CEC_SET), \ 10958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CEC_GET), \ 11058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_REBOOT), \ 11158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_RESEND_RESPONSE), \ 11258a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_VERSION0), \ 11358a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PD_EXCHANGE_STATUS), \ 11458a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_USB_PD_CONTROL), \ 11558a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_USB_PD_PORTS), \ 11658a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_USB_PD_POWER_INFO), \ 11758a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_CHARGE_PORT_COUNT), \ 11858a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_USB_PD_DISCOVERY), \ 11958a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PD_CHARGE_PORT_OVERRIDE), \ 12058a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_PD_GET_LOG_ENTRY), \ 12158a2109fSRaul E Rangel TRACE_SYMBOL(EC_CMD_USB_PD_MUX_INFO) 12258a2109fSRaul E Rangel 12358a2109fSRaul E Rangel #define CREATE_TRACE_POINTS 12458a2109fSRaul E Rangel #include "cros_ec_trace.h" 125