remoteproc: report error if resource table doesn't exist
authorStefan Agner <stefan@agner.ch>
Sat, 29 Aug 2015 01:08:19 +0000 (18:08 -0700)
committerBjorn Andersson <bjorn.andersson@linaro.org>
Sat, 30 Jan 2016 01:26:45 +0000 (17:26 -0800)
Currently, if the resource table is completely missing in the
firmware, powering up the remoteproc fails silently. Add a message
indicating that the resource table is missing in the firmware.

Signed-off-by: Stefan Agner <stefan@agner.ch>
Acked-by: Suman Anna <s-anna@ti.com>
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
drivers/remoteproc/remoteproc_core.c

index 9e03d158f4119133f09b0979d8b5b70e1ae63c06..3d7d58a109d8ebb0b602e17b9a6ff4ed211423ef 100644 (file)
@@ -823,8 +823,10 @@ static int rproc_fw_boot(struct rproc *rproc, const struct firmware *fw)
 
        /* look for the resource table */
        table = rproc_find_rsc_table(rproc, fw, &tablesz);
-       if (!table)
+       if (!table) {
+               dev_err(dev, "Failed to find resource table\n");
                goto clean_up;
+       }
 
        /* Verify that resource table in loaded fw is unchanged */
        if (rproc->table_csum != crc32(0, table, tablesz)) {