chrome-ec/include
Vadim Bendebury 0816d829ee cr50: add vendor CCD subcommand to report CCD information
It is important for the OS to be able to find out the state of CCD and
current capabilities settings of the device.

This patch defines a structure to use to report information about CCD
state from Cr50 to the host and adds a CCD vendor subcommand to allow
to retrieve the information from Cr50.

Some structure and variable definitions had to be moved into the .h
file to make it possible to share them between Cr50 and gsctool.

BRANCH=cr50, cr50-mp
BUG=b:72718383
TEST=with the following patch applied verified that CCD info is
     properly reported. Also verified that other CCD subcommands still
     work as advertised.

Change-Id: I4a783e6817ed364b9e64522ebbe968d4a657a84c
Signed-off-by: Vadim Bendebury <vbendeb@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/999825
Reviewed-by: Randall Spangler <rspangler@chromium.org>
(cherry picked from commit c3077e63e5)
Reviewed-on: https://chromium-review.googlesource.com/1015615
2018-04-17 18:44:35 +00:00
..
2id.h rwsig: Add support for rwsig image types 2017-02-17 04:09:37 -08:00
accelgyro.h motion_sense: Add "spoof" mode 2017-01-07 13:29:52 -08:00
acpi.h Move ACPI stuff out of chip/lm4 and into common 2013-12-12 18:21:56 +00:00
adc.h servo_v4: Fix ADC console command 2016-05-26 16:17:26 -07:00
als.h ALS: Disable the ALS task if all the ALS inits fail 2015-10-02 12:55:51 -07:00
ap_hang_detect.h Add AP hang detection 2013-12-17 21:27:53 +00:00
backlight.h gpio: Refactor IRQ handler pointer out of gpio_list 2015-04-10 22:08:25 +00:00
base32.h common: Substitute modified CRC8 with CRC-5-USB 2018-02-01 00:48:00 +00:00
battery.h BD9995X/reef/snappy/pyro: Boot from the shipmode battery 2016-11-18 20:07:47 -08:00
battery_bq27621_g1.h battery: Add support for TI's BQ27621_g1 fuel gauge. 2014-12-31 00:01:00 +00:00
battery_smart.h Basking: Fix cannot power on when resume from battery cutoff. 2017-01-13 05:00:27 -08:00
bluetooth_le.h btle: Timeout of ble_rx now based on chip time 2016-08-12 20:49:45 -07:00
bluetooth_le_ll.h btle: Accepts and maintains connections 2016-08-23 15:36:55 -07:00
board_config.h g: Move chip pre-init to chip_pre_init() 2017-09-07 22:34:12 +00:00
btle_hci2.h include: Add HCI include files from NewBlue 2016-07-22 20:37:17 -07:00
btle_hci_int.h include/btle_hcl_int.h: Fix misspellings in #defines and struct name 2016-11-15 17:41:58 -08:00
button.h button: Check volume up/down status and set recovery mode 2017-01-20 00:05:06 -08:00
byteorder.h Move include/byteorder.h -> builtin/endian.h 2016-04-22 20:40:03 -07:00
capsense.h Samus: Support capsense input as keyboard events. 2014-02-08 04:15:39 +00:00
case_closed_debug.h cr50: Defragment code 2017-09-11 21:34:22 +00:00
ccd_config.h cr50: add vendor CCD subcommand to report CCD information 2018-04-17 18:44:35 +00:00
charge_manager.h Revert "charge_ramp: Adjust minimum ramp current" 2017-01-18 19:18:31 -08:00
charge_ramp.h charge_ramp: Specify port number in board_is_vbus_too_low() 2017-02-02 19:09:52 -08:00
charge_state.h cleanup: Remove charge_state_v1 2017-02-06 14:50:32 -08:00
charge_state_v1.h Move common charge_state time constants to a common header 2014-04-11 15:37:38 +00:00
charge_state_v2.h charger_profile: Add common code for charger profile override 2017-01-02 14:04:12 -08:00
charger.h charge_ramp: Specify port number in board_is_vbus_too_low() 2017-02-02 19:09:52 -08:00
charger_detect.h lucid: add support to detect BC1.2 suppliers 2016-02-26 21:22:07 -08:00
charger_profile_override.h charger_profile: support multiple battery voltage range thresholds 2017-02-10 19:02:55 -08:00
chipset.h chip/npcx/espi: Handle global reset events asserting eSPI_Reset# 2017-02-09 20:48:47 -08:00
clock.h stm32: Add delay after enabling peripheral clock 2015-02-10 10:47:07 +00:00
common.h Reef: Reduce max battery charge voltage for 0.5% margin 2017-01-25 22:12:30 -08:00
compile_time_macros.h NPCX: Refactor GPIO driver for functionality and size 2016-03-02 11:22:51 -08:00
config.h cr50: use run time generated public RMA key definition 2018-04-17 18:44:33 +00:00
config_std_internal_flash.h cleanup: Remove CONFIG_FW_IMAGE_SIZE 2015-09-24 18:07:01 -07:00
console.h g: fix build without CONFIG_RESTRICTED_CONSOLE_COMMANDS 2017-06-30 17:24:56 +00:00
console_channel.inc cr50: Add physical presence state machine 2017-08-04 16:33:09 +00:00
consumer.h consumer: Remove flush operation 2018-02-01 00:48:04 +00:00
crc.h ec: add crc32_ctx..() to take context parameter. 2018-03-01 02:06:18 +00:00
crc8.h crc8: Support crc calculation across non-contiguous data 2016-03-18 22:16:53 -07:00
crypto_api.h g: common: introduce generic crypto API 2017-01-25 22:12:28 -08:00
curve25519.h core/cortex-m0/curve25519: Integrate fast curve25519 implementation 2017-10-24 01:54:09 +00:00
device_state.h cr50: Refactor Rdd state machine 2017-09-07 22:34:07 +00:00
dma.h common: Change interface to dma_test 2015-07-27 22:19:16 +00:00
dptf.h Support DPTF charger current limiting 2014-02-08 00:14:48 +00:00
ec_commands.h pd_log: Make PD logging more generic for general purpose logging 2017-08-04 17:02:08 +00:00
eeprom.h cleanup: eeprom and option comments 2013-10-25 20:12:49 +00:00
espi.h npcx: Add espi driver of npcx5mng for x86-based platform. 2016-08-10 22:16:57 -07:00
event_log.h pd_log: Make PD logging more generic for general purpose logging 2017-08-04 17:02:08 +00:00
extension.h cr50: usb_updater: include return codes into USB response payload 2017-06-30 17:30:42 +00:00
extpower.h Remove obsolete board-specific code 2015-06-10 18:24:05 +00:00
fan.h Samus: Handle fan startup in the EC, not the fan controller 2014-11-06 02:28:22 +00:00
flash.h flash: add flash selection support 2017-08-04 16:59:05 +00:00
gesture.h common: motion: move gesture actions in motion task. 2015-09-18 17:55:32 -07:00
gpio.h g: don't enable interrupts in gpio_set_flags_by_mask 2017-06-30 17:33:33 +00:00
gpio.wrap mec1322: Simplify GPIO lists 2015-05-27 03:58:16 +00:00
gpio_list.h Add check to prevent duplicate PIN assignments 2016-09-09 17:15:25 -07:00
gpio_signal.h mec1322: Simplify GPIO lists 2015-05-27 03:58:16 +00:00
hooks.h Clean up CONFIG_CASE_CLOSED_DEBUG usage 2017-09-07 22:34:40 +00:00
host_command.h ec: Minor cleanup of private host command macros. 2017-01-11 14:46:18 -08:00
hwtimer.h pit: Clean up timer init code 2013-06-26 09:08:23 -07:00
i2c.h i2c: Lock out i2c passthru except for desired ports 2016-12-01 19:59:01 -08:00
i8042_protocol.h More supports for A20 enable/disable 2012-11-04 20:27:57 -08:00
inductive_charging.h cleanup: fix all the header guards 2015-06-18 19:07:00 +00:00
keyboard_8042.h keyboard: Always call keyboard_state_changed 2016-11-17 07:08:25 -08:00
keyboard_8042_sharedlib.h libsharedobjs: Add 8042 scancodes to shared lib. 2015-07-17 03:18:03 +00:00
keyboard_config.h common: Add new recovery mode button combination 2016-11-08 20:30:07 -08:00
keyboard_mkbp.h mkbp: Add support for buttons and switches. 2016-07-19 18:33:36 -07:00
keyboard_protocol.h keyboard: Always call keyboard_state_changed 2016-11-17 07:08:25 -08:00
keyboard_raw.h ectool: Support keyboard factory scanning 2016-04-01 00:21:35 -07:00
keyboard_scan.h common: Add new recovery mode button combination 2016-11-08 20:30:07 -08:00
keyboard_test.h Move keyboard dimension and key constants to keyboard_config.h 2013-03-22 11:24:29 -07:00
lb_common.h common: lightbar: put multiple commands under i2c_lock 2015-09-19 12:27:21 -07:00
led_common.h Fix various misspellings in comments 2016-11-15 17:41:53 -08:00
libsharedobjs.h libsharedobjs: Add libsharedobjs.h. 2015-07-17 03:17:57 +00:00
lid_angle.h Cyan: Added Clamshell/Tablet mode support 2015-08-10 20:42:18 +00:00
lid_switch.h Split lid switch code out of switch.c to its own file 2013-04-02 14:12:57 -07:00
lightbar.h common: lightbar: Add histeresis to prevent flickering 2015-10-23 18:03:12 -07:00
lightbar_msg_list.h Remove PULSE and TEST sequences from lightbar module 2014-10-08 02:50:54 +00:00
lightbar_opcode_list.h lightbar: interpreter additions to encode other patterns 2014-10-15 18:22:37 +00:00
link_defs.h Clean up CONFIG_CASE_CLOSED_DEBUG usage 2017-09-07 22:34:40 +00:00
lpc.h intel_x86: Make common code for LPC S0 <-> S0ix transitions 2017-01-21 10:03:45 -08:00
mag_cal.h common: Add magnetometer online calibration. 2015-10-13 05:28:54 -07:00
mat33.h common: Add magnetometer online calibration. 2015-10-13 05:28:54 -07:00
mat44.h common: Add magnetometer online calibration. 2015-10-13 05:28:54 -07:00
math_util.h common: Add magnetometer online calibration. 2015-10-13 05:28:54 -07:00
memory_commands.h Initial sources import 2/3 2011-12-07 19:10:02 +00:00
mkbp_event.h mkbp_event: Properly queue events during host sleep 2016-11-04 18:31:37 -07:00
module_id.h stm32f446e-eval: add support for stm32f446 2016-08-17 16:19:07 -07:00
motion_lid.h common: Add tablet_mode API 2016-11-08 17:11:28 -08:00
motion_sense.h motion: Add opt3001 as a motion sensor 2017-02-16 18:03:59 -08:00
nvcounter.h Add non-volatile flash counter 2017-06-06 23:40:30 +00:00
nvmem.h cr50: Make sure TPM wipe only clears TPM data. 2017-03-02 17:11:22 +00:00
nvmem_vars.h Add nvmem-backed key=value variable storage 2016-12-21 19:42:37 -08:00
onewire.h Clean up LED and onewire modules 2012-10-25 14:12:11 -07:00
panic.h panic: Provide declarations for chip panic data backup/restore 2017-06-30 17:36:17 +00:00
peci.h Switch temp sensor polling to use hooks instead of task 2012-11-01 12:45:22 -07:00
physical_presence.h pp: add API to show when press is expected 2018-02-01 00:48:16 +00:00
port80.h mec1322: Change the Port 80 task to a timer IRQ. 2015-10-19 18:21:22 -07:00
power.h Apollolake: Enter/exit from S0ix based on host commands from kernel 2016-11-17 16:09:44 -08:00
power_button.h cleanup: Fix signed vs unsigned typing 2016-02-03 21:34:47 -08:00
power_led.h Replace generated CONFIG_TASK_ macros with HAS_TASK_ 2013-04-24 16:32:58 -07:00
printf.h printf: Add sign ('+') flag 2016-07-29 10:51:22 -07:00
producer.h cleanup: fix all the header guards 2015-06-18 19:07:00 +00:00
pwm.h gru: control LEDs by changing frequency 2016-12-05 16:43:18 -08:00
queue.h Queue: Add ability to modify contiguous units inplace 2015-07-15 21:57:36 +00:00
queue_policies.h cleanup: fix all the header guards 2015-06-18 19:07:00 +00:00
rma_auth.h cr50: use single __packed definition 2018-03-01 02:06:14 +00:00
rsa.h common: Split rwsig parts from rsa.h header 2017-06-30 17:24:28 +00:00
rwsig.h common: Split rwsig parts from rsa.h header 2017-06-30 17:24:28 +00:00
sfdp.h common: Fixes the SFDP_BITFIELD() macro. 2016-01-29 02:59:58 +00:00
sha1.h cleanup: fix all the header guards 2015-06-18 19:07:00 +00:00
sha256.h sha256: add support for hmac_sha256, and add test for sha256 2017-06-30 17:35:57 +00:00
shared_mem.h common: introduce malloc/free implementation 2017-01-05 21:13:09 -08:00
smbus.h Fix various misspellings in comments 2016-11-15 17:41:53 -08:00
software_panic.h samus: panic reboot EC if PD MCU crashes 2015-02-18 04:53:59 +00:00
spi.h spi: extend spi master API on STM32 2017-06-30 16:51:53 +00:00
spi_flash.h flash: Add command to get SPI flash chip info 2016-09-23 12:21:51 -07:00
spi_flash_reg.h Celes: Add define to support GD25Q41B for External EC ROM. 2015-09-15 19:17:53 -07:00
spi_nor.h common/spi_nor: Adds RDID and 64KiB erase support 2016-12-07 23:45:29 +00:00
stack_trace.h cleanup: fix all the header guards 2015-06-18 19:07:00 +00:00
switch.h gpio: Refactor IRQ handler pointer out of gpio_list 2015-04-10 22:08:25 +00:00
system.h cr50: Add physical presence state machine 2017-08-04 16:33:09 +00:00
tablet_mode.h common: Add tablet_mode API 2016-11-08 17:11:28 -08:00
task.h stm32f446e-eval: add support for stm32f446 2016-08-17 16:19:07 -07:00
task_filter.h Makefile: Allow different task list for RO and RW 2017-06-30 17:24:38 +00:00
task_id.h Makefile: Allow different task list for RO and RW 2017-06-30 17:24:38 +00:00
temp_sensor.h Include battery fuel gauge temp sensor in temperature sensors 2014-02-08 04:21:26 +00:00
temp_sensor_chip.h cleanup: fix all the header guards 2015-06-18 19:07:00 +00:00
test_util.h host: mock i2c_xfer 2015-09-16 14:49:46 -07:00
thermal.h Show the fan-cooling percentage for each active temp sensor 2015-01-14 03:15:41 +00:00
throttle_ap.h Add more build conditions on x86-only code. 2014-08-10 18:39:24 +00:00
timer.h timer: fix clock() implementation to match TPM2 library expectations 2016-07-21 17:32:28 -07:00
tpm_log.h cr50: log I2C slave 'wedged bus recovery' event 2017-09-07 22:34:05 +00:00
tpm_manufacture.h cr50: provide chip factory mode support 2017-08-04 17:01:42 +00:00
tpm_registers.h cr50: pass essential ccd commands through tpm task context 2018-02-01 00:48:13 +00:00
tpm_vendor_cmds.h cr50: expose spihash PP polling to the host 2018-03-01 02:06:15 +00:00
trng.h Cr50: Ensure that trng.h is self-contained. 2016-12-08 19:49:53 -08:00
u2f.h Add U2F implementation 2017-07-18 17:50:28 +00:00
u2f_impl.h Add U2F implementation 2017-07-18 17:50:28 +00:00
uart.h UART: Remove enable/disable interrupt functions 2016-04-27 10:10:02 -07:00
update_fw.h servo_v4: copypasta usb updater code into common 2016-07-21 13:13:35 -07:00
usb_api.h g: restore DATA PID after USB suspend/resume 2017-09-11 21:34:16 +00:00
usb_bb.h cleanup: fix all the header guards 2015-06-18 19:07:00 +00:00
usb_charge.h bd99955: Improve interrupt / USB charger task wake scheme 2016-06-16 12:27:42 -07:00
usb_console.h g: add CONFIG_USB_CONSOLE_CRC 2018-03-01 02:06:19 +00:00
usb_descriptor.h Add WebUSB descriptor support 2017-10-24 01:52:58 +00:00
usb_hid.h chip/stm32/usb_hid: Separate HID keyboard support 2016-11-16 19:04:47 -08:00
usb_hid_touchpad.h chip/stm32/usb_hid: Add USB HID touchpad driver 2016-11-22 18:36:37 -08:00
usb_i2c.h usb_i2c: Remove usb_i2c_board_enable/disable 2017-12-07 01:00:29 +00:00
usb_mux.h kevin / gru: Notify host of HPD IRQ status 2016-08-10 20:07:32 -07:00
usb_pd.h usb pd:Correct the USB PD SinkWaitCap and PSHardReset timer values 2017-02-01 14:29:23 -08:00
usb_pd_tcpc.h tcpm: Add configuration struct for tcpc i2c params 2015-11-08 17:31:12 -08:00
usb_pd_tcpm.h pdchipinfo: Add option to force renewal 2017-02-14 17:28:16 -08:00
util.h util: add constant-time memcmp 2017-06-30 16:51:23 +00:00
vb21_struct.h rwsig: Add support for rwsig image types 2017-02-17 04:09:37 -08:00
vboot_hash.h vboot_hash: Abort hash calculation on flash write 2015-07-01 03:49:00 +00:00
vec3.h common: Add magnetometer online calibration. 2015-10-13 05:28:54 -07:00
vec4.h common: Add magnetometer online calibration. 2015-10-13 05:28:54 -07:00
version.h sync up with upstream header version structure 2017-06-07 00:40:20 +00:00
virtual_battery.h i2c_passthru: fix virtual battery operation 2016-12-14 06:03:14 -08:00
watchdog.h Include "config.h" in include/watchdog.h. 2017-06-30 16:51:50 +00:00
wireless.h Initial Glower commit 2015-01-20 20:56:43 +00:00