1 /* SPDX-License-Identifier: GPL-2.0+ */
3 * Chromium OS Matrix Keyboard Message Protocol definitions
5 * Copyright (c) 2012 The Chromium OS Authors.
8 #ifndef _CROS_MESSAGE_H
9 #define _CROS_MESSAGE_H
12 * Command interface between EC and AP, for LPC, I2C and SPI interfaces.
14 * This is copied from the Chromium OS Open Source Embedded Controller code.
17 /* The header byte, which follows the preamble */
21 MSG_TRAILER_BYTES = 2,
22 MSG_PROTO_BYTES = MSG_HEADER_BYTES + MSG_TRAILER_BYTES,
24 /* Max length of messages */
25 MSG_BYTES = EC_PROTO2_MAX_PARAM_SIZE + MSG_PROTO_BYTES,