From 7d2d3956fbc1aa9a3ccdc9389b88505232764d4f Mon Sep 17 00:00:00 2001 From: Mark Grosen Date: Tue, 13 Dec 2011 09:14:15 +0200 Subject: remoteproc: avoid registering a virtio device if not supported Let remoteproc know when the firmware doesn't support any virtio functionality, so registering a virtio device can be avoided. This is needed for remote processors that doesn't require any virtio-based communications, but are still controlled via remoteproc. [ohad@wizery.com: write commit log] Signed-off-by: Mark Grosen Signed-off-by: Ohad Ben-Cohen --- drivers/remoteproc/remoteproc_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/remoteproc/remoteproc_core.c') diff --git a/drivers/remoteproc/remoteproc_core.c b/drivers/remoteproc/remoteproc_core.c index 0d9a9552c311..080c0569ef38 100644 --- a/drivers/remoteproc/remoteproc_core.c +++ b/drivers/remoteproc/remoteproc_core.c @@ -695,7 +695,7 @@ static int rproc_handle_virtio_rsc(struct rproc *rproc, struct fw_resource *rsc, int len) { struct device *dev = rproc->dev; - int ret = 0; + int ret = -ENODEV; for (; len >= sizeof(*rsc); rsc++, len -= sizeof(*rsc)) if (rsc->type == RSC_VIRTIO_DEV) { -- cgit v1.2.1