vchiq_connect_internal(struct vchiq_state *state, struct vchiq_instance *instance)
{
struct vchiq_service *service;
+ int status = 0;
int i;
/* Find all services registered to this client and enable them. */
}
if (state->conn_state == VCHIQ_CONNSTATE_DISCONNECTED) {
- if (queue_message(state, NULL, MAKE_CONNECT, NULL, NULL, 0,
- QMFLAGS_IS_BLOCKING) == -EAGAIN)
- return -EAGAIN;
+ status = queue_message(state, NULL, MAKE_CONNECT, NULL, NULL, 0,
+ QMFLAGS_IS_BLOCKING);
+ if (status)
+ return status;
vchiq_set_conn_state(state, VCHIQ_CONNSTATE_CONNECTING);
}
complete(&state->connect);
}
- return 0;
+ return status;
}
void