Lines Matching refs:device

93     // Unload any device drivers might have been loaded
158 // Load device driver if requested
199 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
201 if (device != NULL) {
202 LOG_I("dropConnection(): closing still open device.");
204 device->close(connection);
344 LOG_V("%s: no device associated with connection",__FUNCTION__); \
357 // Check if device has been registered to the connection
358 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
359 if (NULL != device) {
360 LOG_E("processOpenDevice(): device already set");
367 // Get device for device ID
368 device = getDevice(cmdOpenDevice.deviceId);
370 // Check if a device for the given name has been found
371 if (device == NULL) {
377 // Register device object with connection
378 device->open(connection);
393 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
394 CHECK_DEVICE(device, connection);
397 // Unregister device object with connection
398 device->close(connection);
414 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
415 CHECK_DEVICE(device, connection);
430 CWsm_ptr pWsm = device->registerWsmL2((addr_t)(regObj->value), regObj->len, 0);
444 mcResult_t ret = device->openSession(
454 if (!device->unregisterWsmL2(pWsm)) {
482 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
483 CHECK_DEVICE(device, connection);
485 mcResult_t ret = device->closeSession(connection, cmdCloseSession.sessionId);
497 // associated with a device. If a device is registered to the
504 // device must be empty since this is a new connection
505 MobiCoreDevice *device = (MobiCoreDevice *)(connection->connectionData);
506 if (device != NULL) {
507 LOG_E("device already set\n");
517 device = getDevice(cmd.deviceId);
518 // Check if a device for the given name has been found
519 if (NULL == device) {
525 TrustletSession *ts = device->registerTrustletConnection(
566 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
567 if (NULL == device) {
568 LOG_V("%s: no device associated with connection", __FUNCTION__);
578 device->notify(cmd.sessionId);
591 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
592 CHECK_DEVICE(device, connection);
594 if (!device->lockWsmL2(cmd.handle)) {
601 uint32_t pAddrL2 = (uint32_t)device->findWsmL2(cmd.handle);
610 mcResult_t mcResult = device->mapBulk(cmd.sessionId, cmd.handle, pAddrL2,
633 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
634 CHECK_DEVICE(device, connection);
637 uint32_t mcResult = device->unmapBulk(cmd.sessionId, cmd.handle, cmd.secureVirtualAdr, cmd.lenBulkMem);
646 device->unlockWsmL2(cmd.handle);
674 MobiCoreDevice *device = (MobiCoreDevice *) (connection->connectionData);
675 CHECK_DEVICE(device, connection);
680 mcResult_t mcResult = device->getMobiCoreVersion(&rspGetMobiCoreVersion.payload);