index 223e3cce59109fe44eff20469337262a12d35299..1d038cbdebcd1572a044f470a16ef04937b37dd5 100644 (file)
}
}
+ if (!rpmsg_rdev_remote_ready(rdev_loc))
+ return RPMSG_ERR_DEV_INIT;
+
/* Initialize endpoints list */
metal_list_init(&rdev_loc->rp_endpoints);
@@ -301,27 +304,9 @@ struct rpmsg_endpoint *rpmsg_rdev_get_endpoint_from_addr(struct remote_device *r
*/
int rpmsg_rdev_notify(struct remote_device *rdev)
{
- int status = RPMSG_SUCCESS;
-
- if (rdev->role == RPMSG_REMOTE) {
- status = hil_get_status(rdev->proc);
-
- /*
- * Let the remote device know that Master is ready for
- * communication.
- */
- if (!status)
- virtqueue_kick(rdev->rvq);
+ virtqueue_kick(rdev->rvq);
- } else {
- status = hil_set_status(rdev->proc);
- }
-
- if (status == RPMSG_SUCCESS) {
- rdev->state = RPMSG_DEV_STATE_ACTIVE;
- }
-
- return status;
+ return RPMSG_SUCCESS;
}
/**