// SPDX-License-Identifier: GPL-2.0 /* * SCMI Message Protocol driver header * * Copyright (C) 2018 ARM Ltd. */ #include #define SCMI_MAX_STR_SIZE 16 /** * struct scmi_revision_info - version information structure * * @major_ver: Major ABI version. Change here implies risk of backward * compatibility break. * @minor_ver: Minor ABI version. Change here implies new feature addition, * or compatible change in ABI. * @num_protocols: Number of protocols that are implemented, excluding the * base protocol. * @num_agents: Number of agents in the system. * @impl_ver: A vendor-specific implementation version. * @vendor_id: A vendor identifier(Null terminated ASCII string) * @sub_vendor_id: A sub-vendor identifier(Null terminated ASCII string) */ struct scmi_revision_info { u16 major_ver; u16 minor_ver; u8 num_protocols; u8 num_agents; u32 impl_ver; char vendor_id[SCMI_MAX_STR_SIZE]; char sub_vendor_id[SCMI_MAX_STR_SIZE]; }; /** * struct scmi_handle - Handle returned to ARM SCMI clients for usage. * * @dev: pointer to the SCMI device * @version: pointer to the structure containing SCMI version information */ struct scmi_handle { struct device *dev; struct scmi_revision_info *version; }; enum scmi_std_protocol { SCMI_PROTOCOL_BASE = 0x10, SCMI_PROTOCOL_POWER = 0x11, SCMI_PROTOCOL_SYSTEM = 0x12, SCMI_PROTOCOL_PERF = 0x13, SCMI_PROTOCOL_CLOCK = 0x14, SCMI_PROTOCOL_SENSOR = 0x15, };