1 /* SPDX-License-Identifier: GPL-2.0-only */
3 * SCMI Message Protocol driver NXP extension header
8 #ifndef _LINUX_SCMI_NXP_PROTOCOL_H
9 #define _LINUX_SCMI_NXP_PROTOCOL_H
11 #include <linux/bitfield.h>
12 #include <linux/device.h>
13 #include <linux/notifier.h>
14 #include <linux/types.h>
16 enum scmi_nxp_protocol {
17 SCMI_PROTOCOL_IMX_BBM = 0x81,
18 SCMI_PROTOCOL_IMX_MISC = 0x84,
21 struct scmi_imx_bbm_proto_ops {
22 int (*rtc_time_set)(const struct scmi_protocol_handle *ph, u32 id,
24 int (*rtc_time_get)(const struct scmi_protocol_handle *ph, u32 id,
26 int (*rtc_alarm_set)(const struct scmi_protocol_handle *ph, u32 id,
27 bool enable, u64 sec);
28 int (*button_get)(const struct scmi_protocol_handle *ph, u32 *state);
31 enum scmi_nxp_notification_events {
32 SCMI_EVENT_IMX_BBM_RTC = 0x0,
33 SCMI_EVENT_IMX_BBM_BUTTON = 0x1,
34 SCMI_EVENT_IMX_MISC_CONTROL = 0x0,
37 struct scmi_imx_bbm_notif_report {
45 struct scmi_imx_misc_ctrl_notify_report {
51 struct scmi_imx_misc_proto_ops {
52 int (*misc_ctrl_set)(const struct scmi_protocol_handle *ph, u32 id,
54 int (*misc_ctrl_get)(const struct scmi_protocol_handle *ph, u32 id,
56 int (*misc_ctrl_req_notify)(const struct scmi_protocol_handle *ph,
57 u32 ctrl_id, u32 evt_id, u32 flags);