Lines Matching refs:emul

40 		struct espi_emul *emul;  in espi_emul_find()  local
42 emul = CONTAINER_OF(node, struct espi_emul, node); in espi_emul_find()
43 if (emul->chipsel == chipsel) { in espi_emul_find()
44 return emul; in espi_emul_find()
91 struct espi_emul *emul; in espi_emul_read_lpc_request() local
101 emul = espi_emul_find(dev, EMUL_ESPI_HOST_CHIPSEL); in espi_emul_read_lpc_request()
102 if (!emul) { in espi_emul_read_lpc_request()
107 __ASSERT_NO_MSG(emul->api); in espi_emul_read_lpc_request()
108 api = emul->api; in espi_emul_read_lpc_request()
114 *data = (uint32_t)api->get_acpi_shm(emul->target); in espi_emul_read_lpc_request()
136 struct espi_emul *emul; in espi_emul_send_vwire() local
143 emul = espi_emul_find(dev, EMUL_ESPI_HOST_CHIPSEL); in espi_emul_send_vwire()
144 if (!emul) { in espi_emul_send_vwire()
149 __ASSERT_NO_MSG(emul->api); in espi_emul_send_vwire()
150 __ASSERT_NO_MSG(emul->api->set_vw); in espi_emul_send_vwire()
151 api = emul->api; in espi_emul_send_vwire()
153 return api->set_vw(emul->target, vw, level); in espi_emul_send_vwire()
160 struct espi_emul *emul; in espi_emul_receive_vwire() local
167 emul = espi_emul_find(dev, EMUL_ESPI_HOST_CHIPSEL); in espi_emul_receive_vwire()
168 if (!emul) { in espi_emul_receive_vwire()
173 __ASSERT_NO_MSG(emul->api); in espi_emul_receive_vwire()
174 __ASSERT_NO_MSG(emul->api->get_vw); in espi_emul_receive_vwire()
175 api = emul->api; in espi_emul_receive_vwire()
177 return api->get_vw(emul->target, vw, level); in espi_emul_receive_vwire()
202 int espi_emul_register(const struct device *dev, struct espi_emul *emul) in espi_emul_register() argument
205 const char *name = emul->target->dev->name; in espi_emul_register()
207 sys_slist_append(&data->emuls, &emul->node); in espi_emul_register()
209 LOG_INF("Register emulator '%s' at cs %u\n", name, emul->chipsel); in espi_emul_register()