Lines Matching refs:msg

48 static void report_version(struct scmi_msg *msg)  in report_version()  argument
55 if (msg->in_size != 0U) { in report_version()
56 scmi_status_response(msg, SCMI_PROTOCOL_ERROR); in report_version()
60 scmi_write_response(msg, &return_values, sizeof(return_values)); in report_version()
63 static void report_attributes(struct scmi_msg *msg) in report_attributes() argument
67 .attributes = plat_scmi_rstd_count(msg->agent_id), in report_attributes()
70 if (msg->in_size != 0U) { in report_attributes()
71 scmi_status_response(msg, SCMI_PROTOCOL_ERROR); in report_attributes()
75 scmi_write_response(msg, &return_values, sizeof(return_values)); in report_attributes()
78 static void report_message_attributes(struct scmi_msg *msg) in report_message_attributes() argument
80 struct scmi_protocol_message_attributes_a2p *in_args = (void *)msg->in; in report_message_attributes()
87 if (msg->in_size != sizeof(*in_args)) { in report_message_attributes()
88 scmi_status_response(msg, SCMI_PROTOCOL_ERROR); in report_message_attributes()
93 scmi_status_response(msg, SCMI_NOT_FOUND); in report_message_attributes()
97 scmi_write_response(msg, &return_values, sizeof(return_values)); in report_message_attributes()
100 static void reset_domain_attributes(struct scmi_msg *msg) in reset_domain_attributes() argument
102 struct scmi_reset_domain_attributes_a2p *in_args = (void *)msg->in; in reset_domain_attributes()
107 if (msg->in_size != sizeof(*in_args)) { in reset_domain_attributes()
108 scmi_status_response(msg, SCMI_PROTOCOL_ERROR); in reset_domain_attributes()
114 if (domain_id >= plat_scmi_rstd_count(msg->agent_id)) { in reset_domain_attributes()
115 scmi_status_response(msg, SCMI_INVALID_PARAMETERS); in reset_domain_attributes()
119 name = plat_scmi_rstd_get_name(msg->agent_id, domain_id); in reset_domain_attributes()
121 scmi_status_response(msg, SCMI_NOT_FOUND); in reset_domain_attributes()
131 scmi_write_response(msg, &return_values, sizeof(return_values)); in reset_domain_attributes()
134 static void reset_request(struct scmi_msg *msg) in reset_request() argument
136 struct scmi_reset_domain_request_a2p *in_args = (void *)msg->in; in reset_request()
142 if (msg->in_size != sizeof(*in_args)) { in reset_request()
143 scmi_status_response(msg, SCMI_PROTOCOL_ERROR); in reset_request()
149 if (domain_id >= plat_scmi_rstd_count(msg->agent_id)) { in reset_request()
150 scmi_status_response(msg, SCMI_NOT_FOUND); in reset_request()
155 out_args.status = plat_scmi_rstd_autonomous(msg->agent_id, in reset_request()
159 out_args.status = plat_scmi_rstd_set_state(msg->agent_id, in reset_request()
162 out_args.status = plat_scmi_rstd_set_state(msg->agent_id, in reset_request()
167 scmi_status_response(msg, out_args.status); in reset_request()
169 scmi_write_response(msg, &out_args, sizeof(out_args)); in reset_request()
187 scmi_msg_handler_t scmi_msg_get_rstd_handler(struct scmi_msg *msg) in scmi_msg_get_rstd_handler() argument
189 unsigned int message_id = SPECULATION_SAFE_VALUE(msg->message_id); in scmi_msg_get_rstd_handler()
192 VERBOSE("Reset domain handle not found %u\n", msg->message_id); in scmi_msg_get_rstd_handler()