Lines Matching refs:dev

91  * @dev: mei device
95 static inline int mei_hbm_write_message(struct mei_device *dev,
99 return mei_write_message(dev, hdr, sizeof(*hdr), data, hdr->length);
105 * @dev: the device structure
107 void mei_hbm_idle(struct mei_device *dev)
109 dev->init_clients_timer = 0;
110 dev->hbm_state = MEI_HBM_IDLE;
116 * @dev: the device structure
118 void mei_hbm_reset(struct mei_device *dev)
120 mei_me_cl_rm_all(dev);
122 mei_hbm_idle(dev);
162 * @dev: the device structure
170 static inline int mei_hbm_cl_write(struct mei_device *dev, struct mei_cl *cl,
178 return mei_hbm_write_message(dev, &mei_hdr, buf);
200 * @dev: the device structure
206 struct mei_cl *mei_hbm_cl_find_by_cmd(struct mei_device *dev, void *buf)
211 list_for_each_entry(cl, &dev->file_list, link)
221 * @dev: the device structure
225 int mei_hbm_start_wait(struct mei_device *dev)
229 if (dev->hbm_state > MEI_HBM_STARTING)
232 mutex_unlock(&dev->device_lock);
233 ret = wait_event_timeout(dev->wait_hbm_start,
234 dev->hbm_state != MEI_HBM_STARTING,
235 dev->timeouts.hbm);
236 mutex_lock(&dev->device_lock);
238 if (ret == 0 && (dev->hbm_state <= MEI_HBM_STARTING)) {
239 dev->hbm_state = MEI_HBM_IDLE;
240 dev_err(dev->dev, "waiting for mei start failed\n");
249 * @dev: the device structure
253 int mei_hbm_start_req(struct mei_device *dev)
259 mei_hbm_reset(dev);
269 dev->hbm_state = MEI_HBM_IDLE;
270 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
272 dev_err(dev->dev, "version message write failed: ret = %d\n",
277 dev->hbm_state = MEI_HBM_STARTING;
278 dev->init_clients_timer = dev->timeouts.client_init;
279 mei_schedule_stall_timer(dev);
285 * @dev: the device structure
289 static int mei_hbm_dma_setup_req(struct mei_device *dev)
303 paddr = dev->dr_dscr[i].daddr;
306 req.dma_dscr[i].size = dev->dr_dscr[i].size;
309 mei_dma_ring_reset(dev);
311 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
313 dev_err(dev->dev, "dma setup request write failed: ret = %d.\n",
318 dev->hbm_state = MEI_HBM_DR_SETUP;
319 dev->init_clients_timer = dev->timeouts.client_init;
320 mei_schedule_stall_timer(dev);
327 * @dev: the device structure
331 static int mei_hbm_capabilities_req(struct mei_device *dev)
341 if (dev->hbm_f_vt_supported)
344 if (dev->hbm_f_cd_supported)
347 if (dev->hbm_f_gsc_supported)
350 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
352 dev_err(dev->dev,
357 dev->hbm_state = MEI_HBM_CAP_SETUP;
358 dev->init_clients_timer = dev->timeouts.client_init;
359 mei_schedule_stall_timer(dev);
366 * @dev: the device structure
370 static int mei_hbm_enum_clients_req(struct mei_device *dev)
381 req.flags |= dev->hbm_f_dc_supported ? MEI_HBM_ENUM_F_ALLOW_ADD : 0;
382 req.flags |= dev->hbm_f_ie_supported ?
385 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
387 dev_err(dev->dev, "enumeration request write failed: ret = %d.\n",
391 dev->hbm_state = MEI_HBM_ENUM_CLIENTS;
392 dev->init_clients_timer = dev->timeouts.client_init;
393 mei_schedule_stall_timer(dev);
400 * @dev: the device structure
406 static int mei_hbm_me_cl_add(struct mei_device *dev,
412 mei_me_cl_rm_by_uuid(dev, uuid);
424 mei_me_cl_add(dev, me_cl);
432 * @dev: the device structure
438 static int mei_hbm_add_cl_resp(struct mei_device *dev, u8 addr, u8 status)
444 dev_dbg(dev->dev, "adding client response\n");
453 ret = mei_hbm_write_message(dev, &mei_hdr, &resp);
455 dev_err(dev->dev, "add client response write failed: ret = %d\n",
463 * @dev: the device structure
468 static int mei_hbm_fw_add_cl_req(struct mei_device *dev,
477 ret = mei_hbm_me_cl_add(dev, (struct hbm_props_response *)req);
481 if (dev->dev_state == MEI_DEV_ENABLED)
482 schedule_work(&dev->bus_rescan_work);
484 return mei_hbm_add_cl_resp(dev, req->me_addr, status);
490 * @dev: the device structure
496 int mei_hbm_cl_notify_req(struct mei_device *dev,
509 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
511 dev_err(dev->dev, "notify request failed: ret = %d\n", ret);
536 * @dev: the device structure
540 static void mei_hbm_cl_notify_start_res(struct mei_device *dev,
547 cl_dbg(dev, cl, "hbm: notify start response status=%d\n", rs->status);
562 * @dev: the device structure
566 static void mei_hbm_cl_notify_stop_res(struct mei_device *dev,
573 cl_dbg(dev, cl, "hbm: notify stop response status=%d\n", rs->status);
588 * @dev: the device structure
591 static void mei_hbm_cl_notify(struct mei_device *dev,
596 cl = mei_hbm_cl_find_by_cmd(dev, cmd);
604 * @dev: the device structure
609 int mei_hbm_cl_dma_map_req(struct mei_device *dev, struct mei_cl *cl)
625 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
627 dev_err(dev->dev, "dma map request failed: ret = %d\n", ret);
635 * @dev: the device structure
640 int mei_hbm_cl_dma_unmap_req(struct mei_device *dev, struct mei_cl *cl)
653 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
655 dev_err(dev->dev, "dma unmap request failed: ret = %d\n", ret);
660 static void mei_hbm_cl_dma_map_res(struct mei_device *dev,
667 list_for_each_entry_safe(cb, next, &dev->ctrl_rd_list, list) {
680 dev_err(dev->dev, "cl dma map failed %d\n", res->status);
683 dev_dbg(dev->dev, "cl dma map succeeded\n");
690 static void mei_hbm_cl_dma_unmap_res(struct mei_device *dev,
697 list_for_each_entry_safe(cb, next, &dev->ctrl_rd_list, list) {
710 dev_err(dev->dev, "cl dma unmap failed %d\n", res->status);
713 dev_dbg(dev->dev, "cl dma unmap succeeded\n");
723 * @dev: the device structure
728 static int mei_hbm_prop_req(struct mei_device *dev, unsigned long start_idx)
735 addr = find_next_bit(dev->me_clients_map, MEI_CLIENTS_MAX, start_idx);
739 dev->hbm_state = MEI_HBM_STARTED;
740 mei_host_client_init(dev);
751 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
753 dev_err(dev->dev, "properties request write failed: ret = %d\n",
758 dev->init_clients_timer = dev->timeouts.client_init;
759 mei_schedule_stall_timer(dev);
767 * @dev: the device structure
773 int mei_hbm_pg(struct mei_device *dev, u8 pg_cmd)
779 if (!dev->hbm_f_pg_supported)
787 ret = mei_hbm_write_message(dev, &mei_hdr, &req);
789 dev_err(dev->dev, "power gate command write failed.\n");
797 * @dev: mei device
801 static int mei_hbm_stop_req(struct mei_device *dev)
812 return mei_hbm_write_message(dev, &mei_hdr, &req);
818 * @dev: the device structure
823 int mei_hbm_cl_flow_control_req(struct mei_device *dev, struct mei_cl *cl)
827 cl_dbg(dev, cl, "sending flow control\n");
828 return mei_hbm_cl_write(dev, cl, MEI_FLOW_CONTROL_CMD,
835 * @dev: the device structure
840 static int mei_hbm_add_single_tx_flow_ctrl_creds(struct mei_device *dev,
846 me_cl = mei_me_cl_by_id(dev, fctrl->me_addr);
848 dev_err(dev->dev, "no such me client %d\n", fctrl->me_addr);
858 dev_dbg(dev->dev, "recv flow ctrl msg ME %d (single) creds = %d.\n",
870 * @dev: the device structure
873 static void mei_hbm_cl_tx_flow_ctrl_creds_res(struct mei_device *dev,
880 mei_hbm_add_single_tx_flow_ctrl_creds(dev, fctrl);
884 cl = mei_hbm_cl_find_by_cmd(dev, fctrl);
887 cl_dbg(dev, cl, "flow control creds = %d.\n",
896 * @dev: the device structure
901 int mei_hbm_cl_disconnect_req(struct mei_device *dev, struct mei_cl *cl)
905 return mei_hbm_cl_write(dev, cl, CLIENT_DISCONNECT_REQ_CMD,
912 * @dev: the device structure
917 int mei_hbm_cl_disconnect_rsp(struct mei_device *dev, struct mei_cl *cl)
921 return mei_hbm_cl_write(dev, cl, CLIENT_DISCONNECT_RES_CMD,
929 * @dev: the device structure
933 static void mei_hbm_cl_disconnect_res(struct mei_device *dev, struct mei_cl *cl,
939 cl_dbg(dev, cl, "hbm: disconnect response status=%d\n", rs->status);
949 * @dev: the device structure
954 int mei_hbm_cl_connect_req(struct mei_device *dev, struct mei_cl *cl)
958 return mei_hbm_cl_write(dev, cl, CLIENT_CONNECT_REQ_CMD,
966 * @dev: the device structure
970 static void mei_hbm_cl_connect_res(struct mei_device *dev, struct mei_cl *cl,
976 cl_dbg(dev, cl, "hbm: connect response status=%s\n",
984 mei_me_cl_del(dev, cl->me_cl);
985 if (dev->dev_state == MEI_DEV_ENABLED)
986 schedule_work(&dev->bus_rescan_work);
996 * @dev: the device structure
1000 static void mei_hbm_cl_res(struct mei_device *dev,
1008 list_for_each_entry_safe(cb, next, &dev->ctrl_rd_list, list) {
1026 mei_hbm_cl_connect_res(dev, cl, rs);
1029 mei_hbm_cl_disconnect_res(dev, cl, rs);
1032 mei_hbm_cl_notify_start_res(dev, cl, rs);
1035 mei_hbm_cl_notify_stop_res(dev, cl, rs);
1050 * @dev: the device structure.
1055 static int mei_hbm_fw_disconnect_req(struct mei_device *dev,
1061 cl = mei_hbm_cl_find_by_cmd(dev, disconnect_req);
1063 cl_warn(dev, cl, "fw disconnect request received\n");
1078 * @dev: the device structure.
1082 static int mei_hbm_pg_enter_res(struct mei_device *dev)
1084 if (mei_pg_state(dev) != MEI_PG_OFF ||
1085 dev->pg_event != MEI_PG_EVENT_WAIT) {
1086 dev_err(dev->dev, "hbm: pg entry response: state mismatch [%s, %d]\n",
1087 mei_pg_state_str(mei_pg_state(dev)), dev->pg_event);
1091 dev->pg_event = MEI_PG_EVENT_RECEIVED;
1092 wake_up(&dev->wait_pg);
1100 * @dev: the device structure.
1102 void mei_hbm_pg_resume(struct mei_device *dev)
1104 pm_request_resume(dev->dev);
1111 * @dev: the device structure.
1115 static int mei_hbm_pg_exit_res(struct mei_device *dev)
1117 if (mei_pg_state(dev) != MEI_PG_ON ||
1118 (dev->pg_event != MEI_PG_EVENT_WAIT &&
1119 dev->pg_event != MEI_PG_EVENT_IDLE)) {
1120 dev_err(dev->dev, "hbm: pg exit response: state mismatch [%s, %d]\n",
1121 mei_pg_state_str(mei_pg_state(dev)), dev->pg_event);
1125 switch (dev->pg_event) {
1127 dev->pg_event = MEI_PG_EVENT_RECEIVED;
1128 wake_up(&dev->wait_pg);
1136 dev->pg_event = MEI_PG_EVENT_RECEIVED;
1137 mei_hbm_pg_resume(dev);
1141 dev->pg_event);
1152 * @dev: the device structure
1154 static void mei_hbm_config_features(struct mei_device *dev)
1157 dev->hbm_f_pg_supported = 0;
1158 if (dev->version.major_version > HBM_MAJOR_VERSION_PGI)
1159 dev->hbm_f_pg_supported = 1;
1161 if (dev->version.major_version == HBM_MAJOR_VERSION_PGI &&
1162 dev->version.minor_version >= HBM_MINOR_VERSION_PGI)
1163 dev->hbm_f_pg_supported = 1;
1165 dev->hbm_f_dc_supported = 0;
1166 if (dev->version.major_version >= HBM_MAJOR_VERSION_DC)
1167 dev->hbm_f_dc_supported = 1;
1169 dev->hbm_f_ie_supported = 0;
1170 if (dev->version.major_version >= HBM_MAJOR_VERSION_IE)
1171 dev->hbm_f_ie_supported = 1;
1174 dev->hbm_f_dot_supported = 0;
1175 if (dev->version.major_version >= HBM_MAJOR_VERSION_DOT)
1176 dev->hbm_f_dot_supported = 1;
1179 dev->hbm_f_ev_supported = 0;
1180 if (dev->version.major_version >= HBM_MAJOR_VERSION_EV)
1181 dev->hbm_f_ev_supported = 1;
1184 dev->hbm_f_fa_supported = 0;
1185 if (dev->version.major_version >= HBM_MAJOR_VERSION_FA)
1186 dev->hbm_f_fa_supported = 1;
1189 dev->hbm_f_os_supported = 0;
1190 if (dev->version.major_version >= HBM_MAJOR_VERSION_OS)
1191 dev->hbm_f_os_supported = 1;
1194 dev->hbm_f_dr_supported = 0;
1195 if (dev->version.major_version > HBM_MAJOR_VERSION_DR ||
1196 (dev->version.major_version == HBM_MAJOR_VERSION_DR &&
1197 dev->version.minor_version >= HBM_MINOR_VERSION_DR))
1198 dev->hbm_f_dr_supported = 1;
1201 dev->hbm_f_vt_supported = 0;
1202 if (dev->version.major_version > HBM_MAJOR_VERSION_VT ||
1203 (dev->version.major_version == HBM_MAJOR_VERSION_VT &&
1204 dev->version.minor_version >= HBM_MINOR_VERSION_VT))
1205 dev->hbm_f_vt_supported = 1;
1208 if (dev->version.major_version > HBM_MAJOR_VERSION_GSC ||
1209 (dev->version.major_version == HBM_MAJOR_VERSION_GSC &&
1210 dev->version.minor_version >= HBM_MINOR_VERSION_GSC))
1211 dev->hbm_f_gsc_supported = 1;
1214 dev->hbm_f_cap_supported = 0;
1215 if (dev->version.major_version > HBM_MAJOR_VERSION_CAP ||
1216 (dev->version.major_version == HBM_MAJOR_VERSION_CAP &&
1217 dev->version.minor_version >= HBM_MINOR_VERSION_CAP))
1218 dev->hbm_f_cap_supported = 1;
1221 dev->hbm_f_cd_supported = 0;
1222 if (dev->version.major_version > HBM_MAJOR_VERSION_CD ||
1223 (dev->version.major_version == HBM_MAJOR_VERSION_CD &&
1224 dev->version.minor_version >= HBM_MINOR_VERSION_CD))
1225 dev->hbm_f_cd_supported = 1;
1232 * @dev: the device structure
1235 bool mei_hbm_version_is_supported(struct mei_device *dev)
1237 return (dev->version.major_version < HBM_MAJOR_VERSION) ||
1238 (dev->version.major_version == HBM_MAJOR_VERSION &&
1239 dev->version.minor_version <= HBM_MINOR_VERSION);
1246 * @dev: the device structure
1251 int mei_hbm_dispatch(struct mei_device *dev, struct mei_msg_hdr *hdr)
1268 BUG_ON(hdr->length >= sizeof(dev->rd_msg_buf));
1269 mei_read_slots(dev, dev->rd_msg_buf, hdr->length);
1270 mei_msg = (struct mei_bus_message *)dev->rd_msg_buf;
1276 if (dev->hbm_state == MEI_HBM_IDLE) {
1277 dev_dbg(dev->dev, "hbm: state is idle ignore spurious messages\n");
1283 dev_dbg(dev->dev, "hbm: start: response message received.\n");
1285 dev->init_clients_timer = 0;
1289 dev_dbg(dev->dev, "HBM VERSION: DRIVER=%02d:%02d DEVICE=%02d:%02d\n",
1295 dev->version.major_version = HBM_MAJOR_VERSION;
1296 dev->version.minor_version = HBM_MINOR_VERSION;
1298 dev->version.major_version =
1300 dev->version.minor_version =
1304 if (!mei_hbm_version_is_supported(dev)) {
1305 dev_warn(dev->dev, "hbm: start: version mismatch - stopping the driver.\n");
1307 dev->hbm_state = MEI_HBM_STOPPED;
1308 if (mei_hbm_stop_req(dev)) {
1309 dev_err(dev->dev, "hbm: start: failed to send stop request\n");
1315 mei_hbm_config_features(dev);
1317 if (dev->dev_state != MEI_DEV_INIT_CLIENTS ||
1318 dev->hbm_state != MEI_HBM_STARTING) {
1319 if (dev->dev_state == MEI_DEV_POWER_DOWN ||
1320 dev->dev_state == MEI_DEV_POWERING_DOWN) {
1321 dev_dbg(dev->dev, "hbm: start: on shutdown, ignoring\n");
1324 dev_err(dev->dev, "hbm: start: state mismatch, [%d, %d]\n",
1325 dev->dev_state, dev->hbm_state);
1329 if (dev->hbm_f_cap_supported) {
1330 if (mei_hbm_capabilities_req(dev))
1332 wake_up(&dev->wait_hbm_start);
1336 if (dev->hbm_f_dr_supported) {
1337 if (mei_dmam_ring_alloc(dev))
1338 dev_info(dev->dev, "running w/o dma ring\n");
1339 if (mei_dma_ring_is_allocated(dev)) {
1340 if (mei_hbm_dma_setup_req(dev))
1343 wake_up(&dev->wait_hbm_start);
1348 dev->hbm_f_dr_supported = 0;
1349 mei_dmam_ring_free(dev);
1351 if (mei_hbm_enum_clients_req(dev))
1354 wake_up(&dev->wait_hbm_start);
1358 dev_dbg(dev->dev, "hbm: capabilities response: message received.\n");
1360 dev->init_clients_timer = 0;
1362 if (dev->dev_state != MEI_DEV_INIT_CLIENTS ||
1363 dev->hbm_state != MEI_HBM_CAP_SETUP) {
1364 if (dev->dev_state == MEI_DEV_POWER_DOWN ||
1365 dev->dev_state == MEI_DEV_POWERING_DOWN) {
1366 dev_dbg(dev->dev, "hbm: capabilities response: on shutdown, ignoring\n");
1369 dev_err(dev->dev, "hbm: capabilities response: state mismatch, [%d, %d]\n",
1370 dev->dev_state, dev->hbm_state);
1376 dev->hbm_f_vt_supported = 0;
1378 dev->hbm_f_cd_supported = 0;
1381 dev->hbm_f_gsc_supported = 0;
1383 if (dev->hbm_f_dr_supported) {
1384 if (mei_dmam_ring_alloc(dev))
1385 dev_info(dev->dev, "running w/o dma ring\n");
1386 if (mei_dma_ring_is_allocated(dev)) {
1387 if (mei_hbm_dma_setup_req(dev))
1393 dev->hbm_f_dr_supported = 0;
1394 mei_dmam_ring_free(dev);
1396 if (mei_hbm_enum_clients_req(dev))
1401 dev_dbg(dev->dev, "hbm: dma setup response: message received.\n");
1403 dev->init_clients_timer = 0;
1405 if (dev->dev_state != MEI_DEV_INIT_CLIENTS ||
1406 dev->hbm_state != MEI_HBM_DR_SETUP) {
1407 if (dev->dev_state == MEI_DEV_POWER_DOWN ||
1408 dev->dev_state == MEI_DEV_POWERING_DOWN) {
1409 dev_dbg(dev->dev, "hbm: dma setup response: on shutdown, ignoring\n");
1412 dev_err(dev->dev, "hbm: dma setup response: state mismatch, [%d, %d]\n",
1413 dev->dev_state, dev->hbm_state);
1423 dev_dbg(dev->dev, "hbm: dma setup not allowed\n");
1425 dev_info(dev->dev, "hbm: dma setup response: failure = %d %s\n",
1429 dev->hbm_f_dr_supported = 0;
1430 mei_dmam_ring_free(dev);
1433 if (mei_hbm_enum_clients_req(dev))
1438 dev_dbg(dev->dev, "hbm: client connect response: message received.\n");
1439 mei_hbm_cl_res(dev, cl_cmd, MEI_FOP_CONNECT);
1443 dev_dbg(dev->dev, "hbm: client disconnect response: message received.\n");
1444 mei_hbm_cl_res(dev, cl_cmd, MEI_FOP_DISCONNECT);
1448 dev_dbg(dev->dev, "hbm: client flow control response: message received.\n");
1451 mei_hbm_cl_tx_flow_ctrl_creds_res(dev, fctrl);
1455 dev_dbg(dev->dev, "hbm: power gate isolation entry response received\n");
1456 ret = mei_hbm_pg_enter_res(dev);
1462 dev_dbg(dev->dev, "hbm: power gate isolation exit request received\n");
1463 ret = mei_hbm_pg_exit_res(dev);
1469 dev_dbg(dev->dev, "hbm: properties response: message received.\n");
1471 dev->init_clients_timer = 0;
1473 if (dev->dev_state != MEI_DEV_INIT_CLIENTS ||
1474 dev->hbm_state != MEI_HBM_CLIENT_PROPERTIES) {
1475 if (dev->dev_state == MEI_DEV_POWER_DOWN ||
1476 dev->dev_state == MEI_DEV_POWERING_DOWN) {
1477 dev_dbg(dev->dev, "hbm: properties response: on shutdown, ignoring\n");
1480 dev_err(dev->dev, "hbm: properties response: state mismatch, [%d, %d]\n",
1481 dev->dev_state, dev->hbm_state);
1488 dev_dbg(dev->dev, "hbm: properties response: %d CLIENT_NOT_FOUND\n",
1491 dev_err(dev->dev, "hbm: properties response: wrong status = %d %s\n",
1496 mei_hbm_me_cl_add(dev, props_res);
1500 if (mei_hbm_prop_req(dev, props_res->me_addr + 1))
1506 dev_dbg(dev->dev, "hbm: enumeration response: message received\n");
1508 dev->init_clients_timer = 0;
1511 BUILD_BUG_ON(sizeof(dev->me_clients_map)
1513 memcpy(dev->me_clients_map, enum_res->valid_addresses,
1516 if (dev->dev_state != MEI_DEV_INIT_CLIENTS ||
1517 dev->hbm_state != MEI_HBM_ENUM_CLIENTS) {
1518 if (dev->dev_state == MEI_DEV_POWER_DOWN ||
1519 dev->dev_state == MEI_DEV_POWERING_DOWN) {
1520 dev_dbg(dev->dev, "hbm: enumeration response: on shutdown, ignoring\n");
1523 dev_err(dev->dev, "hbm: enumeration response: state mismatch, [%d, %d]\n",
1524 dev->dev_state, dev->hbm_state);
1528 dev->hbm_state = MEI_HBM_CLIENT_PROPERTIES;
1531 if (mei_hbm_prop_req(dev, 0))
1537 dev_dbg(dev->dev, "hbm: stop response: message received\n");
1539 dev->init_clients_timer = 0;
1541 if (dev->hbm_state != MEI_HBM_STOPPED) {
1542 dev_err(dev->dev, "hbm: stop response: state mismatch, [%d, %d]\n",
1543 dev->dev_state, dev->hbm_state);
1547 mei_set_devstate(dev, MEI_DEV_POWER_DOWN);
1548 dev_info(dev->dev, "hbm: stop response: resetting.\n");
1553 dev_dbg(dev->dev, "hbm: disconnect request: message received\n");
1556 mei_hbm_fw_disconnect_req(dev, disconnect_req);
1560 dev_dbg(dev->dev, "hbm: stop request: message received\n");
1561 dev->hbm_state = MEI_HBM_STOPPED;
1562 if (mei_hbm_stop_req(dev)) {
1563 dev_err(dev->dev, "hbm: stop request: failed to send stop request\n");
1569 dev_dbg(dev->dev, "hbm: add client request received\n");
1574 if (dev->hbm_state <= MEI_HBM_ENUM_CLIENTS ||
1575 dev->hbm_state >= MEI_HBM_STOPPED) {
1576 dev_err(dev->dev, "hbm: add client: state mismatch, [%d, %d]\n",
1577 dev->dev_state, dev->hbm_state);
1581 ret = mei_hbm_fw_add_cl_req(dev, add_cl_req);
1583 dev_err(dev->dev, "hbm: add client: failed to send response %d\n",
1587 dev_dbg(dev->dev, "hbm: add client request processed\n");
1591 dev_dbg(dev->dev, "hbm: notify response received\n");
1592 mei_hbm_cl_res(dev, cl_cmd, notify_res_to_fop(cl_cmd));
1596 dev_dbg(dev->dev, "hbm: notification\n");
1597 mei_hbm_cl_notify(dev, cl_cmd);
1601 dev_dbg(dev->dev, "hbm: client dma map response: message received.\n");
1603 mei_hbm_cl_dma_map_res(dev, client_dma_res);
1607 dev_dbg(dev->dev, "hbm: client dma unmap response: message received.\n");
1609 mei_hbm_cl_dma_unmap_res(dev, client_dma_res);